Coder Social home page Coder Social logo

lcdsl's Introduction

lcdsl

Eclipse Launch Configuration DSL (Xtext based)

unstable

LcDsl provides a way of defining Eclipse launch configurations in a textual way. The file extension used is '.lc' It provides some obvious and some non-obvious advantages over the Eclipse launch configuration solution:

  • Merge-able text representation
  • Compatible - LcDsl translates to "normal" Eclipse launch configurations
  • Stable format (i.e. sometimes Eclipse launch configurations change when just opening them in the editor for no obvious reasons - .lc files don't)
  • Flexibility:
    • Define launch configurations using plugins and features and .product files. In a single configuration.
    • Let LcDsl calculate dependencies automatically for you. Or don't, and define everything statically.
    • Influence the dependency calculation that LcDsl can do by telling it to ignore dependency subtrees.
    • Use abstract launch configurations as templates, allowing for very slick configuration definitions.
  • Support for plain Java, Eclipse, RAP, JUnit Plug-in, SWTBot and Launch Group configurations - more on demand.

Currently, the LcDsl repository also provides the Launch Configuration View feature. See below for documentation on that.

Installation

Currently, the latest update site is hosted here: https://mduft.github.io/lcdsl-latest/ (P2 repository)

Ziped P2 repositories are provided for releases.

Demo

See these videos for a quick glance on what it is all about:

IMAGE ALT TEXT

IMAGE ALT TEXT

General

All launch configurations are built up the same way:

[modifiers..] [type] configuration [name] {
    [single-properties..] // properties that appear at most once
    [multi-properties..] // properties that can appear 0..N times
}

All kinds of launch configurations can define certain attributes the same. These are:

  • modifiers:
    • manual: launch configuration is not generated on save, but only explicitly by right clicking the configuration in the editor or the outline view.
    • abstract: defines an abstract configuration which can be used to define certain things in a reusable way. An abstract configuration can be used by adding a : and its name after the name of the inheriting configuration.
    • foreground: launches the launch configuration in foreground.
    • no-console (not for type 'group'): don't allocate a console for the launch.
    • replace-env (not for type 'group'): don't append to the environment when defining new variables, but replace it as a whole.
    • qualified: qualifies the name of the launch configuration with the project name the file is contained in. This allows to copy the project and have all copied launch configurations automatically receive the project name as prefix (means that the now two launch configurations don't collide).
    • qualified("NAME"): qualifies the launch configuration by prefixing it with NAME.
  • single-properties:
    • working-dir: specifies the working directory for the launch
    • memory: allows to specify various memory aspects (min, max, maxPermSize) without the need to wring vm-args.
    • favorite: allows to specify launch groups where this launch should appear as favortite (run, debug, profile, ...)
    • redirect (not for type 'group'): allows to redirect stdin, stdout/stderr to/from files.
    • execution-environment (not for type 'group'): specifies the execution environment to use for the launch
  • multi-properties:
    • vm-argument (not for type 'group'): allows to specify one or more (on the same line) vm arguments
    • argument (not for type 'group'): allows to specify command line arguments for the program to launch
    • environment (not for type 'group'): allows to specify an environment variable to place into the launches environment.

Multiple Arguments have to be quoted each, key and value separately, but may be written in one line:
vm-argument '-os' '${target.os}'

For all the above, check content assist to get an idea of the supported values and the exact syntax.

Note that variable expansion is supported throughout most string values in LcDsl (exceptions: regular expression for group post-launch action, RAP servlet/context path, trace specifications). Variables are defined in the Eclipse standard way (Window > Preferences > String Substitutions).

Java

The configuration type java has these attributes on top:

  • modifiers:
    • stop-in-main: when debugging stop execution on the first line of the main method
  • single-properties:
    • project: specifies the project that contains the main class of the program to run
    • main-class: specifies the class in project that contains the main method to execute. Content assist for this attribute is available once project is set for the launch.
    • search-main: allows to extend the search path for the main class to inherited methods and system libraries that the project dependes on.

A typical java configuration looks like this:

java configuration LcJavaMain {
    project com.wamas.test;
    main-class com.wamas.test.JavaMain;
    	
    memory min=64m max=256m;
    
    vm-argument '-Dmy.arg=value';
    argument 'cmdArg';
}

Eclipse, RAP, JUnit Plug-in, SWTBot

Eclipse, RAP, JUnit Plug-in and SWTBot launch configurations share a lot of configuration options, that is why they are described in the same chapter. The following attributes are added for these types:

  • modifiers:
    • explicit: usually LcDsl will automatically add required dependencies of the specifies plugins to the launch. This modifier tells it to not do so.
    • no-validate: don't validate (check for missing/invalid) plugins before launching
    • sw-install-allowed (not for type 'rap'): allow software installation via P2 in the launch
    • keep-running (only for type 'junit-plugin' and 'swtbot'): keep JUnit running after a test run when debugging
    • run-in-ui-thread (only for type 'junit-plugin'): run JUnit test in UI thread
  • single-properties:
    • clear: allows to clear (and force clear without confirmation) workspace/log and configuration area
    • workspace: specifies the workspace directory to use.
    • application: id of the application to launch. Only valid if no product is set
    • product: id of the product to launch. Only valid if no application is set
    • config-ini-template: use the given file as config.ini template.
    • content-provider: allows to specify the absolute path to a .product file (Hint: you can use variables like ${workspace_loc}). This file is read and all declared dependencies (features, plugins) are expanded as if they were declared using plugin and feature directives. There is no way to apply ignore to any of the features/pluings originating from the .product. Additionally, arguments and VM arguments are applied as well, as if written directly in the launch configuration.
    • servlet {} (only for type 'rap'):
      • path: servlet path
      • browser: use internal, external or no browser at all on launch
      • port: port to use for the web server
      • session-timeout: session timeout to use
      • context-path: use this as additional context path
      • dev-mode: enable RAP developer mode
    • test {} (only for types 'junit-plugin' and 'swtbot'):
      • runner: test runner (JUnit3, JUnit4 or JUnit5 (default))
      • container: project, package or source folder which contains tests (the project containing the .lc file if not specified). If the container points to a plugin project, the plugin will be added to the dependency list as well.
      • class: If specified only tests within this class will be executed, otherwise all tests of the container will be executed.
      • method: If specified only this test will be executed, otherwise all tests of the class will executed.
      • exclude-tags (only for runner 'junit5'): tags which are used to exclude certain tests
      • include-tags (only for runner 'junit5'): tags which are used to include certain tests
  • multi-properties
    • plugin: adds a plugin to the launch configuration. may specify also version, startlevel and autostart property. Dependencies of the given plugin are added automatically to the launch unless explcit modifier is given.
    • feature: same as plugin but for features - no startlevel support though.
    • ignore: specify a plugin symbolic name to ignore during automatic dependency resolution. this plugin will not be taken into account, and thus also it's direct and indirect dependencies will not be added (unless some other plugin requires the same ones).
    • trace: allows to specify trace options per plugin.

Examples for typical eclipse, rap, junit-plugin and swtbot launch configurations:

eclipse configuration LcEclipseMain {
    workspace "${workspace_loc}/../runtime-MyWorkspace";
    application com.wamas.test.demo;
    
    clear workspace! config;
    memory min=64M max=256M;
    
    plugin com.wamas.test;
    
    environment DISPLAY=":0";
}

rap configuration LcRapMain {
    servlet {
        path '/test';
        port 8081;
    }
    
    plugin com.wamas.test;
}

junit-plugin configuration LcSWTBotMain {
    application com.wamas.test.demo;
    feature com.wamas.test.demo.feature;
    test {
        runner junit5;
        container '/com.wamas.test.demo.tests';
        exclude-tags long-running,ui-required;
    }
}

swtbot configuration LcSWTBotMain {
    application com.wamas.test.demo;
    plugin com.wamas.test.demo.plugin;
    test {
        runner junit4;
        container '/com.wamas.test.demo.swtbottests';
        class com.wamas.test.demo.swtbottests.MainTest;
        method 'testMain';
    }
}

Launch Groups

LcDsl allows to create Launch groups by using the group type and the member multi-property. Example:

group configuration MyGroup1 {
    adopt run member MyLaunchConfig1; // Launch Mode "Run" is used
    adopt inherit member MyLaunchConfig2; // Launch Mode "inherit" is used
    adopt run member MyLaunchConfig3 delay 2; // Two seconds post launch action
    adopt run member MyLaunchConfig4 wait; // Wait until terminated
    adopt run member MyLaunchConfig4 regex "Started"; // Wait until regular expression is found in console output
    adopt run member MyGroup2; // launch another group
}

Launch Configuration View

The launch configuration view is something that is actually independent of LcDsl itself. It depends on Eclipse platform.debug ONLY. It allows to hook (via OSGi services) launch configuration providers into it. It comes along with a default provider that allows it to handle "normal" Eclipse launch configurations. LcDsl brings along another provider for the view, that allows it to also handle LcDsl specifics.

lcdsl's People

Contributors

bananeweizen avatar ecljpseb0t avatar glatuske avatar haubi avatar hueami avatar jukzi avatar mduft avatar miklossy avatar simplydanny avatar szarnekow avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

lcdsl's Issues

Provide default ID for launch config

Currently, I have to know at which position I have to enter the launch config ID, as the auto-complete does not propose anything at this point.
It would be easier to use if auto-complete provides an default ID, so I can get to a valid launch config by hitting Ctrl-Space lots of times.

Validation for test class is too strict

The validation looks for test related annotations on public test methods only. However, JUnit 5 no longer requires public test methods, therefore the validation wrongly fails on JUnit 5 test classes that leave away the public keyword.

See https://github.com/ssi-schaefer/lcdsl/blob/master/com.wamas.ide.launching/src/com/wamas/ide/launching/validation/LcDslValidator.xtend#L425 and https://github.com/ssi-schaefer/lcdsl/blob/master/com.wamas.ide.launching/src/com/wamas/ide/launching/validation/LcDslValidator.xtend#L427

Introduction of variables in lcdsl

I have the following configuration:

abstract swtbot configuration Base-UI-Test {
	product MyProduct;
	content-provider "${workspace_loc:MyProduct}/target/classes/product.product";
}
swtbot configuration My-Plugin-UI-Test : Base-UI-Test {
	plugin MyPlugin;
	workspace "${workspace_loc:/MyPlugin}/target/swt-workspace";
	
	test {
		runner junit4;
		container '/MyPlugin';
	}
}

and with variables I would like to be able to do something like this:

abstract swtbot configuration Base-UI-Test {
	product MyProduct;
	content-provider "${workspace_loc:MyProduct}/target/classes/product.product";
	
	workspace "${workspace_loc:/$testPlugin}/target/swt-workspace";
	
	test {
		runner junit4;
		container '/$testPlugin';
	}
}
swtbot configuration My-Plugin-UI-Test : Base-UI-Test {
	plugin MyPlugin;
	var testPlugin="MyPlugin";
}

I'm not sure what all is possible within the editor for pre validating the code.

Maybe it would even be possible in Non-String arguments for:
plugin $testPlugin;

Invalid product id

Hi,

I tried to use lcdsl for our RCP application but I encountered an issue.

I this config launch.lc:

eclipse configuration Coder_Studio {
    product io.toro.coder.branding.io.toro.coder.product;
    
    feature io.toro.coder.feature;
    feature io.toro.coder.gloop.feature;
    feature io.toro.coder.flux.feature;
}

Once the corresponding launch configuration is generated I check it and the select product is invalid.
image

If I do it manually it would be:
image

The plugin.xml in io.toro.coder.branding looks like this:

<plugin>
    <extension
            id="io.toro.coder.product"
            point="org.eclipse.core.runtime.products">
        <product
                description="Coder Studio"
                application="org.eclipse.ui.ide.workbench"
                name="TORO Coder Studio">
        <!-- ... -->
        </product>
    </extension>
</plugin>

Am I doing something wrong or is it an issue on lcdsl side?

Support for different project names

We often have the problem, that a project will be copied (or branched) with it's launch configurations.
This new projects get's a new project name.
After the copy and renaming of the project the launch configurations they will not longer work, because they contain the old project name.

It would be nice to have a place holder for the project which will be filled with the current project.
Especially for launch configurations located in the project it would be helpful.

Eclipse "hangs" when using ${project_loc} in "content-provider"

Hi,

due to a discussion in portfolio-performance/portfolio#1156, I am checking out a generic way to create reliable launch configurations. I really like the approach of this project.

My Product file does not reside in the workspace (as the git projects are checked out somewhere else. I would hope to use project_loc, however, my Eclipse Installation (2019-03) --> on macOS I get a spinning wheel mouse pointer and have to abort Eclipse.

Is project_loc supported?

eclipse configuration PP {
    workspace "${workspace_loc}/../runtime-MyWorkspace";
    product name.abuchen.portfolio.bootstrap.product;
    
    content-provider "${project_loc}/../portfolio-product/name.abuchen.portfolio.product";
    
    ignore javax.servlet;
    ignore name.abuchen.portfolio.tests;
    ignore name.abuchen.portfolio.ui.tests;
    ignore org.jsr-305;
    
    argument "-consoleLog";
    argument "-Dorg.eclipse.e4.core.di.debug=true";
}

BTW, the resolution includes more plugins than defined in the product file - for example all test plugins. Is there a way to reduce it to the features/plugins defined in the product file only?

Formatting of launch configuration files not possible

Using CTRL+SHIFT+F in eclipse results in "complete content of file is moved to first line of file".

So instead of

java configuration XXX : BaseJavaLog4jLaunch {
memory max = 1280M;
main-class com.test.something.Main;
project com.test.something;
argument "42";
vm-argument "-Dtarget.home=${target_home}" ;
}

I get

java configuration XXX : BaseJavaLog4jLaunch { memory max = 1280M; main-class om.test.something.Main; project com.test.something; argument "42"; vm-argument -Dtarget.home=${target_home}" ; }

Schema based Grammar

To make the language extensible, it should be possible to define schemas (without changing LcDsl) to define new launch configuration types.

The language should provide the value types (string, int, plugin, feature, path, ...), and the schema should define which keys are using which value types, as well as how they transform into the launch configuration attributes later on.

Support launch type pure JUnit?

We do make a difference between out JUnit plugin tests vs our pure unit tests.
The plugin test take significant more startup time, so we want to run the pure unit test much more often.

Could LCDSL also support this?

Content Assist not working

Content assist is not working properly in a lot of cases, for instance the launch configuration type is no longer proposed once a single 'modifier' is present.

Application `[No Application] - Headless Mode` unsupported. - Should be default

In the Junit Runner application, there is a setting to run the built-in Eclipse JUnit runner. It hides behind a drop-down setting of [No Application] - Headless Mode. It would be nice to include this setting or even make this the default. I am unsure how else I can use the DSL without this at the moment - the validation fails as the editor does not know about this.

The default application name is org.eclipse.pde.junit.runtime.application for headless, and something with UI for running with widgets. It would be great if you could add this, as headless tests are very common.

new feature: Add required dependencies

It would be nice to have a quickfix that adds all required dependencies to a launch config.

This could work

  • For a complete launch config (main use case)
  • For one entry (product / feature / plugin) to only add the dependencies required for this one

In any case, we should add transitive dependencies, too.

Working Sets

I don't know if you are familiar with the Eclipse working sets, but it's a great way to organize your projects in an Eclipse workspace in the Project Explorer view.

It would cool to be able to toggle a filter for the launch configurations by selected project. Or to be able to toggle organizing them by working set or project instead of type.

Publish a p2 repo

In order to simplify trial and usage of those plugins, it would be great to produce and publish a p2-repo.

Easy access to raw launch configuration file

Perhaps via the right‑click menu, a selection for bringing up the XML file for the launch configuration in the Eclipse editor.
For this, I could see a Open and Open With similar to that if you right‑click a file in the Project Explorer.

It's sometimes nice to be able to edit those files outright as oppose to needing to work through the Launch Configuration Editor GUI window.

Additionally with this, a separate context‑menu selection for opening the location of the launch configuration in the file navigator (Windows Explorer (win), Finder (macOS), etc.) would be really nice to have as well.
Open File Location

Stackoverflow when a derived configuration has the same name than the original one

Copy the following snippet into a new .lc file:

eclipse configuration ConfigA {
    product org.eclipse.sdk.ide;
    plugin org.eclipse.core.runtime;
  }

  eclipse configuration CustomConfigA:ConfigA {
  }

Now rename CustomConfigA to ConfigA and press save.

eclipse configuration ConfigA:ConfigA { 
}

This results in a StackOverflow exception when trying to validate the configuration. See the attached file for more details.

stacktrace.txt

Qualify copied launch configurations

When copying a whole project including launch configurations, both the original and the copy should work. This is only possible if they get different names. A keyword (like 'auto-qualify' or so) could be implemented to prefix the launch configuration name automatically with the project name. This would allow to have both without any modifications. This is more or less the same requirement sources as "project self;"

Test class not accepting all JUnit5 variants

In the LCDSCL the block

Test {
    class my.TestClass;
}

does not accept all JUnit5 test classes.

E.g. in JUnit5 test class/method can be non-public, but package visible only. Please consider this example:

class TestClass {
    class Base {
        @Test
        void testMethod1() {}
        @Test
        void testMethod2() {}
    }
    @Nested
    class Variant1 extends Base {
        // configuration only, no test method
    }
    @Nested
    class Variant2 extends Base {
        // configuration only, no test method
    }
}

Cannot add two plugins with same id but different version

I'd like to add the same plugin twice, with different versions.
This is possible in regular launch configs.

LcDsl gives an error Duplicate PluginWithVersion 'org.antlr.runtime'

Example:

plugin org.antlr.runtime 3.2.0.v201101311130;
plugin org.antlr.runtime 4.3.0.v201502022030;

NPE when generating Launch Config for Feature-based Product

I'm working on a RCP application with a product and a single feature.
When I generate a launch configuration from the product, everything works, and I can start the application.
I would expect to be able to create a working launch configuration from the following LC file as well:

eclipse configuration LcLaunch {
    workspace "${workspace_loc}/../runtime-MyWorkspace";
    product foo.bar.product;
    feature foo.bar.feature;
}

Instead, I get an NPE in my error log:

Caused by: java.lang.NullPointerException
	at com.wamas.ide.launching.generator.DependencyResolver.getPluginModels(DependencyResolver.java:256)
	at com.wamas.ide.launching.generator.DependencyResolver.findDependencies(DependencyResolver.java:128)
	at com.wamas.ide.launching.generator.StandaloneLaunchConfigGenerator.generateDependenciesEclipseRap(StandaloneLaunchConfigGenerator.java:346)
	at com.wamas.ide.launching.generator.StandaloneLaunchConfigGenerator.generateEclipse(StandaloneLaunchConfigGenerator.java:340)
	at com.wamas.ide.launching.generator.StandaloneLaunchConfigGenerator.generate(StandaloneLaunchConfigGenerator.java:173)
	at com.wamas.ide.launching.ui.handlers.AbstractLaunchConfigGeneratorHandler.execute(AbstractLaunchConfigGeneratorHandler.java:37)
	at com.wamas.ide.launching.ui.handlers.AbstractLaunchConfigGeneratorHandler.execute(AbstractLaunchConfigGeneratorHandler.java:1)
	at org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:291)
	at org.eclipse.ui.internal.handlers.E4HandlerProxy.execute(E4HandlerProxy.java:92)
	at sun.reflect.GeneratedMethodAccessor76.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:55)
	... 36 more

If I try this it with a content-provider with the pull path of my product as a parameter, I also get an NPE with a different stack-trace

eclipse configuration LcLaunch {
    workspace "${workspace_loc}/../runtime-MyWorkspace";
    product foo.bar.product;
    
    content-provider 'C:\\foo\\bar\\Foo.product';
}
Caused by: java.lang.NullPointerException
	at com.wamas.ide.launching.generator.DependencyResolver.getPluginModels(DependencyResolver.java:256)
	at com.wamas.ide.launching.generator.DependencyResolver.lambda$3(DependencyResolver.java:208)
	at org.eclipse.xtext.xbase.lib.internal.FunctionDelegate.apply(FunctionDelegate.java:42)
	at com.google.common.collect.Iterators$7.transform(Iterators.java:750)
	at com.google.common.collect.TransformedIterator.next(TransformedIterator.java:47)
	at com.google.common.collect.Iterators$6.computeNext(Iterators.java:616)
	at com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:145)
	at com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:140)
	at com.google.common.collect.TransformedIterator.hasNext(TransformedIterator.java:42)
	at com.google.common.collect.MultitransformedIterator.hasNext(MultitransformedIterator.java:50)
	at com.google.common.collect.MultitransformedIterator.hasNext(MultitransformedIterator.java:50)
	at com.google.common.collect.Iterators.addAll(Iterators.java:366)
	at com.google.common.collect.Iterables.addAll(Iterables.java:332)
	at com.wamas.ide.launching.generator.DependencyResolver.findBundlesInProduct(DependencyResolver.java:213)
	at com.wamas.ide.launching.generator.DependencyResolver.findDependencies(DependencyResolver.java:107)
	at com.wamas.ide.launching.generator.StandaloneLaunchConfigGenerator.generateDependenciesEclipseRap(StandaloneLaunchConfigGenerator.java:346)
	at com.wamas.ide.launching.generator.StandaloneLaunchConfigGenerator.generateEclipse(StandaloneLaunchConfigGenerator.java:340)
	at com.wamas.ide.launching.generator.StandaloneLaunchConfigGenerator.generate(StandaloneLaunchConfigGenerator.java:173)
	at com.wamas.ide.launching.ui.handlers.AbstractLaunchConfigGeneratorHandler.execute(AbstractLaunchConfigGeneratorHandler.java:37)
	at com.wamas.ide.launching.ui.handlers.AbstractLaunchConfigGeneratorHandler.execute(AbstractLaunchConfigGeneratorHandler.java:1)
	at org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:291)
	at org.eclipse.ui.internal.handlers.E4HandlerProxy.execute(E4HandlerProxy.java:92)
	at sun.reflect.GeneratedMethodAccessor82.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:55)
	... 36 more

