EJB 3.0
  1. EJB 3.0
  2. EJBTHREE-909

Injection of Simple Environment Entries Using Resource Annotation without name

    Details

    • Type: Bug Bug
    • Status: Resolved Resolved (View Workflow)
    • Priority: Major Major
    • Resolution: Done
    • Affects Version/s: EJB 3.0 RC9 - Patch 1
    • Fix Version/s: depchain-1.0.0-alpha-43
    • Component/s: None
    • Labels:
      None
    • Similar Issues:
      Show 10 results 

      Description

      The name of the @Resource annotations should default to the property or method name. The following simple environment injections are not working as expected:

      @Resource
      String stringValue;

      Long longValue = Long.valueOf(1);

      @Resource
      void setLongValue(Long longValue) {
      this.longValue = longValue;
      }

      Workaround:
      @Resource(name = "stringValue")
      String stringValue = "hi";

      Long longValue = Long.valueOf(1);

      @Resource(name = "longValue")
      public void setIntValue(Long longValue) {
      this.longValue = longValue;
      }

        Activity

        Hide
        Dmitri Voronov
        added a comment -

        Are there any plans regarding this bug? It actually violates JEE compliancy.

        Show
        Dmitri Voronov
        added a comment - Are there any plans regarding this bug? It actually violates JEE compliancy.

          People

          • Assignee:
            jaikiran pai
            Reporter:
            Roland Räz
          • Votes:
            2 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: