[JBoss JIRA] (WFLY-11996) A singleton can not add a init-method via ejb-jar.xml descriptor because it fail with Parser Exception
by Cheng Fang (Jira)
[ https://issues.jboss.org/browse/WFLY-11996?page=com.atlassian.jira.plugin... ]
Cheng Fang resolved WFLY-11996.
-------------------------------
Resolution: Explained
> A singleton can not add a init-method via ejb-jar.xml descriptor because it fail with Parser Exception
> ------------------------------------------------------------------------------------------------------
>
> Key: WFLY-11996
> URL: https://issues.jboss.org/browse/WFLY-11996
> Project: WildFly
> Issue Type: Bug
> Components: EJB
> Affects Versions: 17.0.0.Beta1
> Reporter: Wolf-Dieter Fink
> Assignee: Cheng Fang
> Priority: Major
>
> If a Singelton EJB should be created without annotation and use ejb-jar.xml to declare it this will work for mostly all but not for init-method element.
> The class is a POJO without annotations, the ejb-jar.xml looks like followed
> ------
> <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_2.xsd" version="3.2">
> <enterprise-beans>
> <session>
> <ejb-name>StartupSingletonBean</ejb-name>
> <display-name>JBossInit</display-name>
> <description>JBoss startup class</description>
> <ejb-class>org.jboss.wfink.ejb31.singleton.StartupSingletonBean</ejb-class>
> <session-type>Singleton</session-type>
> <init-on-startup>true</init-on-startup>
> <init-method>test23</init-method>
> --- > this is where the Exception row/col point to
> <env-entry>
> <description>an example for a environment value</description>
> <env-entry-name>myString</env-entry-name>
> <env-entry-type>java.lang.String</env-entry-type>
> <env-entry-value>MyString from the ejb-jar.xml :)</env-entry-value>
> </env-entry>
> </session>
> </enterprise-beans>
> .....
> --------
> The Exception is this:
> 15:27:29,450 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-3) MSC000001: Failed to start service jboss.deployment.subunit."simpleEJB31.ear"."ejb.jar".PARSE: org.jboss.msc.service.StartException in service jboss.deployment.subunit."simpleEJB31.ear"."ejb.jar".PARSE: WFLYSRV0153: Failed to process phase PARSE of subdeployment "ejb.jar" of deployment "simpleEJB31.ear"
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:183)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1738)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1700)
> at org.jboss.msc.service.ServiceControllerImpl$ControllerTask.run(ServiceControllerImpl.java:1558)
> at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
> at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1982)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1486)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1377)
> at java.lang.Thread.run(Thread.java:748)
> Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: WFLYEJB0085: Exception while parsing ejb-jar.xml: /content/simpleEJB31.ear/ejb.jar/META-INF/ejb-jar.xml
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.parseEjbJarXml(EjbJarParsingDeploymentUnitProcessor.java:275)
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.deploy(EjbJarParsingDeploymentUnitProcessor.java:126)
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:176)
> ... 8 more
> Caused by: com.ctc.wstx.exc.WstxParsingException: Received non-all-whitespace CHARACTERS or CDATA event in nextTag().
> at [row,col {unknown-source}]: [18,25]
> at com.ctc.wstx.sr.StreamScanner.constructWfcException(StreamScanner.java:621)
> at com.ctc.wstx.sr.StreamScanner.throwParseError(StreamScanner.java:491)
> at com.ctc.wstx.sr.StreamScanner.throwParseError(StreamScanner.java:475)
> at com.ctc.wstx.sr.BasicStreamReader.nextTag(BasicStreamReader.java:1224)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:64)
> at org.jboss.metadata.ejb.parser.spec.InitMethodMetaDataParser.parse(InitMethodMetaDataParser.java:55)
> at org.jboss.metadata.ejb.parser.spec.SessionBean30MetaDataParser.processElement(SessionBean30MetaDataParser.java:104)
> at org.jboss.metadata.ejb.parser.spec.SessionBean31MetaDataParser.processElement(SessionBean31MetaDataParser.java:143)
> at org.jboss.metadata.ejb.parser.spec.SessionBean32MetaDataParser.processElement(SessionBean32MetaDataParser.java:54)
> at org.jboss.metadata.ejb.parser.spec.SessionBean32MetaDataParser.processElement(SessionBean32MetaDataParser.java:36)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.SessionBeanMetaDataParser.parse(SessionBeanMetaDataParser.java:81)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.processElement(EnterpriseBeansMetaDataParser.java:87)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.processElement(EnterpriseBeansMetaDataParser.java:39)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.parse(EnterpriseBeansMetaDataParser.java:72)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.parse(EnterpriseBeansMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.AbstractEjbJarMetaDataParser.processElement(AbstractEjbJarMetaDataParser.java:98)
> at org.jboss.metadata.ejb.parser.spec.AbstractEjbJarMetaDataParser.processElement(AbstractEjbJarMetaDataParser.java:43)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.EjbJarMetaDataParser.parseDocument(EjbJarMetaDataParser.java:101)
> at org.jboss.metadata.ejb.parser.spec.EjbJarMetaDataParser.parse(EjbJarMetaDataParser.java:51)
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.parseEjbJarXml(EjbJarParsingDeploymentUnitProcessor.java:272)
> ... 10 more
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
7 years, 3 months
[JBoss JIRA] (WFLY-11996) A singleton can not add a init-method via ejb-jar.xml descriptor because it fail with Parser Exception
by Cheng Fang (Jira)
[ https://issues.jboss.org/browse/WFLY-11996?page=com.atlassian.jira.plugin... ]
Cheng Fang edited comment on WFLY-11996 at 4/18/19 3:17 PM:
------------------------------------------------------------
the correct ejb-jar.xml should be:
{code:xml}
<ejb-jar xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/ejb-jar_3_2.xsd" version="3.2">
<enterprise-beans>
<session>
<description>JBoss startup class</description>
<display-name>JBossInit</display-name>
<ejb-name>Counter</ejb-name>
<ejb-class> org.jboss.wfink.ejb31.singleton.StartupSingletonBean </ejb-class>
<session-type>Singleton</session-type>
<init-on-startup>true</init-on-startup>
<!-- <init-method>test23</init-method>-->
<env-entry>
<description>an example for a environment value</description>
<env-entry-name>myString</env-entry-name>
<env-entry-type>java.lang.String</env-entry-type>
<env-entry-value>MyString from the ejb-jar.xml</env-entry-value>
</env-entry>
<post-construct>
<lifecycle-callback-method>test23</lifecycle-callback-method>
</post-construct>
</session>
</enterprise-beans>
</ejb-jar>
{code}
Note the use of post-construct element, instead of init-method element. With the above corrected deployment descriptor, my test app of a plain POJO singleton ejb worked.
Per ejb-jar_3_2.xsd schema:
The init-method element specifies the mappings for
EJB 2.x style create methods for an EJB 3.x bean.
This element can only be specified for stateful
session beans.
was (Author: cfang):
the correct ejb-jar.xml should be:
{code:xml}
<ejb-jar xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/ejb-jar_3_2.xsd" version="3.2">
<enterprise-beans>
<session>
<description>JBoss startup class</description>
<display-name>JBossInit</display-name>
<ejb-name>Counter</ejb-name>
<ejb-class> org.jboss.wfink.ejb31.singleton.StartupSingletonBean </ejb-class>
<session-type>Singleton</session-type>
<init-on-startup>true</init-on-startup>
<!-- <init-method>test23</init-method>-->
<env-entry>
<description>an example for a environment value</description>
<env-entry-name>myString</env-entry-name>
<env-entry-type>java.lang.String</env-entry-type>
<env-entry-value>MyString from the ejb-jar.xml</env-entry-value>
</env-entry>
<post-construct>
<lifecycle-callback-method>test23</lifecycle-callback-method>
</post-construct>
</session>
</enterprise-beans>
</ejb-jar>
{code}
> A singleton can not add a init-method via ejb-jar.xml descriptor because it fail with Parser Exception
> ------------------------------------------------------------------------------------------------------
>
> Key: WFLY-11996
> URL: https://issues.jboss.org/browse/WFLY-11996
> Project: WildFly
> Issue Type: Bug
> Components: EJB
> Affects Versions: 17.0.0.Beta1
> Reporter: Wolf-Dieter Fink
> Assignee: Cheng Fang
> Priority: Major
>
> If a Singelton EJB should be created without annotation and use ejb-jar.xml to declare it this will work for mostly all but not for init-method element.
> The class is a POJO without annotations, the ejb-jar.xml looks like followed
> ------
> <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_2.xsd" version="3.2">
> <enterprise-beans>
> <session>
> <ejb-name>StartupSingletonBean</ejb-name>
> <display-name>JBossInit</display-name>
> <description>JBoss startup class</description>
> <ejb-class>org.jboss.wfink.ejb31.singleton.StartupSingletonBean</ejb-class>
> <session-type>Singleton</session-type>
> <init-on-startup>true</init-on-startup>
> <init-method>test23</init-method>
> --- > this is where the Exception row/col point to
> <env-entry>
> <description>an example for a environment value</description>
> <env-entry-name>myString</env-entry-name>
> <env-entry-type>java.lang.String</env-entry-type>
> <env-entry-value>MyString from the ejb-jar.xml :)</env-entry-value>
> </env-entry>
> </session>
> </enterprise-beans>
> .....
> --------
> The Exception is this:
> 15:27:29,450 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-3) MSC000001: Failed to start service jboss.deployment.subunit."simpleEJB31.ear"."ejb.jar".PARSE: org.jboss.msc.service.StartException in service jboss.deployment.subunit."simpleEJB31.ear"."ejb.jar".PARSE: WFLYSRV0153: Failed to process phase PARSE of subdeployment "ejb.jar" of deployment "simpleEJB31.ear"
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:183)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1738)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1700)
> at org.jboss.msc.service.ServiceControllerImpl$ControllerTask.run(ServiceControllerImpl.java:1558)
> at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
> at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1982)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1486)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1377)
> at java.lang.Thread.run(Thread.java:748)
> Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: WFLYEJB0085: Exception while parsing ejb-jar.xml: /content/simpleEJB31.ear/ejb.jar/META-INF/ejb-jar.xml
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.parseEjbJarXml(EjbJarParsingDeploymentUnitProcessor.java:275)
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.deploy(EjbJarParsingDeploymentUnitProcessor.java:126)
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:176)
> ... 8 more
> Caused by: com.ctc.wstx.exc.WstxParsingException: Received non-all-whitespace CHARACTERS or CDATA event in nextTag().
> at [row,col {unknown-source}]: [18,25]
> at com.ctc.wstx.sr.StreamScanner.constructWfcException(StreamScanner.java:621)
> at com.ctc.wstx.sr.StreamScanner.throwParseError(StreamScanner.java:491)
> at com.ctc.wstx.sr.StreamScanner.throwParseError(StreamScanner.java:475)
> at com.ctc.wstx.sr.BasicStreamReader.nextTag(BasicStreamReader.java:1224)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:64)
> at org.jboss.metadata.ejb.parser.spec.InitMethodMetaDataParser.parse(InitMethodMetaDataParser.java:55)
> at org.jboss.metadata.ejb.parser.spec.SessionBean30MetaDataParser.processElement(SessionBean30MetaDataParser.java:104)
> at org.jboss.metadata.ejb.parser.spec.SessionBean31MetaDataParser.processElement(SessionBean31MetaDataParser.java:143)
> at org.jboss.metadata.ejb.parser.spec.SessionBean32MetaDataParser.processElement(SessionBean32MetaDataParser.java:54)
> at org.jboss.metadata.ejb.parser.spec.SessionBean32MetaDataParser.processElement(SessionBean32MetaDataParser.java:36)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.SessionBeanMetaDataParser.parse(SessionBeanMetaDataParser.java:81)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.processElement(EnterpriseBeansMetaDataParser.java:87)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.processElement(EnterpriseBeansMetaDataParser.java:39)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.parse(EnterpriseBeansMetaDataParser.java:72)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.parse(EnterpriseBeansMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.AbstractEjbJarMetaDataParser.processElement(AbstractEjbJarMetaDataParser.java:98)
> at org.jboss.metadata.ejb.parser.spec.AbstractEjbJarMetaDataParser.processElement(AbstractEjbJarMetaDataParser.java:43)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.EjbJarMetaDataParser.parseDocument(EjbJarMetaDataParser.java:101)
> at org.jboss.metadata.ejb.parser.spec.EjbJarMetaDataParser.parse(EjbJarMetaDataParser.java:51)
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.parseEjbJarXml(EjbJarParsingDeploymentUnitProcessor.java:272)
> ... 10 more
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
7 years, 3 months
[JBoss JIRA] (WFLY-11996) A singleton can not add a init-method via ejb-jar.xml descriptor because it fail with Parser Exception
by Cheng Fang (Jira)
[ https://issues.jboss.org/browse/WFLY-11996?page=com.atlassian.jira.plugin... ]
Cheng Fang edited comment on WFLY-11996 at 4/18/19 3:14 PM:
------------------------------------------------------------
the correct ejb-jar.xml should be:
{code:xml}
<ejb-jar xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/ejb-jar_3_2.xsd" version="3.2">
<enterprise-beans>
<session>
<description>JBoss startup class</description>
<display-name>JBossInit</display-name>
<ejb-name>Counter</ejb-name>
<ejb-class> org.jboss.wfink.ejb31.singleton.StartupSingletonBean </ejb-class>
<session-type>Singleton</session-type>
<init-on-startup>true</init-on-startup>
<!-- <init-method>test23</init-method>-->
<env-entry>
<description>an example for a environment value</description>
<env-entry-name>myString</env-entry-name>
<env-entry-type>java.lang.String</env-entry-type>
<env-entry-value>MyString from the ejb-jar.xml</env-entry-value>
</env-entry>
<post-construct>
<lifecycle-callback-method>test23</lifecycle-callback-method>
</post-construct>
</session>
</enterprise-beans>
</ejb-jar>
{code}
was (Author: cfang):
the correct ejb-jar.xml should be:
{code:xml}
<ejb-jar xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/ejb-jar_3_2.xsd" version="3.2">
<enterprise-beans>
<session>
<description>JBoss startup class</description>
<display-name>JBossInit</display-name>
<ejb-name>Counter</ejb-name>
<ejb-class>org.jboss.as.quickstarts.singleton.Counter</ejb-class>
<session-type>Singleton</session-type>
<init-on-startup>true</init-on-startup>
<!-- <init-method>test23</init-method>-->
<env-entry>
<description>an example for a environment value</description>
<env-entry-name>myString</env-entry-name>
<env-entry-type>java.lang.String</env-entry-type>
<env-entry-value>MyString from the ejb-jar.xml</env-entry-value>
</env-entry>
<post-construct>
<lifecycle-callback-method>test23</lifecycle-callback-method>
</post-construct>
</session>
</enterprise-beans>
</ejb-jar>
{code}
> A singleton can not add a init-method via ejb-jar.xml descriptor because it fail with Parser Exception
> ------------------------------------------------------------------------------------------------------
>
> Key: WFLY-11996
> URL: https://issues.jboss.org/browse/WFLY-11996
> Project: WildFly
> Issue Type: Bug
> Components: EJB
> Affects Versions: 17.0.0.Beta1
> Reporter: Wolf-Dieter Fink
> Assignee: Cheng Fang
> Priority: Major
>
> If a Singelton EJB should be created without annotation and use ejb-jar.xml to declare it this will work for mostly all but not for init-method element.
> The class is a POJO without annotations, the ejb-jar.xml looks like followed
> ------
> <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_2.xsd" version="3.2">
> <enterprise-beans>
> <session>
> <ejb-name>StartupSingletonBean</ejb-name>
> <display-name>JBossInit</display-name>
> <description>JBoss startup class</description>
> <ejb-class>org.jboss.wfink.ejb31.singleton.StartupSingletonBean</ejb-class>
> <session-type>Singleton</session-type>
> <init-on-startup>true</init-on-startup>
> <init-method>test23</init-method>
> --- > this is where the Exception row/col point to
> <env-entry>
> <description>an example for a environment value</description>
> <env-entry-name>myString</env-entry-name>
> <env-entry-type>java.lang.String</env-entry-type>
> <env-entry-value>MyString from the ejb-jar.xml :)</env-entry-value>
> </env-entry>
> </session>
> </enterprise-beans>
> .....
> --------
> The Exception is this:
> 15:27:29,450 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-3) MSC000001: Failed to start service jboss.deployment.subunit."simpleEJB31.ear"."ejb.jar".PARSE: org.jboss.msc.service.StartException in service jboss.deployment.subunit."simpleEJB31.ear"."ejb.jar".PARSE: WFLYSRV0153: Failed to process phase PARSE of subdeployment "ejb.jar" of deployment "simpleEJB31.ear"
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:183)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1738)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1700)
> at org.jboss.msc.service.ServiceControllerImpl$ControllerTask.run(ServiceControllerImpl.java:1558)
> at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
> at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1982)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1486)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1377)
> at java.lang.Thread.run(Thread.java:748)
> Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: WFLYEJB0085: Exception while parsing ejb-jar.xml: /content/simpleEJB31.ear/ejb.jar/META-INF/ejb-jar.xml
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.parseEjbJarXml(EjbJarParsingDeploymentUnitProcessor.java:275)
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.deploy(EjbJarParsingDeploymentUnitProcessor.java:126)
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:176)
> ... 8 more
> Caused by: com.ctc.wstx.exc.WstxParsingException: Received non-all-whitespace CHARACTERS or CDATA event in nextTag().
> at [row,col {unknown-source}]: [18,25]
> at com.ctc.wstx.sr.StreamScanner.constructWfcException(StreamScanner.java:621)
> at com.ctc.wstx.sr.StreamScanner.throwParseError(StreamScanner.java:491)
> at com.ctc.wstx.sr.StreamScanner.throwParseError(StreamScanner.java:475)
> at com.ctc.wstx.sr.BasicStreamReader.nextTag(BasicStreamReader.java:1224)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:64)
> at org.jboss.metadata.ejb.parser.spec.InitMethodMetaDataParser.parse(InitMethodMetaDataParser.java:55)
> at org.jboss.metadata.ejb.parser.spec.SessionBean30MetaDataParser.processElement(SessionBean30MetaDataParser.java:104)
> at org.jboss.metadata.ejb.parser.spec.SessionBean31MetaDataParser.processElement(SessionBean31MetaDataParser.java:143)
> at org.jboss.metadata.ejb.parser.spec.SessionBean32MetaDataParser.processElement(SessionBean32MetaDataParser.java:54)
> at org.jboss.metadata.ejb.parser.spec.SessionBean32MetaDataParser.processElement(SessionBean32MetaDataParser.java:36)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.SessionBeanMetaDataParser.parse(SessionBeanMetaDataParser.java:81)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.processElement(EnterpriseBeansMetaDataParser.java:87)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.processElement(EnterpriseBeansMetaDataParser.java:39)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.parse(EnterpriseBeansMetaDataParser.java:72)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.parse(EnterpriseBeansMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.AbstractEjbJarMetaDataParser.processElement(AbstractEjbJarMetaDataParser.java:98)
> at org.jboss.metadata.ejb.parser.spec.AbstractEjbJarMetaDataParser.processElement(AbstractEjbJarMetaDataParser.java:43)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.EjbJarMetaDataParser.parseDocument(EjbJarMetaDataParser.java:101)
> at org.jboss.metadata.ejb.parser.spec.EjbJarMetaDataParser.parse(EjbJarMetaDataParser.java:51)
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.parseEjbJarXml(EjbJarParsingDeploymentUnitProcessor.java:272)
> ... 10 more
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
7 years, 3 months
[JBoss JIRA] (WFLY-11996) A singleton can not add a init-method via ejb-jar.xml descriptor because it fail with Parser Exception
by Cheng Fang (Jira)
[ https://issues.jboss.org/browse/WFLY-11996?page=com.atlassian.jira.plugin... ]
Cheng Fang commented on WFLY-11996:
-----------------------------------
the correct ejb-jar.xml should be:
{code:xml}
<ejb-jar xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/ejb-jar_3_2.xsd" version="3.2">
<enterprise-beans>
<session>
<description>JBoss startup class</description>
<display-name>JBossInit</display-name>
<ejb-name>Counter</ejb-name>
<ejb-class>org.jboss.as.quickstarts.singleton.Counter</ejb-class>
<session-type>Singleton</session-type>
<init-on-startup>true</init-on-startup>
<!-- <init-method>test23</init-method>-->
<env-entry>
<description>an example for a environment value</description>
<env-entry-name>myString</env-entry-name>
<env-entry-type>java.lang.String</env-entry-type>
<env-entry-value>MyString from the ejb-jar.xml</env-entry-value>
</env-entry>
<post-construct>
<lifecycle-callback-method>test23</lifecycle-callback-method>
</post-construct>
</session>
</enterprise-beans>
</ejb-jar>
{code}
> A singleton can not add a init-method via ejb-jar.xml descriptor because it fail with Parser Exception
> ------------------------------------------------------------------------------------------------------
>
> Key: WFLY-11996
> URL: https://issues.jboss.org/browse/WFLY-11996
> Project: WildFly
> Issue Type: Bug
> Components: EJB
> Affects Versions: 17.0.0.Beta1
> Reporter: Wolf-Dieter Fink
> Assignee: Cheng Fang
> Priority: Major
>
> If a Singelton EJB should be created without annotation and use ejb-jar.xml to declare it this will work for mostly all but not for init-method element.
> The class is a POJO without annotations, the ejb-jar.xml looks like followed
> ------
> <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_2.xsd" version="3.2">
> <enterprise-beans>
> <session>
> <ejb-name>StartupSingletonBean</ejb-name>
> <display-name>JBossInit</display-name>
> <description>JBoss startup class</description>
> <ejb-class>org.jboss.wfink.ejb31.singleton.StartupSingletonBean</ejb-class>
> <session-type>Singleton</session-type>
> <init-on-startup>true</init-on-startup>
> <init-method>test23</init-method>
> --- > this is where the Exception row/col point to
> <env-entry>
> <description>an example for a environment value</description>
> <env-entry-name>myString</env-entry-name>
> <env-entry-type>java.lang.String</env-entry-type>
> <env-entry-value>MyString from the ejb-jar.xml :)</env-entry-value>
> </env-entry>
> </session>
> </enterprise-beans>
> .....
> --------
> The Exception is this:
> 15:27:29,450 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-3) MSC000001: Failed to start service jboss.deployment.subunit."simpleEJB31.ear"."ejb.jar".PARSE: org.jboss.msc.service.StartException in service jboss.deployment.subunit."simpleEJB31.ear"."ejb.jar".PARSE: WFLYSRV0153: Failed to process phase PARSE of subdeployment "ejb.jar" of deployment "simpleEJB31.ear"
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:183)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1738)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1700)
> at org.jboss.msc.service.ServiceControllerImpl$ControllerTask.run(ServiceControllerImpl.java:1558)
> at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
> at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1982)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1486)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1377)
> at java.lang.Thread.run(Thread.java:748)
> Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: WFLYEJB0085: Exception while parsing ejb-jar.xml: /content/simpleEJB31.ear/ejb.jar/META-INF/ejb-jar.xml
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.parseEjbJarXml(EjbJarParsingDeploymentUnitProcessor.java:275)
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.deploy(EjbJarParsingDeploymentUnitProcessor.java:126)
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:176)
> ... 8 more
> Caused by: com.ctc.wstx.exc.WstxParsingException: Received non-all-whitespace CHARACTERS or CDATA event in nextTag().
> at [row,col {unknown-source}]: [18,25]
> at com.ctc.wstx.sr.StreamScanner.constructWfcException(StreamScanner.java:621)
> at com.ctc.wstx.sr.StreamScanner.throwParseError(StreamScanner.java:491)
> at com.ctc.wstx.sr.StreamScanner.throwParseError(StreamScanner.java:475)
> at com.ctc.wstx.sr.BasicStreamReader.nextTag(BasicStreamReader.java:1224)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:64)
> at org.jboss.metadata.ejb.parser.spec.InitMethodMetaDataParser.parse(InitMethodMetaDataParser.java:55)
> at org.jboss.metadata.ejb.parser.spec.SessionBean30MetaDataParser.processElement(SessionBean30MetaDataParser.java:104)
> at org.jboss.metadata.ejb.parser.spec.SessionBean31MetaDataParser.processElement(SessionBean31MetaDataParser.java:143)
> at org.jboss.metadata.ejb.parser.spec.SessionBean32MetaDataParser.processElement(SessionBean32MetaDataParser.java:54)
> at org.jboss.metadata.ejb.parser.spec.SessionBean32MetaDataParser.processElement(SessionBean32MetaDataParser.java:36)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.SessionBeanMetaDataParser.parse(SessionBeanMetaDataParser.java:81)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.processElement(EnterpriseBeansMetaDataParser.java:87)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.processElement(EnterpriseBeansMetaDataParser.java:39)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.parse(EnterpriseBeansMetaDataParser.java:72)
> at org.jboss.metadata.ejb.parser.spec.EnterpriseBeansMetaDataParser.parse(EnterpriseBeansMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.AbstractEjbJarMetaDataParser.processElement(AbstractEjbJarMetaDataParser.java:98)
> at org.jboss.metadata.ejb.parser.spec.AbstractEjbJarMetaDataParser.processElement(AbstractEjbJarMetaDataParser.java:43)
> at org.jboss.metadata.ejb.parser.spec.AbstractMetaDataParser.processElements(AbstractMetaDataParser.java:65)
> at org.jboss.metadata.ejb.parser.spec.EjbJarMetaDataParser.parseDocument(EjbJarMetaDataParser.java:101)
> at org.jboss.metadata.ejb.parser.spec.EjbJarMetaDataParser.parse(EjbJarMetaDataParser.java:51)
> at org.jboss.as.ejb3.deployment.processors.EjbJarParsingDeploymentUnitProcessor.parseEjbJarXml(EjbJarParsingDeploymentUnitProcessor.java:272)
> ... 10 more
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
7 years, 3 months
[JBoss JIRA] (DROOLS-3591) [DMN Designer] Data Types - Type dropdown is not navigable by keyboard
by Michael Anstis (Jira)
[ https://issues.jboss.org/browse/DROOLS-3591?page=com.atlassian.jira.plugi... ]
Michael Anstis updated DROOLS-3591:
-----------------------------------
Sprint: 2019 Week 17-19
> [DMN Designer] Data Types - Type dropdown is not navigable by keyboard
> ----------------------------------------------------------------------
>
> Key: DROOLS-3591
> URL: https://issues.jboss.org/browse/DROOLS-3591
> Project: Drools
> Issue Type: Bug
> Components: DMN Editor
> Affects Versions: 7.18.0.Final
> Reporter: Guilherme Gomes
> Assignee: Michael Anstis
> Priority: Major
> Labels: drools-tools
> Attachments: 2019-01-31 15.02.26.gif
>
>
> The following navigation between types must work in all supported browsers:
> !2019-01-31 15.02.26.gif|thumbnail!
> [~tirelli] reported that in some scenarios this navigation doesn't work.
> ---
> *Steps to reproduce:*
> - Add new DT
> - Insert the name
> - Dropdown component navigation doesn't work *(expected: dropdown navigation should work)*
> - Dropdown component element unselects the DT *(expected: the DT row should stay selected)*
> - Dropdown component focus on input element when the new type selected *(expected: dropdown should stay focused)*
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
7 years, 3 months
[JBoss JIRA] (DROOLS-3591) [DMN Designer] Data Types - Type dropdown is not navigable by keyboard
by Michael Anstis (Jira)
[ https://issues.jboss.org/browse/DROOLS-3591?page=com.atlassian.jira.plugi... ]
Michael Anstis reassigned DROOLS-3591:
--------------------------------------
Assignee: Michael Anstis (was: Daniel José dos Santos)
> [DMN Designer] Data Types - Type dropdown is not navigable by keyboard
> ----------------------------------------------------------------------
>
> Key: DROOLS-3591
> URL: https://issues.jboss.org/browse/DROOLS-3591
> Project: Drools
> Issue Type: Bug
> Components: DMN Editor
> Affects Versions: 7.18.0.Final
> Reporter: Guilherme Gomes
> Assignee: Michael Anstis
> Priority: Major
> Labels: drools-tools
> Attachments: 2019-01-31 15.02.26.gif
>
>
> The following navigation between types must work in all supported browsers:
> !2019-01-31 15.02.26.gif|thumbnail!
> [~tirelli] reported that in some scenarios this navigation doesn't work.
> ---
> *Steps to reproduce:*
> - Add new DT
> - Insert the name
> - Dropdown component navigation doesn't work *(expected: dropdown navigation should work)*
> - Dropdown component element unselects the DT *(expected: the DT row should stay selected)*
> - Dropdown component focus on input element when the new type selected *(expected: dropdown should stay focused)*
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
7 years, 3 months
[JBoss JIRA] (DROOLS-3921) QCon Presentation
by Edoardo Vacchi (Jira)
[ https://issues.jboss.org/browse/DROOLS-3921?page=com.atlassian.jira.plugi... ]
Edoardo Vacchi updated DROOLS-3921:
-----------------------------------
Description:
Complete slides and possibly source code example (both *deliverables*) for the presentation:
bq. *Your Program as a Transpiler: Applying Compiler Design to Everyday Programming*
bq.
bq. Many languages “transpile” into other languages, but compilers are still often seen as arcane pieces of software that only a master of the dark arts could write. But at the end of the day, both are programs that translate code from a programming language to another.
bq.
bq. So what does make a transpiler simple and a compiler hard? What can we learn from these complex pieces of software? And are they really that complex?
bq.
bq. The lessons we can learn from language implementation design patterns are really within the reach of everyone; not only can they apply to daily programming problems, but they are also key to really understand the basis of exciting new technologies such as the GraalVM project and the Quarkus stack. In our experience on the Drools and jBPM projects, we have come across many opportunities to apply programming language development techniques to a broader context. In this talk, we will see some of these examples.
was:
Complete slides and possibly source code example (both *deliverables*) for the presentation:
??*Your Program as a Transpiler: Applying Compiler Design to Everyday Programming*
Many languages “transpile” into other languages, but compilers are still often seen as arcane pieces of software that only a master of the dark arts could write. But at the end of the day, both are programs that translate code from a programming language to another.
So what does make a transpiler simple and a compiler hard? What can we learn from these complex pieces of software? And are they really that complex?
The lessons we can learn from language implementation design patterns are really within the reach of everyone; not only can they apply to daily programming problems, but they are also key to really understand the basis of exciting new technologies such as the GraalVM project and the Quarkus stack. In our experience on the Drools and jBPM projects, we have come across many opportunities to apply programming language development techniques to a broader context. In this talk, we will see some of these examples.
??
> QCon Presentation
> -----------------
>
> Key: DROOLS-3921
> URL: https://issues.jboss.org/browse/DROOLS-3921
> Project: Drools
> Issue Type: Task
> Reporter: Edoardo Vacchi
> Assignee: Edoardo Vacchi
> Priority: Major
>
> Complete slides and possibly source code example (both *deliverables*) for the presentation:
> bq. *Your Program as a Transpiler: Applying Compiler Design to Everyday Programming*
> bq.
> bq. Many languages “transpile” into other languages, but compilers are still often seen as arcane pieces of software that only a master of the dark arts could write. But at the end of the day, both are programs that translate code from a programming language to another.
> bq.
> bq. So what does make a transpiler simple and a compiler hard? What can we learn from these complex pieces of software? And are they really that complex?
> bq.
> bq. The lessons we can learn from language implementation design patterns are really within the reach of everyone; not only can they apply to daily programming problems, but they are also key to really understand the basis of exciting new technologies such as the GraalVM project and the Quarkus stack. In our experience on the Drools and jBPM projects, we have come across many opportunities to apply programming language development techniques to a broader context. In this talk, we will see some of these examples.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
7 years, 3 months
[JBoss JIRA] (DROOLS-3921) QCon Presentation
by Edoardo Vacchi (Jira)
[ https://issues.jboss.org/browse/DROOLS-3921?page=com.atlassian.jira.plugi... ]
Edoardo Vacchi updated DROOLS-3921:
-----------------------------------
Description:
Complete slides and possibly source code example (both *deliverables*) for the presentation:
bq. *Your Program as a Transpiler: Applying Compiler Design to Everyday Programming*
bq. Many languages “transpile” into other languages, but compilers are still often seen as arcane pieces of software that only a master of the dark arts could write. But at the end of the day, both are programs that translate code from a programming language to another.
bq. So what does make a transpiler simple and a compiler hard? What can we learn from these complex pieces of software? And are they really that complex?
bq. The lessons we can learn from language implementation design patterns are really within the reach of everyone; not only can they apply to daily programming problems, but they are also key to really understand the basis of exciting new technologies such as the GraalVM project and the Quarkus stack. In our experience on the Drools and jBPM projects, we have come across many opportunities to apply programming language development techniques to a broader context. In this talk, we will see some of these examples.
was:
Complete slides and possibly source code example (both *deliverables*) for the presentation:
bq. *Your Program as a Transpiler: Applying Compiler Design to Everyday Programming*
bq.
bq. Many languages “transpile” into other languages, but compilers are still often seen as arcane pieces of software that only a master of the dark arts could write. But at the end of the day, both are programs that translate code from a programming language to another.
bq.
bq. So what does make a transpiler simple and a compiler hard? What can we learn from these complex pieces of software? And are they really that complex?
bq.
bq. The lessons we can learn from language implementation design patterns are really within the reach of everyone; not only can they apply to daily programming problems, but they are also key to really understand the basis of exciting new technologies such as the GraalVM project and the Quarkus stack. In our experience on the Drools and jBPM projects, we have come across many opportunities to apply programming language development techniques to a broader context. In this talk, we will see some of these examples.
> QCon Presentation
> -----------------
>
> Key: DROOLS-3921
> URL: https://issues.jboss.org/browse/DROOLS-3921
> Project: Drools
> Issue Type: Task
> Reporter: Edoardo Vacchi
> Assignee: Edoardo Vacchi
> Priority: Major
>
> Complete slides and possibly source code example (both *deliverables*) for the presentation:
> bq. *Your Program as a Transpiler: Applying Compiler Design to Everyday Programming*
> bq. Many languages “transpile” into other languages, but compilers are still often seen as arcane pieces of software that only a master of the dark arts could write. But at the end of the day, both are programs that translate code from a programming language to another.
> bq. So what does make a transpiler simple and a compiler hard? What can we learn from these complex pieces of software? And are they really that complex?
> bq. The lessons we can learn from language implementation design patterns are really within the reach of everyone; not only can they apply to daily programming problems, but they are also key to really understand the basis of exciting new technologies such as the GraalVM project and the Quarkus stack. In our experience on the Drools and jBPM projects, we have come across many opportunities to apply programming language development techniques to a broader context. In this talk, we will see some of these examples.
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
7 years, 3 months
[JBoss JIRA] (DROOLS-3921) QCon Presentation
by Edoardo Vacchi (Jira)
Edoardo Vacchi created DROOLS-3921:
--------------------------------------
Summary: QCon Presentation
Key: DROOLS-3921
URL: https://issues.jboss.org/browse/DROOLS-3921
Project: Drools
Issue Type: Task
Reporter: Edoardo Vacchi
Assignee: Edoardo Vacchi
Complete slides and possibly source code example (both *deliverables*) for the presentation:
??*Your Program as a Transpiler: Applying Compiler Design to Everyday Programming*
Many languages “transpile” into other languages, but compilers are still often seen as arcane pieces of software that only a master of the dark arts could write. But at the end of the day, both are programs that translate code from a programming language to another.
So what does make a transpiler simple and a compiler hard? What can we learn from these complex pieces of software? And are they really that complex?
The lessons we can learn from language implementation design patterns are really within the reach of everyone; not only can they apply to daily programming problems, but they are also key to really understand the basis of exciting new technologies such as the GraalVM project and the Quarkus stack. In our experience on the Drools and jBPM projects, we have come across many opportunities to apply programming language development techniques to a broader context. In this talk, we will see some of these examples.
??
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
7 years, 3 months