[JBoss JIRA] (WFLY-10513) Getting JTA Datasource (Wildfly 13)
by Scott Marlow (JIRA)
[ https://issues.jboss.org/browse/WFLY-10513?page=com.atlassian.jira.plugin... ]
Scott Marlow commented on WFLY-10513:
-------------------------------------
[~david.tierens] I'm not sure of why your seeing this problem, sounds like a bug to me. We also included Hibernate ORM 5.3 in WildFly 13, if you start the app server via "./standalone.sh -Dee8.preview.mode=true" (or "standalone.bat -Dee8.preview.mode=true"), your application should be deployed with the newer ORM version.
Let us know if that helps.
I do see that the Hibernate ORM project source still includes "javax.persistence.jtaDataSource" ([https://github.com/hibernate/hibernate-orm/blob/master/hibernate-core/src...]).
> Getting JTA Datasource (Wildfly 13)
> -----------------------------------
>
> Key: WFLY-10513
> URL: https://issues.jboss.org/browse/WFLY-10513
> Project: WildFly
> Issue Type: Bug
> Components: JPA / Hibernate
> Affects Versions: 13.0.0.Final
> Reporter: David Tierens
> Assignee: Scott Marlow
> Priority: Minor
>
> In Wildfly 12 it ,was possible to get the DataSource via :
>
> {code:java}
> @ApplicationScoped
> public class ExamplePersistenceContextConfiguration {
>
> @PersistenceContext(unitName = "examplePersistenceUnit")
> @Produces
> private EntityManager entityManager;
>
> @Produces
> public DataSource getDataSource() {
> EntityManagerFactory entityManagerFactory = entityManager.getEntityManagerFactory();
> Map<String, Object> properties = entityManagerFactory.getProperties();
> return (DataSource) properties.get("javax.persistence.jtaDataSource");
> }
>
> @Produces
> public SessionFactory getSessionFactory() {
> Session session = entityManager.unwrap(Session.class);
> return session.getSessionFactory();
> }
> }
> {code}
>
> Currently it's returning null in Wildfly 13, however :
> {code:java}
> (DataSource) properties.get("hibernate.connection.datasource");
> {code}
> does work (instead of :
> {code:java}
> (DataSource) properties.get("javax.persistence.jtaDataSource")
> {code}
>
> Persistence.XML :
> {code:xml}
> // Some comments here
> public String getFoo()
> {
> return foo;
> }
> <?xml version="1.0" encoding="UTF-8"?>
> <persistence xmlns="http://xmlns.jcp.org/xml/ns/persistence"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/persistence
> http://xmlns.jcp.org/xml/ns/persistence/persistence_2_1.xsd"
> version="2.1">
> <!-- HBM files in this module will be loaded automatically -->
> <persistence-unit name="examplePersistenceUnit" transaction-type="JTA">
> <provider>org.hibernate.jpa.HibernatePersistenceProvider</provider>
> <jta-data-source>jdbc/ExampleXADataSource</jta-data-source>
> <properties>
> <property name="hibernate.dialect" value="org.hibernate.dialect.Oracle10gDialect"/>
> <property name="hibernate.show_sql" value="true"/>
> <property name="hibernate.order_inserts" value="true"/>
> <property name="hibernate.jdbc.wrap_result_sets" value="true"/>
> <property name="hibernate.integration.envers.enabled" value="false"/>
> </properties>
> </persistence-unit>
> </persistence>
> {code}
>
> Is there any way to get it via the properties.get("javax.persistence.jtaDataSource") and not via Hibernate ?
>
> Thanks in advance,
> David
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years
[JBoss JIRA] (WFLY-10288) Remove ee8.preview.mode support
by James Perkins (JIRA)
[ https://issues.jboss.org/browse/WFLY-10288?page=com.atlassian.jira.plugin... ]
James Perkins commented on WFLY-10288:
--------------------------------------
PR for 1.3 annotations https://github.com/wildfly/wildfly/pull/11414
> Remove ee8.preview.mode support
> -------------------------------
>
> Key: WFLY-10288
> URL: https://issues.jboss.org/browse/WFLY-10288
> Project: WildFly
> Issue Type: Sub-task
> Components: EE
> Reporter: James Perkins
> Assignee: James Perkins
> Fix For: 14.0.0.CR1
>
>
> Once Java EE 8 compliant we need to remove the support for the {{ee8.preview.mode}} system property.
> The following modules will need to be updated:
> * -{{javax.enterprise.api}}-
> * {{javax.validation.api}}
> * -{{javax.json.bind.api}}-
> * -{{javax.json.api}}-
> * {{javax.annotation.api}}
> * -{{javax.servlet.api}}-
> * -{{org.wildfly.bridge.servlet-api-bridge}} (needs to be removed)-
> * -{{org.eclipse.yasson}}-
> * -{{org.glassfish.javax.json}}-
> * {{javax.persistence.api}}
> * -{{javax.ws.rs.api}}-
> * {{javax.faces.api}}
> * {{javax.mail.api}}
> * {{javax.xml.bind.api}}
> * -{{org.wildfly.cdi-api-bridge}}-
> * -{{org.jboss.resteasy.resteasy-json-binding-provider}}-
> * -{{org.jboss.resteasy.resteasy-jaxrs}}-
> * {{org.hibernate.validator}}
> * {{org.hibernate.validator.cdi}}
> * {{org.hibernate}}
> * {{com.sun.jsf-impl}}
> The following configuration needs to be removed:
> * {{./feature-pack/src/main/resources/configuration/standalone/template-ee8.xml}}
> The Hibernate Search modules are currently duplicated:
> * {{org.hibernate.search.*}} using "main" slot should be removed
> * {{org.hibernate.search.*}} using "5.10" slot should be promoted to main
> * Update usage of constants {{org.jboss.as.jpa.config.Configuration#PROVIDER_MODULE_HIBERNATE_SEARCH_EE8}}, PROVIDER_MODULE_HIBERNATE_SEARCH_EE7
> The following source files should be updated:
> * -{{org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService.java}}-
> * -{{org.wildfly.extension.undertow.deployment.WarMetaDataProcessor.java}}-
> Any solution for WFLY-10289 should be reverted.
> The following documentation needs to be updated:
> * {{./docs/src/main/asciidoc/Getting_Started_Guide.adoc}}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years
[JBoss JIRA] (WFLY-10541) allow user to easily override the transaction node identifier
by Tom Jenkinson (JIRA)
[ https://issues.jboss.org/browse/WFLY-10541?page=com.atlassian.jira.plugin... ]
Tom Jenkinson commented on WFLY-10541:
--------------------------------------
{code}
still@DESKTOP-FM5AA5S /cygdrive/c/Users/still/Documents/jbosstm/narayana/jboss-as/build/target/wildfly-14.0.0.Beta1-SNAPSHOT (master)
$ ./bin/standalone.sh -Djboss.tx.node.id=`hostname` | grep WARN
16:53:45,504 WARN [org.jboss.as.domain.management.security] (MSC service thread 1-8) WFLYDM0111: Keystore C:\Users\still\Documents\jbosstm\narayana\jboss-as\build\target\wildfly-14.0.0.Beta1-SNAPSHOT\standalone\configuration\application.keystore not found, it will be auto generated on first use with a self signed certificate for host localhost
still@DESKTOP-FM5AA5S /cygdrive/c/Users/still/Documents/jbosstm/narayana/jboss-as/build/target/wildfly-14.0.0.Beta1-SNAPSHOT (master)
$ ./bin/standalone.sh -Djboss.tx.node.id=1 | grep WARN
16:54:00,992 WARN [org.jboss.as.txn] (ServerService Thread Pool -- 62) WFLYTX0013: The node-identifier attribute on the /subsystem=transactions is set to the default value. This is a danger for environments running multiple servers. Please make sure the attribute value is unique.
16:54:01,540 WARN [org.jboss.as.domain.management.security] (MSC service thread 1-1) WFLYDM0111: Keystore C:\Users\still\Documents\jbosstm\narayana\jboss-as\build\target\wildfly-14.0.0.Beta1-SNAPSHOT\standalone\configuration\application.keystore not found, it will be auto generated on first use with a self signed certificate for host localhost
still@DESKTOP-FM5AA5S /cygdrive/c/Users/still/Documents/jbosstm/narayana/jboss-as/build/target/wildfly-14.0.0.Beta1-SNAPSHOT (master)
$
{code}
> allow user to easily override the transaction node identifier
> -------------------------------------------------------------
>
> Key: WFLY-10541
> URL: https://issues.jboss.org/browse/WFLY-10541
> Project: WildFly
> Issue Type: Enhancement
> Components: Server
> Affects Versions: 13.0.0.Final
> Reporter: Brad Maxwell
> Assignee: Tom Jenkinson
>
> Add
> {code}
> node-identifier="${jboss.tx.node.id:1}
> {code}
> to the default WF Config files.
> Allows a user to then set -Djboss.tx.node.id to something like a pod name during startup in a script
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years
[JBoss JIRA] (WFLY-10494) HHH-12651 org.hibernate.Session.*Query(Ljava/lang/String) methods return different types in 5.1 and 5.3
by Scott Marlow (JIRA)
[ https://issues.jboss.org/browse/WFLY-10494?page=com.atlassian.jira.plugin... ]
Scott Marlow commented on WFLY-10494:
-------------------------------------
[~simkam] looks like https://hibernate.atlassian.net/browse/HHH-12651 is resolved, do you need this jira to remain open?
> HHH-12651 org.hibernate.Session.*Query(Ljava/lang/String) methods return different types in 5.1 and 5.3
> -------------------------------------------------------------------------------------------------------
>
> Key: WFLY-10494
> URL: https://issues.jboss.org/browse/WFLY-10494
> Project: WildFly
> Issue Type: Bug
> Components: JPA / Hibernate
> Affects Versions: 13.0.0.Final
> Reporter: Martin Simka
> Assignee: Scott Marlow
> Priority: Blocker
> Labels: blocker-WF14
>
> https://hibernate.atlassian.net/browse/HHH-12651
> although mentioned in HHH-12424, it doesn't seem to be resolved
> in 5.1
> org.hibernate.Session.createQuery(Ljava/lang/String;)Lorg/hibernate/Query
> in 5.3
> org.hibernate.Session.createQuery(Ljava/lang/String;)Lorg/hibernate.query.Query
> It happens when code compiled with Hibernate ORM 5.1 is run with Hibernate ORM 5.3
> I attached very simple reproducer class.
> {code}
> # compile with Hibernate 5.1
> javac App.java -cp ~/.m2/repository/org/hibernate/hibernate-core/5.1.9.Final/hibernate-core-5.1.9.Final.jar
> # run with 5.1 => ok
> java -cp .:/home/msimka/.m2/repository/org/hibernate/hibernate-core/5.1.9.Final/hibernate-core-5.1.9.Final.jar App
> # run with 5.3 => fail
> java -cp .:/home/msimka/.m2/repository/org/hibernate/hibernate-core/5.3.1.Final/hibernate-core-5.3.1.Final.jar:/home/msimka/.m2/repository/javax/persistence/javax.persistence-api/2.2/javax.persistence-api-2.2.jar App
> Exception in thread "main" java.lang.NoSuchMethodError: org.hibernate.Session.createQuery(Ljava/lang/String;)Lorg/hibernate/Query;
> at App.main(App.java:35)
> {code}
> other methods with the same issue:
> java.lang.NoSuchMethodError: org.hibernate.Session.getNamedQuery(Ljava/lang/String;)Lorg/hibernate/Query;
> java.lang.NoSuchMethodError: org.hibernate.Session.createSQLQuery(Ljava/lang/String;)Lorg/hibernate/SQLQuery;
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years
[JBoss JIRA] (WFLY-10288) Remove ee8.preview.mode support
by James Perkins (JIRA)
[ https://issues.jboss.org/browse/WFLY-10288?page=com.atlassian.jira.plugin... ]
James Perkins commented on WFLY-10288:
--------------------------------------
PR for Java Mail https://github.com/wildfly/wildfly/pull/11411
> Remove ee8.preview.mode support
> -------------------------------
>
> Key: WFLY-10288
> URL: https://issues.jboss.org/browse/WFLY-10288
> Project: WildFly
> Issue Type: Sub-task
> Components: EE
> Reporter: James Perkins
> Assignee: James Perkins
> Fix For: 14.0.0.CR1
>
>
> Once Java EE 8 compliant we need to remove the support for the {{ee8.preview.mode}} system property.
> The following modules will need to be updated:
> * -{{javax.enterprise.api}}-
> * {{javax.validation.api}}
> * -{{javax.json.bind.api}}-
> * -{{javax.json.api}}-
> * {{javax.annotation.api}}
> * -{{javax.servlet.api}}-
> * -{{org.wildfly.bridge.servlet-api-bridge}} (needs to be removed)-
> * -{{org.eclipse.yasson}}-
> * -{{org.glassfish.javax.json}}-
> * {{javax.persistence.api}}
> * -{{javax.ws.rs.api}}-
> * {{javax.faces.api}}
> * {{javax.mail.api}}
> * {{javax.xml.bind.api}}
> * -{{org.wildfly.cdi-api-bridge}}-
> * -{{org.jboss.resteasy.resteasy-json-binding-provider}}-
> * -{{org.jboss.resteasy.resteasy-jaxrs}}-
> * {{org.hibernate.validator}}
> * {{org.hibernate.validator.cdi}}
> * {{org.hibernate}}
> * {{com.sun.jsf-impl}}
> The following configuration needs to be removed:
> * {{./feature-pack/src/main/resources/configuration/standalone/template-ee8.xml}}
> The Hibernate Search modules are currently duplicated:
> * {{org.hibernate.search.*}} using "main" slot should be removed
> * {{org.hibernate.search.*}} using "5.10" slot should be promoted to main
> * Update usage of constants {{org.jboss.as.jpa.config.Configuration#PROVIDER_MODULE_HIBERNATE_SEARCH_EE8}}, PROVIDER_MODULE_HIBERNATE_SEARCH_EE7
> The following source files should be updated:
> * -{{org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService.java}}-
> * -{{org.wildfly.extension.undertow.deployment.WarMetaDataProcessor.java}}-
> Any solution for WFLY-10289 should be reverted.
> The following documentation needs to be updated:
> * {{./docs/src/main/asciidoc/Getting_Started_Guide.adoc}}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years
[JBoss JIRA] (DROOLS-2342) Update Kie Navigator to the new git/rest structure
by Andrej Podhradsky (JIRA)
[ https://issues.jboss.org/browse/DROOLS-2342?page=com.atlassian.jira.plugi... ]
Andrej Podhradsky commented on DROOLS-2342:
-------------------------------------------
I tried basic operations and it seems to be working. I will try other scenarios and let you know.
> Update Kie Navigator to the new git/rest structure
> --------------------------------------------------
>
> Key: DROOLS-2342
> URL: https://issues.jboss.org/browse/DROOLS-2342
> Project: Drools
> Issue Type: Bug
> Components: eclipse plugin
> Affects Versions: 7.5.0.Final
> Environment: 7.7.0-SNAPSHOT
> Reporter: Tomas David
> Assignee: Tiago Bento
> Labels: AppFormer, AppFormer-Prioritized
> Fix For: 7.8.0.Final
>
>
> Drools eclipse plugin contains Kie Navigator tool which uses git structure and rest calls to connect to kie-wb. According to changes made in kie-wb 7.7.0 the tooling should be updated.
> The rest api and the git structure changed. and the kie navigator doesn't work.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years