Also, I do not understand why the DSL forces me to add features/plug-ins or a content-provider at all, when the product should contain everything that's necessary to generate a launch configuration.

I'm using Oxygen and the latest LCDSL.

[Feature] Overwrite an existing configuration

Scenario: Developers are checking in launch configuration into a code repository so that the entire team uses the same settings.

Now as a developer i want to customize an existing configuration to adopt some settings (xmx, plug-ins). Currently i have to derive from the existing configuration and choose a new unique name. This is annoying in the case that the configuration is referenced in a shared launch group. I would now also need to change the launch group.

Would be nice to have a feature that allows me to overwrite settings of an existing configuration. It should be validated that there can only be a single configuration that overwrites an existing configuration.

Updating the Xtext Community Website

Hello Launch Configuration DSL team,

The Xtext team would like to update the Xtext community website listing all the cool projects people are building around Xtext/Xtend.

See also the corresponding GitHub issue and Bugzilla ticket.

If you are interested that the Launch Configuration DSL project is listed there, please provide the following information as a comment to this issue:

<tr>
	<td><a href="project_link">project_name</a></td>
	<td>project_description_max_2_sentences</td>
	<td>license</td>
	<td>category</td>
	<td>author(s)</td>
</tr>

We will then update the Xtext community website and get it online as soon as possible.

