Bug 1129293
| Summary: | Use @Resource instead of @Inject for BMT example | ||
|---|---|---|---|
| Product: | [JBoss] JBoss Enterprise Application Platform 6 | Reporter: | Ondrej Chaloupka <ochaloup> |
| Component: | Documentation | Assignee: | sgilda |
| Status: | CLOSED NOTABUG | QA Contact: | Ondrej Chaloupka <ochaloup> |
| Severity: | urgent | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 6.3.0 | CC: | hhovsepy, mmusgrov, pmuir, sgilda, tom.jenkinson |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: |
Build Name: 22816, Development Guide-6.3-1
Build Date: 08-08-2014 15:41:08
Topic ID: 4305-591659 [Latest]
|
|
| Last Closed: | 2014-08-12 17:13:42 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Ondrej Chaloupka
2014-08-12 14:20:16 UTC
Ondrej, all the quickstarts use the @Inject and work fine with Java EE 6. Check out the code in the following quickstarts: bmt cdi-veto greeter jta-crash-rec Adding Mike and Tom to get more clarification. The Oracle documentation uses @Resource: http://docs.oracle.com/javaee/6/tutorial/doc/gmgli.html http://docs.oracle.com/javaee/7/tutorial/doc/cdi-adv004.htm It sounds like we do need to change the documentation and the quickstarts. Waiting to see what Mike and Tom say. You can inject UserTransaction in to a CDI bean in Java EE 6. This is defined in CDI 1.0 Section 3.6 (http://docs.jboss.org/cdi/spec/1.0/html_single/#d0e2363). If this does not work, it is a bug in EAP NOT the quickstart. Setting devel nack to - Thanks Pete. Because the quickstarts all work and were tested thoroughly by QA, I am not changing the code example in the documentation. Closing this as not a bug. Yeap, sorry Sande. I was terribly mistaken. I did a mistake in my deployment and as I saw that the most documentation about the injection of UserTransaction points to injection by resource so I thought that injection by Inject is rather feature of java ee 7. Once again, sorry for this bug. |