6 Replies Latest reply: Sep 13, 2012 6:11 AM by 956042 RSS

    Repeat: Module building

    956042
      Hi,

      I'm re-posting this thread just to make sure that the previous thread is dead.

      I added lot of random comments in the previous thread as I was unaware of the exact problem. Now I have recognized it to some extent.

      I have many attributes under an entity <x> in project <p1>. Some of them have public names.

      Build->Build module gave many warnings in <p1>. I tried to add link of <p1> module in another project <p2>. It was added successfully. However, I received the following error in Embedded web server output:
      "Error (re)loading rulebase 'xxxx': attribute 'b198@yyyyyy_doc' does not exist in entity 'global' in module 'zzzzzzzz <module name>' "

      However, the attribute yyyyyy is supposed to be in entity <x> (AND NOT IN GLOBAL) in project <p1>.

      Kindly help me with this problem.
      PS: I have added entity <x> in properties file of <p1> also. It has identifying attribute only.

      Thanks,
      Naveen
        • 1. Re: Repeat: Module building
          956042
          Seems to be working after removing public names of all attributes in the entity <x>
          • 2. Re: Repeat: Module building
            956042
            New problem now: Some of the attributes in entity <x> are not getting exported.

            Warning: The attribute 'p22@propertiesfile_xsrc' has not been exported. This means attribute '<top goal>' may not be provable in any rulebase that uses this module.
            • 3. Re: Repeat: Module building
              Matt Sevin-Oracle
              Only attributes, entities, etc. with public names will be exported. Exporting something that is inferred without exporting the necessary/supporting base level entities and attributes is not usually useful nor a good design choice (thus the warning). See the following topics in the help for detailed explanations / requirements, etc. when using modules:

              - Create rules that can be shared with another project .. which contains:
              During a module build, there are two classes of module specific warnings that may be displayed:
              Warnings caused by an entity, attribute or relationship that has a public name but cannot be exported for some other reason (see above).
              Warnings to indicate that a base level entity, attribute or relationship that participates in the proof of an exported inferred entity, attribute or relationship is not itself exported.

              These warnings can be ignored, but may result in unintended behavior of the module.

              - Include rules defined in a separate project

              Modules should be used to define a specific "interface" (i.e. a set of attributes and entities to be collected and the rules which determine a set of inferred attributes, etc.). That "interface" can then be imported as a module into another project but the project importing the module may only reference the imported attributes, not change them in anyway nor can it define new rules to infer imported attributes.
              • 4. Re: Repeat: Module building
                956042
                I have worked on the issues and reduced the number of warnings to zero. However, I'm still getting a runtime error:

                Embedded web server output:
                1 [Thread-1] ERROR com.oracle.determinations.interview.engine.RulebaseService - Error (re)loading rulebase '<rulebase name>': attribute 'b196@Properties_<module>_xsrc' does not exist in entity 'global' in module '<module name>'
                com.oracle.determinations.engine.exceptions.RulebaseLoadException: attribute 'b196@Properties_<module>_xsrc' does not exist in entity 'global' in module '<module name>'
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:148)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.writeRules(VirtualRulebaseCoreWriter.java:104)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.writeRules(VirtualRulebaseCoreWriter.java:109)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.createRulebaseXmlFile(VirtualRulebaseCoreWriter.java:48)
                     at com.oracle.determinations.engine.local.modules.ModuleLoader.writeVirtualRulebase(ModuleLoader.java:335)
                     at com.oracle.determinations.engine.local.modules.ModuleLoader.createUnifiedRulebase(ModuleLoader.java:36)
                     at com.oracle.determinations.engine.local.RulebaseLoader.createUnifiedRulebase(RulebaseLoader.java:141)
                     at com.oracle.determinations.interview.engine.local.LocalRulebaseService.applyChangeSet(LocalRulebaseService.java:243)
                     at com.oracle.determinations.interview.engine.plugins.rulebaseresolver.ClassloaderRulebaseResolverPlugin.initialise(ClassloaderRulebaseResolverPlugin.java:73)
                     at com.oracle.determinations.interview.engine.local.LocalRulebaseService.<init>(LocalRulebaseService.java:53)
                     at com.oracle.determinations.interview.engine.local.LocalInterviewEngine.initialise(LocalInterviewEngine.java:181)
                     at com.oracle.determinations.interview.engine.local.LocalInterviewEngine.<init>(LocalInterviewEngine.java:66)
                     at com.oracle.determinations.interview.engine.InterviewEngineFactory.createInstance(InterviewEngineFactory.java:19)
                     at com.oracle.determinations.web.platform.servlet.WebDeterminationsServletContext.init(WebDeterminationsServletContext.java:180)
                     at com.oracle.determinations.web.platform.servlet.WebDeterminationsServletContext.<init>(WebDeterminationsServletContext.java:116)
                     at com.oracle.determinations.web.platform.servlet.WebDeterminationsServlet.init(WebDeterminationsServlet.java:73)
                     at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1139)
                     at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:966)
                     at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3996)
                     at org.apache.catalina.core.StandardContext.start(StandardContext.java:4266)
                     at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:760)
                     at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:740)
                     at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:544)
                     at com.oracle.util.LightWeightWebRunner.addChildContext(LightWeightWebRunner.java:155)
                     at com.oracle.util.LightWeightWebRunner.runServer(LightWeightWebRunner.java:134)
                     at com.oracle.util.LightWeightWebRunner.run(LightWeightWebRunner.java:197)
                     at java.lang.Thread.run(Unknown Source)

                OK - Tomcat server started
                8004 [http-127.0.0.1-9000-Processor4] ERROR com.oracle.determinations.web.platform.templatingengine.ErrorRenderer - Rulebase '<rulebase name>' can not be loaded.
                com.oracle.determinations.interview.engine.exceptions.RulebaseLoadingException: Rulebase '<rulebase name>' can not be loaded.
                     at com.oracle.determinations.interview.engine.local.LocalRulebaseService.getRulebase(LocalRulebaseService.java:99)
                     at com.oracle.determinations.web.platform.controller.actions.StartSessionAction.getInterviewRulebase(StartSessionAction.java:195)
                     at com.oracle.determinations.web.platform.controller.actions.StartSessionAction.getResource(StartSessionAction.java:67)
                     at com.oracle.determinations.web.platform.servlet.WebDeterminationsServlet.doGet(WebDeterminationsServlet.java:112)
                     at javax.servlet.http.HttpServlet.service(HttpServlet.java:627)
                     at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
                     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
                     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
                     at com.oracle.determinations.web.platform.util.CharsetFilter.doFilter(CharsetFilter.java:46)
                     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
                     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
                     at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
                     at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
                     at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
                     at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
                     at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
                     at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
                     at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:879)
                     at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
                     at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
                     at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
                     at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
                     at java.lang.Thread.run(Unknown Source)
                Caused by: com.oracle.determinations.engine.exceptions.RulebaseLoadException: attribute 'b196@Properties_<module>_xsrc' does not exist in entity 'global' in module '<module name>'
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:148)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.resolveRuleRefs(VirtualRulebaseCoreWriter.java:232)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.writeRules(VirtualRulebaseCoreWriter.java:104)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.writeRules(VirtualRulebaseCoreWriter.java:109)
                     at com.oracle.determinations.engine.local.modules.VirtualRulebaseCoreWriter.createRulebaseXmlFile(VirtualRulebaseCoreWriter.java:48)
                     at com.oracle.determinations.engine.local.modules.ModuleLoader.writeVirtualRulebase(ModuleLoader.java:335)
                     at com.oracle.determinations.engine.local.modules.ModuleLoader.createUnifiedRulebase(ModuleLoader.java:36)
                     at com.oracle.determinations.engine.local.RulebaseLoader.createUnifiedRulebase(RulebaseLoader.java:141)
                     at com.oracle.determinations.interview.engine.local.LocalRulebaseService.getRulebase(LocalRulebaseService.java:93)
                     ... 22 more

                Edited by: Naveen Mathew on Sep 12, 2012 12:37 AM
                • 5. Re: Repeat: Module building
                  Kristy Van Der Vlist
                  It looks like the module resolver in the engine isn't identifying the correct entity the local attribute belongs to. It might be possible to resolve the issue by sticking a public name on the attribute "b196@Properties_<module>_xsrc". You may also be able to work around it by re-structuring your rule that uses it slightly differently, but I'd actually need to see the rule to give you more advice on this.

                  If you can, please raise an SR so that we can better track the issue. When you do please be sure to add a complete set of projects that reproduces your problem.
                  • 6. Re: Repeat: Module building
                    956042
                    To be precise, the entity to which the attribute belongs is not being determined correctly.

                    Adding public name in the respective project does not solve the problem. That attribute belongs to entity <x> and not global.

                    Edited by: Naveen Mathew on Sep 13, 2012 4:11 AM