Thanks!
Tamás

How to launch Plug-in Tests?

Is there a way to launch plug-in tests?

I usually would create the launch configuration by right-clicking the project and choosing "Run --> JUnit Plug-in Test".

new feature: Link to products / features / plugins

I'd like to jump to the referenced product / feature / plugin when Ctrl-clicking / pressing F3 on a reference.

Example (| = cursor position):

plugin com.example.m|y.plugin;

Pressing F3 should open plugin.xml in com.example.my.plugin.

Compile error due to using API 11, but 1.8 on classpath

The project is currently in an inconsistent state and does not compile, if the JDK is setup correctly. It uses methods from Java 11 (List.of(...)), but compiles with 1.8 and has BREE 1.8. Would you prefer fixing the code to be 1.8 compatible again, or rather upgrade BREE and jdt settings to 11 (what I would very much prefer)?

Startlevels for workspacebundles

I have some startLevels defined in my product:

<configurations>
      <plugin id="org.eclipse.core.runtime" autoStart="true" startLevel="1" />
      <plugin id="org.eclipse.equinox.ds" autoStart="true" startLevel="1" />
      <plugin id="org.eclipse.equinox.event" autoStart="true" startLevel="2" />
      <plugin id="my.plugin" autoStart="true" startLevel="3" />
   </configurations>

