ejb-spec
  1. ejb-spec
  2. EJB_SPEC-57

Define asynchronous thread behavior upon close of embeddable container

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.2
    • Fix Version/s: 3.2
    • Labels:
      None

      Description

      Issue EJB_SPEC-13 adds asynchronous method invocation to EJB lite, which may be implemented by an embeddable container. The specification should define the behavior of the embeddable container regarding any outstanding asynchronous invocations upon closing the container (EJBContainer.close()) and since close() is not required, exit of main within the JVM.

      Transactionally, it seems to make the most sense for EJBContainer.close() and JVM exit to wait for any outstanding asynchronous threads before exiting. This provides consistent behavior, but at the risk of having an ill-behaved thread block the container or JVM from closing/exiting.

        Activity

        Hide
        marina vatkina added a comment -

        Hmmm.... I don't think EJB or Java EE spec says anything about what happens when the container(s) are being stopped....

        Show
        marina vatkina added a comment - Hmmm.... I don't think EJB or Java EE spec says anything about what happens when the container(s) are being stopped....
        Hide
        jrbauer added a comment -

        Section 18.2.4 (pd1) does contain some verbiage around shutdown requirements and expectations of the embeddable container. I shied away mentioning any sort of asynch shutdown expectations for containers in an EE environment since I too couldn't find anything around this topic in the specs. Introducing something now would likely cause compatibility issues for most vendors. But, since asynch support will be new in the embeddable container we have an opportunity to introduce some commonality/predictability without release compatibility concerns.

        Show
        jrbauer added a comment - Section 18.2.4 (pd1) does contain some verbiage around shutdown requirements and expectations of the embeddable container. I shied away mentioning any sort of asynch shutdown expectations for containers in an EE environment since I too couldn't find anything around this topic in the specs. Introducing something now would likely cause compatibility issues for most vendors. But, since asynch support will be new in the embeddable container we have an opportunity to introduce some commonality/predictability without release compatibility concerns.
        Show
        marina vatkina added a comment - See thread http://java.net/projects/ejb-spec/lists/jsr345-experts/archive/2012-07/message/6
        Hide
        marina vatkina added a comment -

        Reopening.

        Show
        marina vatkina added a comment - Reopening.
        Hide
        marina vatkina added a comment -

        Fixed in the upcoming version

        Show
        marina vatkina added a comment - Fixed in the upcoming version

          People

          • Assignee:
            marina vatkina
            Reporter:
            jrbauer
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: