On Thursday 01 September 2011 08:00 PM, Jason T. Greene wrote:
On 9/1/11 9:03 AM, Jaikiran Pai wrote:
> On Thursday 01 September 2011 07:29 PM, Jason T. Greene wrote:
>> On 9/1/11 8:51 AM, Jaikiran Pai wrote:
>>> On Thursday 01 September 2011 07:14 PM, Jason T. Greene wrote:
>>> As for moving it to a separate library, it was indeed a separate
>>> library
>>> in the timerservice project that we merged recently into AS
>>> codebase. I
>>> think it probably makes sense to leave this library out of AS code
>>> base
>>> and let it be independent library.
>>
>> I meant generic time manipulation logic, not the entire ejb3 timer
>> service implementation, which encompasses much more than that.
>>
> Yeah, I meant the same too :) The time manipulation library was a
> separate maven project/library. I think it makes sense to let it stay
> independent and be outside of AS and let the rest of the timerservice
> logic stay in AS.
You mean this
https://github.com/jbossejb3/jboss-ejb3-timerservice/tree/master/ejb31-ca...
?
Yes, that's the one. The ejb31-calendar-expr-parser library is mainly
for parsing the cron style schedule expressions. At the time, during AS6
days, when I started working on timerservice, I couldn't find any
existing reusable projects which addressed this (without having to pull
in on a whole set of other unnecessary timer style functionalities), so
I just came up with this new independent one. It needs some
documentation, a bit of improvement,and a bit of cleanup but from a
functionality point of view it works.
That's reasonable. Although I was more thinking of common routines
that do date math with Calendar. I mean the hairy part of this is
caused by the fact that Calendar is a bad API and so difficult to use,
and easy to screw up. Such a module would have potential reusability
across other projects.
I agree about the Calendar API.
Another possibility is exploring the idea of using JODA.
Yes,
that's a good idea. We could make use of JODA within our parser
library instead of the Calendar API.
-Jaikiran