But they seem not to have any impact. The important point is for the plugin from workspace:
<setEntry value="my.plugin@default:default"/>
So that I need to define at least the my.plugin startlevel in the lc to run my project properly.

Also the org.eclipse.equinox.ds does not get any starting level:
<setEntry value="org.eclipse.equinox.ds*[version]@default:default"/>

And org.eclipse.core.runtime gets another start level:
<setEntry value="org.eclipse.core.runtime*3.20.100.v20210111-0815@0:true"/>

The lc looks like this:

explicit eclipse configuration MyProduct {
	product my.product;
	content-provider "${workspace_loc:my.product}/product.product";
	//plugin my.plugin startlevel 3 autostart;
}

NPE with unknown launch types

Have a stored launch config (.launch, not .lc) in your workspace that is unknown to all the plugins in the current IDE. In that case the launch view is completely unusable because of NPE during creation of the tree. The view needs to filter out all launches where the container cannot be calculated.

java.lang.NullPointerException
	at org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel.lambda$9(LaunchViewModel.java:68)
	at java.base/java.util.TreeMap$KeySpliterator.forEachRemaining(TreeMap.java:2754)
	at java.base/java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:658)
	at org.eclipse.debug.ui.launchview.internal.model.LaunchViewModel.getModel(LaunchViewModel.java:67)
	at org.eclipse.debug.ui.launchview.internal.view.LaunchViewImpl.lambda$7(LaunchViewImpl.java:271)

In our case this happens because we declare own launch config types and have serialized launches for these types in our example and test models. And of course those runtime-only launch types are unknown to the IDE.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.