Unable to use Drools in Eclipse - eclipse

I understand the latest version of Drools (7.47) descoped the Eclipse Java Compiler (https://docs.jboss.org/drools/release/7.47.0.Final/drools-docs/html_single/#drools-ecj), but this has broken the integration with Eclipse. I no longer get syntax/error parsing in .drl files, the Rete tree cannot be shown, and the project has a build error:
java.lang.ClassNotFoundException: org.drools.ecj.EclipseJavaCompiler cannot be found by org.drools.eclipse_7.47.0.Final
(This error is the same for the Rete tree and building the project)
Is this a bug in Drools that will be fixed in the next version, or a configuration issue I need to address? If it's a configuration issue, what do I need to do?

Related

How to get Eclipse Compiler for Java batch package 4.5.2+

Version 4.5.1 is the last one available from central - http://mvnrepository.com/artifact/org.eclipse.jdt.core.compiler/ecj/4.5.1
Unfortunately there is a nasty bug, which was fixed only in 4.5.2.
I cannot seem to find a binary package anywhere. I tried building it from sources but failed (details below). What is the recommended way to obtain 4.5.2 binary?
I tried https://github.com/eclipse/eclipse.jdt.core but it doesn't have any relevant tags.
I tried building the tag R4_5_2 from https://git.eclipse.org/c/jdt/eclipse.jdt.core.git/tag/?h=R4_5_2
Suprisingly it still has a snapshot version 4.5.2-SNAPSHOT and requires a parent of the same version. I can try building the parent project, but I'd expect it to be already available in some repository etc. Before proceeding I'd like at least to know if this path is going to lead anywhere.
Finally I came across Project Tycho but I think this is only relevant if I'm creating a new plugin.
I've found one here by random googling: http://download.eclipse.org/eclipse/downloads/drops4/R-4.5.2-201602121500/#JDTCORE
However the timestamp is different than what I get in my Eclipse Mars. Here it's 20160212-1500 and in Eclipse I have 20160128-0629

How can I file an issue for SonarQube Eclipse plugin

I went here but cannot see any means of reporting an issue:
https://jira.codehaus.org/browse/SONARIDE
The issue is that SonarQube plugin in Eclipse stops working when project is configured as "Groovy Project" and DSL jar is added to classpath. The Sonar run crashes with message saying that it cannot find the Groovy DSL jar in "{build folder}\C:\Users....", which makes no sense - why the hell is it treating an absolute path as relative.
You can't create issue in JIRA by yourself. We prefer issues to be first discussed on our user mailing list (or on SO) in order to avoid too many "won't fix/not a bug".
In your case it seems to be a valid report so I have created https://jira.codehaus.org/browse/SONARIDE-430. In next Sprint of SonarQube Eclipse we plan to highly improve multi language support and Groovy is a good candidate.
If you could provide a simple Groovy project (including Eclipse metadata .project, .settings, ...) it would be very helpful.

The RequestFactory ValidationTool must be run for the ... ApplicationRequestFactory RequestFactory type

I want to use Spring ROO 1.2.1 + GWT 2.6.1 in Springsource Tool Suite 2.9.1 in Ubuntu 12.04.
Following guides like the video in http://www.bytespring.com/blog/spring-roo-integration-gwt, I can create with roo a new project via the "expense" script, then run it with mvn gwt:run.
Ok, than I want to manage it in STS and now the problem starts.
It seems to be problem about m2e.
In pom.xml the tag for artifact with ID "exec-maven-plugin" have this error:
Plugin execution not covered by lifecycle configuration: org.codehaus.mojo:exec-maven-plugin:1.2:exec (execution: default, phase: process-classes)
I tried to follow the solution suggested in How to solve "Plugin execution not covered by lifecycle configuration" for Spring Data Maven Builds.
Surrounded "plugins" tag with the "pluginManagement" tag. Now the error no longer appears.
Then I run the application, "Run as -> Web Application"... HTML Page Selection: ApplicationScaffold.html.
The web page appears, but with a window with this error:
Error: One or more exceptions caught, see full set in UmbrellaException#getCause".
The STS console says
"java.lang.RuntimeException: The RequestFactory ValidationTool must be run for the org.springsource.roo.extrack.client.managed.request.ApplicationRequestFactory RequestFactory type".
To solve this problem, I followed the instructions in http://code.google.com/p/google-web-toolkit/wiki/RequestFactoryInterfaceValidation.
1)In Project Properties->Java Compiler->Annotation Properties I enabled project specific settings, annotation processing and processing in editor, gen.source directory: .apt_generated; verbose false.
2) In Factory Path, enabled project specific settings, and added the external requestfactory-apt.jar located in
/home/toni/springsource/sts-2.9.1.RELEASE/plugins/com.google.gwt.eclipse.sdkbundle_2.4.0.v201205091048-rel-r37/gwt-2.4.0
(right??)
(I do not understand if "Validation Tool" and "Maven build" sections are important for me)
Now I tried to re-run (after a rebuild of project) and the same error persists.
Someone solved this problem?? How? Please explain step-by-step because I am not an expert, It's my first approach with spring and gwt...
This looks like the same problem I ran into a short while back, which (after considerable digging) appeared to be down to a bug in AJDT (Eclipse's AspectJ compiler) which means that it currently cannot handle Java 6 annotations (used heavily by Roo).
A comment on a connected GWT bug report describes the following workaround:
move AspectJ builder to be in front (on top) of Java builder in project properties, Builder page.
clean and build the project.
copy and save generated Java/class files in .apt_generated directory to somewhere else.
move Java builder back in front of AspectJ builder.
clean and rebuild the project
copy the class file from 3 above to your project's classpath.
Alternatively, you can build your project outside of Eclipse - the non-IDE AspectJ compiler, ajc, does not suffer from this problem.

getting "no repository found at..." error when placing my plugin into Eclipse's dropins directory

i am using eclipse 3.5 to create a simple plugin bearing an extension point. i built it using headless pde build via ant. the plugin functions properly. i then proceeded to test its extension point by placing my plugin jar into eclipse_home/dropins with intention of eventually creating an extension. but after i start eclipse, i get the following error in its log:
!ENTRY org.eclipse.equinox.p2.core 4 0 2012-03-22 01:00:45.270
!MESSAGE Provisioning exception
!STACK 1
org.eclipse.equinox.internal.provisional.p2.core.ProvisionException: No repository found at file:/C:/eclipse35/dropins/MyPlugin/.
at org.eclipse.equinox.internal.p2.repository.helpers.AbstractRepositoryManager.fail(AbstractRepositoryManager.java:380)
at org.eclipse.equinox.internal.p2.repository.helpers.AbstractRepositoryManager.loadRepository(AbstractRepositoryManager.java:641)
at org.eclipse.equinox.internal.p2.metadata.repository.MetadataRepositoryManager.loadRepository(MetadataRepositoryManager.java:92)
at org.eclipse.equinox.internal.p2.metadata.repository.MetadataRepositoryManager.loadRepository(MetadataRepositoryManager.java:88)
at org.eclipse.equinox.internal.p2.reconciler.dropins.Activator.loadMetadataRepository(Activator.java:90)
at org.eclipse.equinox.internal.p2.reconciler.dropins.DropinsRepositoryListener.getMetadataRepository(DropinsRepositoryListener.java:184)
at org.eclipse.equinox.internal.p2.reconciler.dropins.DropinsRepositoryListener.addRepository(DropinsRepositoryListener.java:79)
at org.eclipse.equinox.internal.p2.reconciler.dropins.DropinsRepositoryListener.added(DropinsRepositoryListener.java:57)
at org.eclipse.equinox.internal.provisional.p2.directorywatcher.DirectoryWatcher.processFile(DirectoryWatcher.java:200)
at org.eclipse.equinox.internal.provisional.p2.directorywatcher.DirectoryWatcher.scanDirectories(DirectoryWatcher.java:161)
at org.eclipse.equinox.internal.provisional.p2.directorywatcher.DirectoryWatcher.poll(DirectoryWatcher.java:108)
at org.eclipse.equinox.internal.p2.reconciler.dropins.Activator.watchDropins(Activator.java:491)
at org.eclipse.equinox.internal.p2.reconciler.dropins.Activator.start(Activator.java:167)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:782)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:773)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:754)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:352)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:370)
at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1068)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:557)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:464)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:248)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:445)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:220)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:330)
i have tried both just placing the plugin jar directly in the dropins directory, as well as using the following directory structure: eclipse_home/dropins/MyPlugin/plugins/myplugin.jar. both approaches work just fine with 3rd party plugins, but not with mine. please let me know what i am doing wrong. thank you!
It seems like two problems. The "no repository found" error message looks like this problem. And then there is the issue with your plugin not starting.
First you should check if the plugin is found.
Then you should check if the plugin is resolved, i.e if all requirements are fulfilled.
If you have the plugin development version of Eclipse, then you can open the plugin registry view. See if your plugin is in the list, if so, then the atleast it has been found. Then right click on it, enable advanced operations, and after that choose diagnose. Some requirement has probably not been fulfilled.
If you dont have the Plugin version of Eclipse, you can use the osgi console. Go to console view, and choose OSGI console in the view menu.
Run command ss to list all plugins, and diag 123 where the number is the id of your plugin to diagnose it.
Also, see a previous answer to a similar question
Edit: Oh, and I have been having some serious problems getting plugins placed in the dropins catalog to work at times... You could try to copy it to the eclipse/plugins catalog directly.

