[jboss-jira] [JBoss JIRA] (DROOLS-4513) s2i build fails at KieServerContainerVerifier without appropriate logging when kmodule.xml schema validation fails

Filippe Spolti (Jira) issues at jboss.org
Tue Sep 24 14:02:00 EDT 2019


    [ https://issues.jboss.org/browse/DROOLS-4513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13788630#comment-13788630 ] 

Filippe Spolti commented on DROOLS-4513:
----------------------------------------

[~hiroko] thanks for the detailed info.

I made some changes on the xsd and a throw instruction was added, that way we can:

- have the listeners in any order.
- if the validation fails for some reason, the reason will be printed, like this example: 

{code:java}
XSD validation failed against the new schema (cvc-elt.1.a: Cannot find the declaration of element 'kmodule'.) and against the old schema (cvc-complex-type.2.4.a: Invalid content was found starting with element '{"http://jboss.org/kie/6.0.0/kmodule":listeners}'. One of '{"http://jboss.org/kie/6.0.0/kmodule":ksession}' is expected.).
{code}


> s2i build fails at KieServerContainerVerifier without appropriate logging when kmodule.xml schema validation fails
> ------------------------------------------------------------------------------------------------------------------
>
>                 Key: DROOLS-4513
>                 URL: https://issues.jboss.org/browse/DROOLS-4513
>             Project: Drools
>          Issue Type: Bug
>          Components: build, kie server
>    Affects Versions: 7.14.0.Final, 7.18.0.Final, 7.24.0.Final
>         Environment: OpenShift 3.11 with rhdm72-prod-immutable-kieserver.yaml/rhdm73-prod-immutable-kieserver.yaml
>            Reporter: Hiroko Miura
>            Assignee: Filippe Spolti
>            Priority: Major
>              Labels: support
>         Attachments: ruleTest.zip
>
>
> If multiple ksession are defined in kmodule.xml and Event Lister is set more than one ksession, s2i build fails at KieServerContainerVerifier with the following error.
> {noformat}
> [main] ERROR org.kie.server.services.impl.KieServerContainerVerifier - Cannot find KieModule: com.redhat.gss:ruleTest:1.0.0-SNAPSHOT
> java.lang.RuntimeException: Cannot find KieModule: com.redhat.gss:ruleTest:1.0.0-SNAPSHOT
>         at org.drools.compiler.kie.builder.impl.KieServicesImpl.newKieContainer(KieServicesImpl.java:186)
>         at org.drools.compiler.kie.builder.impl.KieServicesImpl.newKieContainer(KieServicesImpl.java:172)
>         at org.kie.server.services.impl.KieServerContainerVerifier.verify(KieServerContainerVerifier.java:65)
>         at org.kie.server.services.impl.KieServerContainerVerifier.verify(KieServerContainerVerifier.java:53)
>         at org.kie.server.services.impl.KieServerContainerVerifier.verify(KieServerContainerVerifier.java:40)
>         at org.kie.server.services.impl.KieServerContainerVerifier.main(KieServerContainerVerifier.java:119)
>         at org.kie.server.services.impl.KieServerContainerVerifier.main(KieServerContainerVerifier.java:101)
>         at org.jboss.modules.Module.run(Module.java:352)
>         at org.jboss.modules.Module.run(Module.java:320)
>         at org.jboss.modules.Main.main(Main.java:593)
> [main] ERROR org.kie.server.services.impl.KieServerContainerVerifier - com.redhat.gss:ruleTest:1.0.0-SNAPSHOT not verified.
> ERROR Aborting due to error code 1 from kie server container verification
> {noformat}



--
This message was sent by Atlassian Jira
(v7.13.8#713008)


More information about the jboss-jira mailing list