I'm trying to refactor a package name (pretty near the root of the project hierarchy), and I'm getting the following error (flash builder 4):
A fatal error occurred while performing the refactoring
An unexpected exception occurred while creating a change object. See the error log for more details.
The log file looks like this....
!ENTRY org.eclipse.ltk.ui.refactoring 4 10000 2010-09-30 10:57:25.134
!MESSAGE Internal Error
!STACK 0
java.lang.reflect.InvocationTargetException
at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:421)
at org.eclipse.ltk.internal.ui.refactoring.RefactoringWizardDialog2.run(RefactoringWizardDialog2.java:330)
at org.eclipse.ltk.ui.refactoring.RefactoringWizard.createChange(RefactoringWizard.java:583)
at org.eclipse.ltk.ui.refactoring.RefactoringWizard.computeUserInputSuccessorPage(RefactoringWizard.java:422)
at org.eclipse.ltk.ui.refactoring.UserInputWizardPage.computeSuccessorPage(UserInputWizardPage.java:74)
at org.eclipse.ltk.ui.refactoring.UserInputWizardPage.getNextPage(UserInputWizardPage.java:114)
at org.eclipse.ltk.internal.ui.refactoring.RefactoringWizardDialog2.nextOrPreviewPressed(RefactoringWizardDialog2.java:495)
at org.eclipse.ltk.internal.ui.refactoring.RefactoringWizardDialog2.access$2(RefactoringWizardDialog2.java:492)
at org.eclipse.ltk.internal.ui.refactoring.RefactoringWizardDialog2$1.widgetSelected(RefactoringWizardDialog2.java:691)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:228)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3880)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3473)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:825)
at org.eclipse.jface.window.Window.open(Window.java:801)
at org.eclipse.ltk.ui.refactoring.RefactoringWizardOpenOperation$1.run(RefactoringWizardOpenOperation.java:143)
at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
at org.eclipse.ltk.ui.refactoring.RefactoringWizardOpenOperation.run(RefactoringWizardOpenOperation.java:155)
at com.adobe.flexbuilder.as.editor.ui.navigator.FlexPackageExplorerRenameAction.renamePackage(FlexPackageExplorerRenameAction.java:171)
at com.adobe.flexbuilder.as.editor.ui.navigator.FlexPackageExplorerRenameAction.run(FlexPackageExplorerRenameAction.java:143)
at org.eclipse.ui.actions.BaseSelectionListenerAction.runWithEvent(BaseSelectionListenerAction.java:168)
at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:584)
at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:501)
at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:411)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3880)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3473)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2405)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2369)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2221)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:500)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:493)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at com.adobe.flexbuilder.standalone.FlexBuilderApplication.start(FlexBuilderApplication.java:109)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:194)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:368)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:559)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514)
at org.eclipse.equinox.launcher.Main.run(Main.java:1311)
Caused by: java.lang.StackOverflowError
at com.adobe.flexbuilder.codemodel.mxml.MXMLData$2.getMXMLVersion(MXMLData.java:501)
<-- snipped 1022 additional identical lines..-->
at com.adobe.flexbuilder.codemodel.mxml.MXMLData$2.getMXMLVersion(MXMLData.java:501)
Root exception:
java.lang.StackOverflowError
at com.adobe.flexbuilder.codemodel.mxml.MXMLData$2.getMXMLVersion(MXMLData.java:501)
<-- snipped 1022 additional identical lines..-->
at com.adobe.flexbuilder.codemodel.mxml.MXMLData$2.getMXMLVersion(MXMLData.java:501)
Any ideas what is wrong...and what I can do to fix it ? I queried google for it, and didn't turn up anything useful with the parameters I tried.
You can try to Restart Eclipse. Oddly that fixes a number of issues in Eclipse that happen all of a sudden with no normal explanation.
Increase the thread size of the JVM you run your IDE in?
I believe in Eclipse you could do it by adding -Xss with some value to eclipse.ini within your Eclipse installation. The setting is a JVM setting so should be added in the -vmargs section, it might be next to -Xmx which is there by default.
This may not be the best answer, but..I recommend you to try a different IDE like IntelliJ.
I've used Flash Builder before. It had always gave me problem. Usually it's because plug-in incompatible. Running tomcat in it sometimes gives me this "undead" java process that just won't die.
I'm using IntelliJ 9 now. It's autocomplete is less complete than Flash Builder, but it has a much better refactoring feature and..much MUCH better integration with other tools (like Maven).
Related
Greetings
I have deployed a simple JavaFX application using msi installer that was created by jpackage. When double-clicking on the application icon installed in Windows 10 "program files" directory, it displays an error "Failed to launch JVM". Prior to deployment, I tested the application jar file from the command prompt without any problem. When checking the application installation directory (under "C:\Program files") it has all the runtime dlls and so on, so I am not sure what causes this error? Here is the japckage command I used to build the runtime image:
jpackage --type msi --name FileChooser -p "%JAVAFX_HOME%\lib;%M2_REPO%;org\openjfx\mavenfxfilechooser\mavenfxfilechooser.jar" --module "org.openjfx.mavenfxfilechooser/org.openjfx.mavenfxfilechooser.FileChooserApp"
Update
Following the recommendation given in the comment section, I installed the JMODS on my machine and issued a jpackage command line to point to the JMODS files instead of JAVAFX_HOME as follow:
jpackage --type msi --name FileChooser -p "%JMODS_HOME%;%M2_REPO%;C:\Users\hrh74\Downloads\Lib\file\org\openjfx\mavenfxfilechooser" --module "org.openjfx.mavenfxfilechooser/org.openjfx.mavenfxfilechooser.FileChooserApp"
I installed the application using the MSI runtime image and this certainly solved the" Failed to launch JVM" problem. The application started, however, I have a WebView component that should display content from https://us.yahoo.com when the user clicks on a "Yahoo" button and this doesn't seem to be working when the application run as a self-contained app but it works when I run the jar file from the command line. Do I need to add anything to the jpackage?
Please let me know if the source code and FXML file are needed.
Thanks
Your original problem has to do with missing native code. But you appear to have already solved that problem by using the JMOD files for JavaFX provided by Gluon. So I'll try to help solve your other issue regarding https://us.yahoo.com not loading in the WebView once you create a self-contained application.
When trying to load that website myself I was running into the same issue as you. Though sometimes I'd get a "we're working on the problem" page response, other times the entire application would become unresponsive, and yet other times nothing would happen (the load would just seem to fail "gracefully"). This happened with other websites as well, not just Yahoo. After some testing I was finally able to get the following error:
java.lang.Throwable: SSL handshake failed
at javafx.web/javafx.scene.web.WebEngine$LoadWorker.describeError(Unknown Source)
at javafx.web/javafx.scene.web.WebEngine$LoadWorker.dispatchLoadEvent(Unknown Source)
at javafx.web/javafx.scene.web.WebEngine$PageLoadListener.dispatchLoadEvent(Unknown Source)
at javafx.web/com.sun.webkit.WebPage.fireLoadEvent(Unknown Source)
at javafx.web/com.sun.webkit.WebPage.fwkFireLoadEvent(Unknown Source)
at javafx.web/com.sun.webkit.network.URLLoaderBase.twkDidFail(Native Method)
at javafx.web/com.sun.webkit.network.HTTP2Loader.notifyDidFail(Unknown Source)
at javafx.web/com.sun.webkit.network.HTTP2Loader.lambda$didFail$18(Unknown Source)
at javafx.web/com.sun.webkit.network.HTTP2Loader.lambda$callBackIfNotCanceled$10(Unknown Source)
at javafx.graphics/com.sun.javafx.application.PlatformImpl.lambda$runLater$10(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Unknown Source)
at javafx.graphics/com.sun.javafx.application.PlatformImpl.lambda$runLater$11(Unknown Source)
at javafx.graphics/com.sun.glass.ui.InvokeLaterDispatcher$Future.run(Unknown Source)
at javafx.graphics/com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at javafx.graphics/com.sun.glass.ui.win.WinApplication.lambda$runLoop$3(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
That indicated to me the application created by jpackage was missing some crypto libraries. From here I just guessed, but inclulding:
--add-modules jdk.crypto.cryptoki,jdk.crypto.ec
When running jpackage seemed to solve the problem. I don't know if both modules are needed, or if only one is needed (or if adding either one implicitly adds the other).
Side note: When scrolling through https://us.yahoo.com I would frequently get the following warnings:
Mar 05, 2021 12:10:40 PM com.sun.javafx.webkit.prism.WCMediaPlayerImpl onError
WARNING: onError, errCode=0, msg=Could not create player!
And:
Mar 05, 2021 12:10:41 PM com.sun.javafx.webkit.prism.WCMediaPlayerImpl$CreateThread run
WARNING: CreateThread ERROR: java.lang.UnsupportedOperationException: Unsupported protocol "data"
I would get that warning regardless of how the application was packaged. I don't know how to solve the problem, or if there even is a solution without modifying the JavaFX code itself.
Have you seen running JavaFX application after jpackage? Try to download Gluon jmods and use it instead of %JAVAFX_HOME%
It is the first time I am posting my question here (I used to find the answer anywhere but this is turning me crazy). For my new job I need to use FlashBuilder (Adobe) to program in Flex. My partners are using Windows 8, but the enterprise computer they gave me is running Windows 10 already. I followed step by step the same manual they used to install everything, but I am obtaining the following error:
java.lang.NoClassDefFoundError: org/w3c/css/sac/Condition
at flex2.tools.API.getCompilers(API.java:264)
at flex2.tools.oem.Application.recompile(Application.java:918)
at flex2.tools.oem.Application.compile(Application.java:681)
at flex2.tools.flexbuilder.BuilderApplication.compile(BuilderApplication.java:354)
at com.adobe.flexbuilder.multisdk.compiler.internal.ASApplicationBuilder$MyBuilder.mybuild(ASApplicationBuilder.java:319)
at com.adobe.flexbuilder.multisdk.compiler.internal.ASApplicationBuilder.build(ASApplicationBuilder.java:129)
at com.adobe.flexbuilder.multisdk.compiler.internal.ASBuilder.build(ASBuilder.java:198)
at com.adobe.flexbuilder.multisdk.compiler.internal.ASItemBuilder.build(ASItemBuilder.java:70)
at com.adobe.flexbuilder.project.compiler.internal.FlexProjectBuilder.buildItem(FlexProjectBuilder.java:607)
at com.adobe.flexbuilder.project.compiler.internal.FlexProjectBuilder.build(FlexProjectBuilder.java:382)
at com.adobe.flexbuilder.project.compiler.internal.FlexIncrementalBuilder.build(FlexIncrementalBuilder.java:187)
at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:728)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:199)
at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:239)
at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:292)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:295)
at org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:351)
at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:374)
at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:143)
at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:241)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
Caused by: java.lang.ClassNotFoundException: org.w3c.css.sac.Condition
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(Unknown Source)
at com.adobe.flexbuilder.project.sdks.FlexClassLoader.loadClass(FlexClassLoader.java:133)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
... 23 more
I tried to install next plug-in: org.w3c.css.sac.source_1.3.1.v200903091627.jar, but I didn't achieve anything. I tried to search in the internet but I can't find a solution. We are thinking that the problem is about the operative system, so it is the unique difference between their enviroments and mine.
If you already had this error or you know any solution I would be really thankful.
Thank you very much,
Juan.
I downloaded and installed the latest version of Typesafe Activator, and created a new project with the Reactive Maps template, then tried to run it, but I get all kinds of java.lang.OutOfMemoryError exceptions in the log, and the UI is unresponsive.
No, I have not really started troubleshooting yet, but I would have expected these templates to be more robust and 'just work' -- is that a bad expectation?
I do not have a support contract, and could not find any way to ask for support; so is stackoverflow the best place to ask for help on these issues?
11:43:58.490 play-akka.actor.default-dispatcher-7 E Weaving class problem. Original class has been returned. The error was caused because of: java.lang.OutOfMemoryError: PermGen space java.lang.OutOfMemoryError#6e29ae44
java.lang.OutOfMemoryError: PermGen space
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at org.aspectj.weaver.bcel.ExtensibleURLClassLoader.defineClass(ExtensibleURLClassLoader.java:63)
at org.aspectj.weaver.loadtime.WeavingURLClassLoader.defineClass(WeavingURLClassLoader.java:148)
at org.aspectj.weaver.bcel.ExtensibleURLClassLoader.defineClass(ExtensibleURLClassLoader.java:97)
at org.aspectj.weaver.bcel.ExtensibleURLClassLoader.findClass(ExtensibleURLClassLoader.java:52)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at com.typesafe.sbt.echo.EchoPlayRun$$anonfun$createWeavingClassLoader$1$$anon$1.loadClass(EchoPlayRun.scala:50)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
at org.joda.time.DateTimeUtils.getChronology(DateTimeUtils.java:283)
at org.joda.time.format.DateTimeFormatter.selectChronology(DateTimeFormatter.java:940)
at org.joda.time.format.DateTimeFormatter.printTo(DateTimeFormatter.java:620)
at org.joda.time.format.DateTimeFormatter.printTo(DateTimeFormatter.java:497)
at org.joda.time.format.DateTimeFormatter.print(DateTimeFormatter.java:599)
at controllers.AssetsBuilder$$anonfun$at$1$$anonfun$apply$2$$anonfun$apply$10$$anonfun$apply$11.apply(Assets.scala:142)
at controllers.AssetsBuilder$$anonfun$at$1$$anonfun$apply$2$$anonfun$apply$10$$anonfun$apply$11.apply(Assets.scala:136)
at scala.Option.getOrElse(Option.scala:120)
at controllers.AssetsBuilder$$anonfun$at$1$$anonfun$apply$2$$anonfun$apply$10.apply(Assets.scala:136)
at controllers.AssetsBuilder$$anonfun$at$1$$anonfun$apply$2$$anonfun$apply$10.apply(Assets.scala:118)
at scala.Option.map(Option.scala:145)
at controllers.AssetsBuilder$$anonfun$at$1$$anonfun$apply$2.apply(Assets.scala:118)
at controllers.AssetsBuilder$$anonfun$at$1$$anonfun$apply$2.apply(Assets.scala:74)
at scala.Option.map(Option.scala:145)
at controllers.AssetsBuilder$$anonfun$at$1.apply(Assets.scala:74)
at controllers.AssetsBuilder$$anonfun$at$1.apply(Assets.scala:65)
at play.api.mvc.ActionBuilder$$anonfun$apply$10.apply(Action.scala:221)
at play.api.mvc.ActionBuilder$$anonfun$apply$10.apply(Action.scala:220)
at play.api.mvc.Action$.invokeBlock(Action.scala:357)
at play.api.mvc.ActionBuilder$$anon$1.apply(Action.scala:309)
at play.api.mvc.Action$$anonfun$apply$1$$anonfun$apply$4$$anonfun$apply$5.apply(Action.scala:109)
at play.api.mvc.Action$$anonfun$apply$1$$anonfun$apply$4$$anonfun$apply$5.apply(Action.scala:109)
11:44:00.224 application-akka.actor.default-dispatcher-3 E Weaving class problem. Original class has been returned. The error was caused because of:java.lang.OutOfMemoryError: PermGen space java.lang.OutOfMemoryError#3bdef2d
java.lang.OutOfMemoryError: PermGen space
Well, after rebooting my Windows system and running the the app again, this time it seems to work correctly. Must be another one of those environment/configuration mysteries as I did not change anything.
I am making a text editor app in JavaFX2 on NetBeans. My problem is this: whenever I try to insert the line scene.getStylesheets().add(<classname>.class.getResource("<css file>.css").toExternalForm()); to link the css, and run it, it shows an error: "Exception while running Application"What exactly is this exception? I've tried removing this line, and then the app runs smoothly. Just five-six hours back, I had inserted this same line of code (with correct classes and css file), it was easily able to use the css. But now, I've created another 3 projects to check it, but the app shows the same error and gets removed on removing this code. I create the Css by right-clicking the Source-packages icon > new > Cascading Style Sheets. I fill in all the correct classes and location for css file, yet this happens. Also tried Shift + F11 (clean and rebuild). When I launch the older app(with css), it runs without an error. (BTW I use Win8 Pro x64, if u need it)The output panel stops at Executing com.javafx.main.Main from <location>\Qwerty.jar using platform C:\Program Files\Java\jdk1.7.0_17/bin/java and then shows error:
Exception in Application start method
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at com.javafx.main.Main.launchApp(Main.java:642)
at com.javafx.main.Main.main(Main.java:805)
Caused by: java.lang.RuntimeException: Exception in Application start method
at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:403)
at com.sun.javafx.application.LauncherImpl.access$000(LauncherImpl.java:47)
at com.sun.javafx.application.LauncherImpl$1.run(LauncherImpl.java:115)
at java.lang.Thread.run(Thread.java:722)
Caused by: java.lang.NullPointerException
at qwerty.Qwerty.start(Qwerty.java:36) (LINE 36 is where the reference to css is)
at com.sun.javafx.application.LauncherImpl$5.run(LauncherImpl.java:319)
at com.sun.javafx.application.PlatformImpl$5.run(PlatformImpl.java:215)
at com.sun.javafx.application.PlatformImpl$4$1.run(PlatformImpl.java:179)
at com.sun.javafx.application.PlatformImpl$4$1.run(PlatformImpl.java:176)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.javafx.application.PlatformImpl$4.run(PlatformImpl.java:176)
at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at com.sun.glass.ui.win.WinApplication.access$100(WinApplication.java:29)
at com.sun.glass.ui.win.WinApplication$3$1.run(WinApplication.java:73)
... 1 more
Java Result: 1
The issue is explained in the nested excpetion:
Caused by: java.lang.NullPointerException
at qwerty.Qwerty.start(Qwerty.java:36) (LINE 36 is where the reference to css is)
Check if <classname>.class.getResource("<css file>.css") is null. Maybe you're specifing the wrong path or the css is not in the jar?
We have set up a basic Drools framework with Guvnor UI. Rules are written by semi-technical guys and have scope of errors (scope is always there irrespective of who writes it :))
Yesterday, someone wrote a rule which started throwing NullPoiterException but Drool appears to wrap this exception into CYCLIC_DEPENDENCY_ERROR and showing the same.
Also, we ended up with OOM java.lang.OutOfMemoryError: Java heap space immediately(3-4 minutes) after this issue.
Stacktrace for details:
Feb 2013 08:06:55,447 [ERROR] (SWF Activity DroolsActivityTaskList-2.2 229) com.amazon.mobius.csi.workers.droolsengine.DroolsEngineActivitiesImpl:runRules:220 [CYCLIC_DEPENDENCY_ERROR]: Error
while executing Rules, Please validate all rules against any cyclic dependency
Exception executing consequence for rule "final NON EC" in com.amazon.mobius.csi.workers.droolsengine: java.lang.NullPointerException
at org.drools.runtime.rule.impl.DefaultConsequenceExceptionHandler.handleException(DefaultConsequenceExceptionHandler.java:39)
at org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1101)
at org.drools.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:1029)
at org.drools.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1251)
at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:708)
at org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:672)
at org.drools.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:218)
at org.drools.impl.StatelessKnowledgeSessionImpl.execute(StatelessKnowledgeSessionImpl.java:295)
at com.amazon.mobius.csi.workers.droolsengine.DroolsEngineActivitiesImpl.runRules(DroolsEngineActivitiesImpl.java:216)
at com.amazon.mobius.csi.workers.droolsengine.DroolsEngineActivitiesImpl.executeRules(DroolsEngineActivitiesImpl.java:145)
at sun.reflect.GeneratedMethodAccessor173.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.amazonaws.services.simpleworkflow.flow.pojo.POJOActivityImplementation.execute(POJOActivityImplementation.java:63)
at com.amazonaws.services.simpleworkflow.flow.generic.ActivityImplementationBase.execute(ActivityImplementationBase.java:46)
at com.amazonaws.services.simpleworkflow.flow.worker.SynchronousActivityTaskPoller.execute(SynchronousActivityTaskPoller.java:214)
at com.amazonaws.services.simpleworkflow.flow.worker.ActivityTaskPoller$2.run(ActivityTaskPoller.java:95)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.NullPointerException
at com.amazon.mobius.csi.workers.droolsengine.Rule_final_NON_EC.defaultConsequence(Unknown Source)
at com.amazon.mobius.csi.workers.droolsengine.Rule_final_NON_ECDefaultConsequenceInvoker.evaluate(Unknown Source)
at org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:1091)
... 18 more
Why does Drools treat it as CYCLIC_DEPENDENCY and result into OOM? Could we have some other issue? Any help would be appreciated.
Thanks,
I believe this to be a cyclic dependency between rules. The RHS of one rule is causing another to activate, which in turn has a RHS which causes the first rule to activate. Therefore there is an infinite loop of rule activations.
Without seeing the rules themselves, I would recommend setting up an agenda event listener to log which rules are firing. That way you should be able to see which 2 rules are activating in this manner. An example such logging listener is here:
https://github.com/gratiartis/scattercode-drools-scenarios/blob/master/src/main/java/uk/co/scattercode/drools/util/TrackingAgendaEventListener.java