[jboss-jira] [JBoss JIRA] (DROOLS-1250) Drools Sample.drl is broken

Tianwei Chen (JIRA) issues at jboss.org
Mon Aug 15 13:11:00 EDT 2016


     [ https://issues.jboss.org/browse/DROOLS-1250?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Tianwei Chen closed DROOLS-1250.
--------------------------------
    Resolution: Done


> Drools Sample.drl is broken
> ---------------------------
>
>                 Key: DROOLS-1250
>                 URL: https://issues.jboss.org/browse/DROOLS-1250
>             Project: Drools
>          Issue Type: Feature Request
>          Components: eclipse plugin
>    Affects Versions: 6.4.0.Final
>            Reporter: Tianwei Chen
>            Assignee: Robert (Bob) Brodt
>
> Hello, I use drools plugin (6.4.0.Final) in Eclipse Neon. I followed the wizard to create a drools project with some example files. After the step were done, Eclipse highlighted errors at the two rules in the Sample.drl file. Here is one of the errors:
> Multiple markers at this line
> - com.sample.DroolsTest.Message cannot be resolved to a type
> - org.drools.core.util.bitmask.AllSetBitMask cannot be resolved to a type
> - Only a type can be imported. com.sample.DroolsTest.Message resolves to a package
> - org.kie.api.runtime.rule.FactHandle cannot be resolved to a type
> - KnowledgeHelper cannot be resolved to a type
> - Only a type can be imported. org.drools.core.spi.KnowledgeHelper resolves to a package
> - Message.GOODBYE cannot be resolved to a type
> - org.kie.api.runtime.rule.RuleContext cannot be resolved to a type
> - java.lang.Exception cannot be resolved to a type
> When I ran DroolsTest.java, I got the following error:
> 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)
> It seems like an library path issue. Please help!
> Thank you very much!
> Tianwei Chen



--
This message was sent by Atlassian JIRA
(v6.4.11#64026)


More information about the jboss-jira mailing list