Uploaded image for project: 'Drools'
  1. Drools
  2. DROOLS-1388

Drools Sample.drl broken with Eclipse Neon

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Major Major
    • None
    • 6.5.0.Final
    • eclipse plugin
    • None
    • Hide

      Just follow the steps described into the tutorial (and install the Drools plugin 6.4.0), then download a newer version and update the Drools plugin to the 6.5.0.Final.

      1. Create a new drools project
      2. Select the middle option proposed by eclipse the dialog box
      3. Enter "FirstProject" as a project name and keep only the "Add a sample Helloworld rule file to this project"
      4. Select DroolsTest class and "Run as Java Application"

      When you download a newer version of Eclipse Drools plugin, the update does not change Eclipse preferences "Installed Drools Runtimes" so, you're are still using to the old Drools runtimes.

      Show
      Just follow the steps described into the tutorial (and install the Drools plugin 6.4.0), then download a newer version and update the Drools plugin to the 6.5.0.Final. 1. Create a new drools project 2. Select the middle option proposed by eclipse the dialog box 3. Enter "FirstProject" as a project name and keep only the "Add a sample Helloworld rule file to this project" 4. Select DroolsTest class and "Run as Java Application" When you download a newer version of Eclipse Drools plugin, the update does not change Eclipse preferences "Installed Drools Runtimes" so, you're are still using to the old Drools runtimes.
    • The bug was related to a local misconfiguration
    • NEW
    • NEW

      Unable to complete the example presented in the documentation "Installing Drools Tooling"

      Trying to run DroolsTest.java sample I get the following errors:

      java.lang.RuntimeException: Error while creating KieBase[Message [id=1, level=ERROR, path=Sample.drl, line=15, column=0
         text=Rule Compilation error Only a type can be imported. com.sample.DroolsTest.Message resolves to a package
      Only a type can be imported. org.drools.core.spi.KnowledgeHelper resolves to a package
      KnowledgeHelper cannot be resolved to a type
      org.kie.api.runtime.rule.FactHandle cannot be resolved to a type
      java.lang.Exception cannot be resolved to a type
      org.kie.api.runtime.rule.RuleContext cannot be resolved to a type], Message [id=2, level=ERROR, path=Sample.drl, line=5, column=0
         text=Rule Compilation error Only a type can be imported. com.sample.DroolsTest.Message resolves to a package
      Only a type can be imported. org.drools.core.spi.KnowledgeHelper resolves to a package
      KnowledgeHelper cannot be resolved to a type
      com.sample.DroolsTest.Message cannot be resolved to a type
      org.kie.api.runtime.rule.FactHandle cannot be resolved to a type
      org.kie.api.runtime.rule.FactHandle cannot be resolved to a type
      java.lang.Exception cannot be resolved to a type
      org.kie.api.runtime.rule.RuleContext cannot be resolved to a type
      Message.GOODBYE cannot be resolved to a type
      org.drools.core.util.bitmask.AllSetBitMask cannot be resolved to a type
      com.sample.DroolsTest.Message cannot be resolved to a type]]
      	at org.drools.compiler.kie.builder.impl.KieContainerImpl.getKieBase(KieContainerImpl.java:450)
      	at org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:604)
      	at org.drools.compiler.kie.builder.impl.KieContainerImpl.newKieSession(KieContainerImpl.java:575)
      	at com.sample.DroolsTest.main(DroolsTest.java:17)
      

              bbrodt_jira Robert (Bob) Brodt (Inactive)
              freedev_jira Vincenzo D'Amore (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: