我试图从普通Java程序执行iLog jRules(7.1版)。我正在使用J2SE会话工厂。我还是得到了误差以下。有人能开导一下吗?还有,从java主方法执行jRules规则的最好和最简单的方法是什么?
6/9/14 4:48 PM [SEVERE] 10700 - -.- - Failed to check license ilog.rules.res.xu.IlrLocalizedResourceException: Failed to check license, error code: XU.ERROR.10700
at ilog.rules.res.xu.util.IlrResourceExceptionHelper.createResourceException(IlrResourceExceptionHelper.java:44)
at ilog.rules.res.xu.util.IlrResourceExceptionHelper.createResourceException(IlrResourceExceptionHelper.java:78)
at ilog.rules.res.xu.spi.IlrManagedXUConnectionFactory.verifyRESLicense(IlrManagedXUConnectionFactory.java:1108)
at ilog.rules.res.xu.spi.IlrManagedXUConnectionFactory.getRulesetProvider(IlrManagedXUConnectionFactory.java:883)
at ilog.rules.res.xu.spi.IlrManagedXUConnection.getRulesetProvider(IlrManagedXUConnection.java:280)
at ilog.rules.res.xu.spi.IlrManagedXUConnection.createEngineManager(IlrManagedXUConnection.java:1659)
at ilog.rules.res.xu.spi.IlrManagedXUConnection.getEngineManager(IlrManagedXUConnection.java:1591)
at ilog.rules.res.xu.spi.IlrManagedXUConnection.getRulesetParameters(IlrManagedXUConnection.java:1508)
at ilog.rules.res.xu.cci.IlrXUConnection.getRulesetParameters(IlrXUConnection.java:499)
at ilog.rules.res.xu.cci.IlrXUInteraction.getRulesetInformation(IlrXUInteraction.java:739)
at ilog.rules.res.xu.cci.IlrXUInteraction.dispatchExecution(IlrXUInteraction.java:185)
at ilog.rules.res.xu.cci.IlrXUInteraction.execute(IlrXUInteraction.java:343)
at ilog.rules.res.xu.cci.IlrXUInteraction.execute(IlrXUInteraction.java:459)
at ilog.rules.res.xu.cci.IlrCCIClient.executeInteraction(IlrCCIClient.java:189)
at ilog.rules.res.xu.cci.IlrCCIRuleEngineClient.getRulesetArchiveProperties(IlrCCIRuleEngineClient.java:699)
at ilog.rules.res.session.util.IlrTraceHelper.<init>(IlrTraceHelper.java:111)
at ilog.rules.res.session.impl.IlrStatelessSessionBase.execute(IlrStatelessSessionBase.java:97)
at poc.PojoClientRunnerImpl.executeentpocrules(PojoClientRunnerImpl.java:88)
at poc.Main.main(Main.java:28)
Caused by: ilog.jum.client700.IluSAMAccessDeniedException: At 2014-06-09 11:18:33 GMT, SAM 3.0.0.1040: Access denied to module 'RES4J'.
If you want to inspect your access key, please do the following:
java -cp [location]sam.jar ilog.jum.client700.IluSAMAccessKey -summary
我解决了这个问题。这是因为jar版本不匹配。我使用jRules Studio版本7.1.1,并使用jRules版本7.0.0 jar执行。
我修改了我的类路径,为jRules 7.1.1版本的rule studio使用7.1.1版本的jar。