JFXtras and Netbeans compiler issue

Would somebody be able to walk me through the proper way of adding the latest JFXtras package to a project in Netbeans? I'm not sure what I'm doing wrong... whether it be importing incorrectly, implementing incorrectly, or just simply downloading the wrong jar files. I'm using JavaFX 1.3 and NetBeans 6.9.
I've been able to get NetBeans to recognize the components in the library (I type XCustomNode, and it prompts me to import from org.​jfxtras.​scene.) Upon trying to build/run, however, I get a compiler error such as the following:
Note: An internal error has occurred in the OpenJFX compiler. Please file a bug at the Openjfx-compiler issues home (https://openjfx-compiler.dev.java.net/Issues) after checking for duplicates. Include in your report:
- the following diagnostics
- file C:\Documents and Settings\me\Local Settings\Temp\javafx_err_4220242024568343160.txt
- and if possible, the source file which triggered this problem. Thank you. C:\Documents and Settings\me\My Documents\NetBeansProjects\project\src\input\NumberWithLabelNode.fx:24: cannot access com.sun.javafx.runtime.location.ObjectVariable class file for com.sun.javafx.runtime.location.ObjectVariable not found public class NumberWithLabelNode extends XCustomNode { 1 error
I don't think I really need to go report this to Openjfx... my gut says I'm missing a file.
Not sure what version of JFXtras you're using, but I've had much better success with version 0.7rc alongside JavaFX 1.3.
In addition to making sure Common and Controls jars in in your library, I've had to add miglayout-3.7.jar and swing-worker-1.2.jar as well, available on the project downloads page
The problem you are facing is incorrect version of library. You are trying to use JFXtras compiled with JavaFX 1.2.* and your project is using JavaFX 1.3.. As you can learn on official site, JavaFX is not backward compatible yet. Get newer library or rebuild sources with JavaFX 1.3.