Skip to main content

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

  • From: "reza_rahman (JIRA)" <jira-no-reply@...>
  • To: issues@...
  • Subject: [ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment
  • Date: Sun, 20 Apr 2014 15:59:49 +0000 (UTC)
  • Auto-submitted: auto-generated


    [ 
https://java.net/jira/browse/EJB_SPEC-121?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=374607#action_374607
 ] 

reza_rahman edited comment on EJB_SPEC-121 at 4/20/14 3:59 PM:
---------------------------------------------------------------

For further context, it is useful to explore fairly common discussions such 
as these (often initiated by EJB/Java EE beginners and responded to by more 
knowledgeable folks/vendors): 
http://stackoverflow.com/questions/7930420/jee6-timer-persistence-across-redeploy.
 As both a user and an implementer it has always been clear to me personally 
why an implementation will likely choose to completely remove all application 
state related to the application upon undeploy/redeploy in order to reliably 
maintain consistency in a properly regimented production environment. In 
fact, this is what all implementations that I know of do today and GlassFish 
is the only implementation that I know of that allows persistent timers to be 
kept across redeployment by allowing it to be an explicit user option 
overriding default behavior.

That all being said, it may (or may not) be worth further clarifying this 
fairly minor (and relatively well understood) issue in the spec.

      was (Author: reza_rahman):
    For further context, it is useful to explore fairly common discussions 
such as these (often initiated by EJB/Java EE beginners and responded to by 
more knowledgeable folks/vendors): 
http://stackoverflow.com/questions/7930420/jee6-timer-persistence-across-redeploy.
 As both a user and an implementer it has always been clear to me personally 
why an implementation will likely choose to completely remove all application 
state related to the application upon undeploy/redeploy in order to reliably 
maintain consistency in a production environment. In fact, this is what all 
implementations that I know of do today and GlassFish is the only 
implementation that I know of that allows persistent timers to be kept across 
redeployment by allowing it to be an explicit user option overriding default 
behavior.

That all being said, it may (or may not) be worth further clarifying this 
fairly minor (and relatively well understood) issue in the spec.
  
> Clarification whether persistent timers have to survive redeployment / 
> undeployment
> -----------------------------------------------------------------------------------
>
>                 Key: EJB_SPEC-121
>                 URL: https://java.net/jira/browse/EJB_SPEC-121
>             Project: ejb-spec
>          Issue Type: Improvement
>    Affects Versions: 3.2
>            Reporter: mkarg
>
> Triggered by a dispute about an unclear section of th EJB 3.2 specification 
> I'd like to suggest that the next maintenance release of the EJB 
> specification provides the following clarification:
>  
> "A persistent timer MUST survive EJB redeployment."
>  
> Optionally I want to suggest that the specification goes further than that 
> an says:
>  
> "A persistent timer MUST survive EJB redeployment and undeployment."
>  
> Justification: Given a long-running business process like subscription 
> management, there are two ways to deal with future business events like 
> automatic subscription extension. The first way is to write the date of 
> next contract extension into a persistent database using JPA, and have a 
> non-persistent timer check this database table daily for any due contracts. 
> This solution survives even undeployment followed by redeployment, as the 
> database content is not touched. The second way is to not write the next 
> contract extension date into the database, but simply set up a persistent 
> timer firing on the day of extension. This offloads the burden of contract 
> book-keeping from the application's code and data tables to the EJB 
> container's persistent timer service. Certainly, an application programmer 
> would expect that when doing a redeployment (or even an undeployment and 
> deployment) will behave exactly the same -- and not kill any timers, as 
> those are not technical instruments but merely valueable business data. If 
> the container would kill that persistent timers at redeployment or 
> undeployment, this business data will get lost, which is clearly not what a 
> developer expects from any persistent technologoy!
>  
> Currently the RI (GlassFish 4.0) by default deletes programatically created 
> persistent timers when a new version of an application is provided by means 
> of redeployment (https://java.net/jira/browse/GLASSFISH-20295). This foils 
> the core idea of both, redeployment (in contrast to undeployment followed 
> by deployment) and persistent timers and threatens the realiability of 
> business applications by behaving in a non-expected way by default.
>  

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
https://java.net/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira




[ejb-spec issues] [JIRA] Created: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

mkarg (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Commented: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Commented: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

mkarg (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Commented: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014

[ejb-spec issues] [JIRA] Issue Comment Edited: (EJB_SPEC-121) Clarification whether persistent timers have to survive redeployment / undeployment

reza_rahman (JIRA) 04/20/2014
 
 
Close
loading
Please Confirm
Close