You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by Bjorn Danielsson <bj...@lists.cuspycode.com> on 2014/07/21 12:11:47 UTC

Spooky org.terracotta.quartz.skipUpdateCheck

Hi,

I noticed that all @Schedule methods stop working after hot
redeployment on one of my machines, and the culprit turned out
to be that I had forgotten to remove this from system.properties
after upgrading the machine to TomEE 1.6.0 a long time ago:

org.terracotta.quartz.skipUpdateCheck=true

This strange behaviour remains in today's 1.7.0-SNAPSHOT.

Removing the line makes everything work again.

I just thought I'd mention it here for the search engines.

-- 
Bjorn Danielsson
Cuspy Code AB

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Jean-Louis Monteiro <jl...@tomitribe.com>.
And that is really appreciated.
Can definitely help others

--
Jean-Louis Monteiro
http://twitter.com/jlouismonteiro
http://www.tomitribe.com


On Mon, Jul 21, 2014 at 12:11 PM, Bjorn Danielsson <
bjorn-apache@lists.cuspycode.com> wrote:

> Hi,
>
> I noticed that all @Schedule methods stop working after hot
> redeployment on one of my machines, and the culprit turned out
> to be that I had forgotten to remove this from system.properties
> after upgrading the machine to TomEE 1.6.0 a long time ago:
>
> org.terracotta.quartz.skipUpdateCheck=true
>
> This strange behaviour remains in today's 1.7.0-SNAPSHOT.
>
> Removing the line makes everything work again.
>
> I just thought I'd mention it here for the search engines.
>
> --
> Bjorn Danielsson
> Cuspy Code AB
>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Romain Manni-Bucau <rm...@gmail.com>.
last time we got it it was cause the schedule was not undeployed correctly
on redeployment and then the BeanContext instance was wrong for scheduled
tasks(no link with this property).

If you have a sample maven project we can test against it would ease it
since it was fixed months ago



Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau


2014-07-21 13:14 GMT+02:00 Andy Gumbrecht <ag...@tomitribe.com>:

> Bjorn,
>
> We actually check for and explicitly set this property with the default to
> skip.
>
> System.setProperty("org.terracotta.quartz.skipUpdateCheck"
>             , System.getProperty("org.terracotta.quartz.skipUpdateCheck",
> "true"));
>
> The 'only' thing I can imagine is that the value is not being read as
> 'true' - maybe a typo or codepage issue (check the file encoding of the
> system.properties file).
> The actual update check is in Quartz and it uses a host name that needs to
> be DNS resolved, and then actually polls their server (which can take ages
> sometimes).
>
> It uses this URL 'http://www.terracotta.org/kit/reflector?kitID=quartz&
> pageID=update.properties', so just out of interest can you try and browse
> that on the machine that hangs?
>
> Thanks,
>
> Andy.
>
> PS. I hope you're not using TomEE to 'spam spam spam' people :-P
>
>
> On 21/07/2014 12:53, Bjorn Danielsson wrote:
>
>> Thanks Andy. Here is the code I used:
>>
>> package foo;
>>
>> import javax.ejb.*;
>> import java.util.logging.Logger;
>>
>> @Singleton
>> @Lock(LockType.READ)
>> @Startup
>> public class BugBean {
>>      static final Logger logger = Logger.getLogger(BugBean.
>> class.getName());
>>
>>      @Lock(LockType.WRITE)
>>      @Schedule(second="*/5", minute="*", hour="*")
>>      public void spam() {
>>         logger.info("Spam spam spam");
>>      }
>>
>> }
>>
>>
> --
>   Andy Gumbrecht
>
>   http://www.tomitribe.com
>   agumbrecht@tomitribe.com
>   https://twitter.com/AndyGeeDe
>
>   TomEE treibt Tomitribe! | http://tomee.apache.org
>
>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Andy Gumbrecht <ag...@tomitribe.com>.
I've merged the fix to the 1.7.x branch. Also many thanks Romain.

Andy.

On 23/07/2014 09:31, Bjorn Danielsson wrote:
> OK, I just compiled r1612637 and now it works. Thanks Romain!
>

-- 
   Andy Gumbrecht

   http://www.tomitribe.com
   agumbrecht@tomitribe.com
   https://twitter.com/AndyGeeDe

   TomEE treibt Tomitribe! | http://tomee.apache.org


Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Bjorn Danielsson <bj...@lists.cuspycode.com>.
OK, I just compiled r1612637 and now it works. Thanks Romain!

-- 
Bjorn Danielsson
Cuspy Code AB


Romain Manni-Bucau <rm...@gmail.com> wrote:
> Hi
>
> finally found https://issues.apache.org/jira/browse/TOMEE-1275
>
>
>
> Romain Manni-Bucau
> Twitter: @rmannibucau
> Blog: http://rmannibucau.wordpress.com/
> LinkedIn: http://fr.linkedin.com/in/rmannibucau
> Github: https://github.com/rmannibucau
>
>
> 2014-07-22 15:29 GMT+02:00 Romain Manni-Bucau <rm...@gmail.com>:
>
>> Ok
>>
>> got the issue, thanks for your patience.
>>
>> It is mainly stop/restart kills quartz executor service, I'll fix it
>> tonight
>>
>>
>>
>> Romain Manni-Bucau
>> Twitter: @rmannibucau
>> Blog: http://rmannibucau.wordpress.com/
>> LinkedIn: http://fr.linkedin.com/in/rmannibucau
>> Github: https://github.com/rmannibucau
>>
>>
>> 2014-07-22 14:29 GMT+02:00 Bjorn Danielsson <
>> bjorn-apache@lists.cuspycode.com>:
>>
>> When I press Stop followed by Start, scheduling stops working.
>>>
>>> Had a quick look with jconsole and noticed that after running
>>> the webapp for about 20 seconds I can see these threads:
>>>
>>> OpenEJB-TimerService-Scheduler_QuartzSchedulerThread
>>> EjbTimerPool - 1
>>> EjbTimerPool - 2
>>> EjbTimerPool - 3
>>>
>>> Stop removes all four threads. Start recreates the first one
>>> but no EjbTimerPool threads appear.
>>>
>>> --
>>> Bjorn Danielsson
>>> Cuspy Code AB
>>>
>>>
>>> Romain Manni-Bucau <rm...@gmail.com> wrote:
>>> > Hi
>>> >
>>> > I tried but when I hit F5 I get "app already deployed". If I stop it or
>>> > remove it and restart/redeploy it works.
>>> >
>>> >
>>> >
>>> > Romain Manni-Bucau
>>> > Twitter: @rmannibucau
>>> > Blog: http://rmannibucau.wordpress.com/
>>> > LinkedIn: http://fr.linkedin.com/in/rmannibucau
>>> > Github: https://github.com/rmannibucau
>>> >
>>> >
>>> > 2014-07-22 11:50 GMT+02:00 Bjorn Danielsson <
>>> > bjorn-apache@lists.cuspycode.com>:
>>> >
>>> >> Romain Manni-Bucau <rm...@gmail.com> wrote:
>>> >> > How do you deploy it? deploying it at startup then hitting several
>>> times
>>> >> > reload works fine
>>> >>
>>> >> I have now reproduced the weird behaviour using the Tomcat manager:
>>> >>
>>> >> 1. Add this to system.properties:
>>> >>
>>> >>    org.terracotta.quartz.skipUpdateCheck=true
>>> >>
>>> >> 2. Enable the manager webapp.
>>> >>
>>> >> 3. Deploy the WAR via the manager.
>>> >>
>>> >> 4. tail -f catalina.out. A message will be logged every 5 seconds
>>> >>    showing that the @Schedule method is being invoked by Quartz.
>>> >>
>>> >> 5. Hit reload in the manager.
>>> >>
>>> >> 6. Notice silence in catalina.out after deployment is complete.
>>> >>
>>> >> Versions used:
>>> >>
>>> >> apache-tomee-1.7.0-20140722.041427-62-jaxrs
>>> >> apache-tomee-1.7.0-20140722.041427-62-plus   (tested separately)
>>> >> jdk-7u60-linux-x64
>>> >> Ubuntu 12.04
>>> >>
>>> >> --
>>> >> Bjorn Danielsson
>>> >> Cuspy Code AB
>>> >>
>>>
>>
>>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi

finally found https://issues.apache.org/jira/browse/TOMEE-1275



Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau


2014-07-22 15:29 GMT+02:00 Romain Manni-Bucau <rm...@gmail.com>:

> Ok
>
> got the issue, thanks for your patience.
>
> It is mainly stop/restart kills quartz executor service, I'll fix it
> tonight
>
>
>
> Romain Manni-Bucau
> Twitter: @rmannibucau
> Blog: http://rmannibucau.wordpress.com/
> LinkedIn: http://fr.linkedin.com/in/rmannibucau
> Github: https://github.com/rmannibucau
>
>
> 2014-07-22 14:29 GMT+02:00 Bjorn Danielsson <
> bjorn-apache@lists.cuspycode.com>:
>
> When I press Stop followed by Start, scheduling stops working.
>>
>> Had a quick look with jconsole and noticed that after running
>> the webapp for about 20 seconds I can see these threads:
>>
>> OpenEJB-TimerService-Scheduler_QuartzSchedulerThread
>> EjbTimerPool - 1
>> EjbTimerPool - 2
>> EjbTimerPool - 3
>>
>> Stop removes all four threads. Start recreates the first one
>> but no EjbTimerPool threads appear.
>>
>> --
>> Bjorn Danielsson
>> Cuspy Code AB
>>
>>
>> Romain Manni-Bucau <rm...@gmail.com> wrote:
>> > Hi
>> >
>> > I tried but when I hit F5 I get "app already deployed". If I stop it or
>> > remove it and restart/redeploy it works.
>> >
>> >
>> >
>> > Romain Manni-Bucau
>> > Twitter: @rmannibucau
>> > Blog: http://rmannibucau.wordpress.com/
>> > LinkedIn: http://fr.linkedin.com/in/rmannibucau
>> > Github: https://github.com/rmannibucau
>> >
>> >
>> > 2014-07-22 11:50 GMT+02:00 Bjorn Danielsson <
>> > bjorn-apache@lists.cuspycode.com>:
>> >
>> >> Romain Manni-Bucau <rm...@gmail.com> wrote:
>> >> > How do you deploy it? deploying it at startup then hitting several
>> times
>> >> > reload works fine
>> >>
>> >> I have now reproduced the weird behaviour using the Tomcat manager:
>> >>
>> >> 1. Add this to system.properties:
>> >>
>> >>    org.terracotta.quartz.skipUpdateCheck=true
>> >>
>> >> 2. Enable the manager webapp.
>> >>
>> >> 3. Deploy the WAR via the manager.
>> >>
>> >> 4. tail -f catalina.out. A message will be logged every 5 seconds
>> >>    showing that the @Schedule method is being invoked by Quartz.
>> >>
>> >> 5. Hit reload in the manager.
>> >>
>> >> 6. Notice silence in catalina.out after deployment is complete.
>> >>
>> >> Versions used:
>> >>
>> >> apache-tomee-1.7.0-20140722.041427-62-jaxrs
>> >> apache-tomee-1.7.0-20140722.041427-62-plus   (tested separately)
>> >> jdk-7u60-linux-x64
>> >> Ubuntu 12.04
>> >>
>> >> --
>> >> Bjorn Danielsson
>> >> Cuspy Code AB
>> >>
>>
>
>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Ok

got the issue, thanks for your patience.

It is mainly stop/restart kills quartz executor service, I'll fix it
tonight



Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau


2014-07-22 14:29 GMT+02:00 Bjorn Danielsson <
bjorn-apache@lists.cuspycode.com>:

> When I press Stop followed by Start, scheduling stops working.
>
> Had a quick look with jconsole and noticed that after running
> the webapp for about 20 seconds I can see these threads:
>
> OpenEJB-TimerService-Scheduler_QuartzSchedulerThread
> EjbTimerPool - 1
> EjbTimerPool - 2
> EjbTimerPool - 3
>
> Stop removes all four threads. Start recreates the first one
> but no EjbTimerPool threads appear.
>
> --
> Bjorn Danielsson
> Cuspy Code AB
>
>
> Romain Manni-Bucau <rm...@gmail.com> wrote:
> > Hi
> >
> > I tried but when I hit F5 I get "app already deployed". If I stop it or
> > remove it and restart/redeploy it works.
> >
> >
> >
> > Romain Manni-Bucau
> > Twitter: @rmannibucau
> > Blog: http://rmannibucau.wordpress.com/
> > LinkedIn: http://fr.linkedin.com/in/rmannibucau
> > Github: https://github.com/rmannibucau
> >
> >
> > 2014-07-22 11:50 GMT+02:00 Bjorn Danielsson <
> > bjorn-apache@lists.cuspycode.com>:
> >
> >> Romain Manni-Bucau <rm...@gmail.com> wrote:
> >> > How do you deploy it? deploying it at startup then hitting several
> times
> >> > reload works fine
> >>
> >> I have now reproduced the weird behaviour using the Tomcat manager:
> >>
> >> 1. Add this to system.properties:
> >>
> >>    org.terracotta.quartz.skipUpdateCheck=true
> >>
> >> 2. Enable the manager webapp.
> >>
> >> 3. Deploy the WAR via the manager.
> >>
> >> 4. tail -f catalina.out. A message will be logged every 5 seconds
> >>    showing that the @Schedule method is being invoked by Quartz.
> >>
> >> 5. Hit reload in the manager.
> >>
> >> 6. Notice silence in catalina.out after deployment is complete.
> >>
> >> Versions used:
> >>
> >> apache-tomee-1.7.0-20140722.041427-62-jaxrs
> >> apache-tomee-1.7.0-20140722.041427-62-plus   (tested separately)
> >> jdk-7u60-linux-x64
> >> Ubuntu 12.04
> >>
> >> --
> >> Bjorn Danielsson
> >> Cuspy Code AB
> >>
>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Bjorn Danielsson <bj...@lists.cuspycode.com>.
When I press Stop followed by Start, scheduling stops working.

Had a quick look with jconsole and noticed that after running
the webapp for about 20 seconds I can see these threads:

OpenEJB-TimerService-Scheduler_QuartzSchedulerThread
EjbTimerPool - 1
EjbTimerPool - 2
EjbTimerPool - 3

Stop removes all four threads. Start recreates the first one
but no EjbTimerPool threads appear.

-- 
Bjorn Danielsson
Cuspy Code AB


Romain Manni-Bucau <rm...@gmail.com> wrote:
> Hi
>
> I tried but when I hit F5 I get "app already deployed". If I stop it or
> remove it and restart/redeploy it works.
>
>
>
> Romain Manni-Bucau
> Twitter: @rmannibucau
> Blog: http://rmannibucau.wordpress.com/
> LinkedIn: http://fr.linkedin.com/in/rmannibucau
> Github: https://github.com/rmannibucau
>
>
> 2014-07-22 11:50 GMT+02:00 Bjorn Danielsson <
> bjorn-apache@lists.cuspycode.com>:
>
>> Romain Manni-Bucau <rm...@gmail.com> wrote:
>> > How do you deploy it? deploying it at startup then hitting several times
>> > reload works fine
>>
>> I have now reproduced the weird behaviour using the Tomcat manager:
>>
>> 1. Add this to system.properties:
>>
>>    org.terracotta.quartz.skipUpdateCheck=true
>>
>> 2. Enable the manager webapp.
>>
>> 3. Deploy the WAR via the manager.
>>
>> 4. tail -f catalina.out. A message will be logged every 5 seconds
>>    showing that the @Schedule method is being invoked by Quartz.
>>
>> 5. Hit reload in the manager.
>>
>> 6. Notice silence in catalina.out after deployment is complete.
>>
>> Versions used:
>>
>> apache-tomee-1.7.0-20140722.041427-62-jaxrs
>> apache-tomee-1.7.0-20140722.041427-62-plus   (tested separately)
>> jdk-7u60-linux-x64
>> Ubuntu 12.04
>>
>> --
>> Bjorn Danielsson
>> Cuspy Code AB
>>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi

I tried but when I hit F5 I get "app already deployed". If I stop it or
remove it and restart/redeploy it works.



Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau


2014-07-22 11:50 GMT+02:00 Bjorn Danielsson <
bjorn-apache@lists.cuspycode.com>:

> Romain Manni-Bucau <rm...@gmail.com> wrote:
> > How do you deploy it? deploying it at startup then hitting several times
> > reload works fine
>
> I have now reproduced the weird behaviour using the Tomcat manager:
>
> 1. Add this to system.properties:
>
>    org.terracotta.quartz.skipUpdateCheck=true
>
> 2. Enable the manager webapp.
>
> 3. Deploy the WAR via the manager.
>
> 4. tail -f catalina.out. A message will be logged every 5 seconds
>    showing that the @Schedule method is being invoked by Quartz.
>
> 5. Hit reload in the manager.
>
> 6. Notice silence in catalina.out after deployment is complete.
>
> Versions used:
>
> apache-tomee-1.7.0-20140722.041427-62-jaxrs
> apache-tomee-1.7.0-20140722.041427-62-plus   (tested separately)
> jdk-7u60-linux-x64
> Ubuntu 12.04
>
> --
> Bjorn Danielsson
> Cuspy Code AB
>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Bjorn Danielsson <bj...@lists.cuspycode.com>.
Romain Manni-Bucau <rm...@gmail.com> wrote:
> How do you deploy it? deploying it at startup then hitting several times
> reload works fine

I have now reproduced the weird behaviour using the Tomcat manager:

1. Add this to system.properties:

   org.terracotta.quartz.skipUpdateCheck=true

2. Enable the manager webapp.

3. Deploy the WAR via the manager.

4. tail -f catalina.out. A message will be logged every 5 seconds
   showing that the @Schedule method is being invoked by Quartz.

5. Hit reload in the manager.

6. Notice silence in catalina.out after deployment is complete.

Versions used:

apache-tomee-1.7.0-20140722.041427-62-jaxrs
apache-tomee-1.7.0-20140722.041427-62-plus   (tested separately)
jdk-7u60-linux-x64
Ubuntu 12.04

-- 
Bjorn Danielsson
Cuspy Code AB

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Bjorn Danielsson <bj...@lists.cuspycode.com>.
TomEE undeploys the first copy before redeploying the new one,
according to catalina.out. Is redeployment by dropping a new
version of the war file into tomee/webapps not supported?

And it makes no difference if I first undeploy the first copy by
deleting the war file, then wait a few minutes and watch how tomee
undeploys it, then I deploy it again by copying the same war file
to webapps. The same spooky behaviour is manifested:

With "org.terracotta.quartz.skipUpdateCheck=true" Quartz stops
working, without it everything works as expected.

-- 
Bjorn Danielsson
Cuspy Code AB


Romain Manni-Bucau <rm...@gmail.com> wrote:
> without undeploying the other copy? then there is an EJB conflict so
> doesn't shock me it doesn't work
>
>
>
> Romain Manni-Bucau
> Twitter: @rmannibucau
> Blog: http://rmannibucau.wordpress.com/
> LinkedIn: http://fr.linkedin.com/in/rmannibucau
> Github: https://github.com/rmannibucau
>
>
> 2014-07-21 19:22 GMT+02:00 Bjorn Danielsson <
> bjorn-apache@lists.cuspycode.com>:
>
>> I redeploy by copying it a second time to tomee/webapps as
>> explained here:
>>
>>
>> https://github.com/cuspycode/apache-stuff/blob/master/schedule-bug/readme.txt
>>
>> Just touching the .war also reproduces it for me.
>>
>> --
>> Bjorn Danielsson
>> Cuspy Code AB
>>
>>
>> Romain Manni-Bucau <rm...@gmail.com> wrote:
>> > How do you deploy it? deploying it at startup then hitting several times
>> > reload works fine
>> >
>> >
>> >
>> > Romain Manni-Bucau
>> > Twitter: @rmannibucau
>> > Blog: http://rmannibucau.wordpress.com/
>> > LinkedIn: http://fr.linkedin.com/in/rmannibucau
>> > Github: https://github.com/rmannibucau
>> >
>> >
>> > 2014-07-21 18:52 GMT+02:00 Bjorn Danielsson <
>> > bjorn-apache@lists.cuspycode.com>:
>> >
>> >> Andy,
>> >>
>> >> No I was just trying to be clever and give a subversion link to
>> >> a Github subdirectory. It works with svn but apparently not in
>> >> a browser. Try the root link instead and ignore the other stuff:
>> >>
>> >> https://github.com/cuspycode/apache-stuff
>> >>
>> >> --
>> >> Bjorn Danielsson
>> >> Cuspy Code AB
>> >>
>> >>
>> >> Andy Gumbrecht <ag...@tomitribe.com> wrote:
>> >> > Bjorn,
>> >> >
>> >> > I get a 404 on the link, did you kill it already?
>> >> >
>> >> > Andy.
>> >> >
>> >> > On 21/07/2014 16:39, Bjorn Danielsson wrote:
>> >> >> I checked the URL connectivity with curl, and I checked the 302-
>> >> >> redirect host, and both are responsive on the machine in question.
>> >> >> Then I temporarily added bogus routes to both hosts, and nothing
>> >> >> changed. There are no delays due to failed connection attempts.
>> >> >> In fact the webapp starts as usual, and beans and servlets are
>> >> >> responsive, it's just that the timers stop working.
>> >> >>
>> >> >> I noticed one more thing now when taking a second look at the logs.
>> >> >> When I redeploy with skipUpdateCheck=true I get log messages about
>> >> >> QuartzScheduler shutting down during undeployment and about one
>> >> >> second later it is initialized during deployment. With an empty
>> >> >> system.properties I get no such messages during redeployment,
>> >> >> only at start and stop of tomee itself.
>> >> >>
>> >> >> Here is a small ant project that reproduces the behaviour:
>> >> >>
>> >> >> svn co https://github.com/cuspycode/apache-stuff/trunk/schedule-bug
>> >> >>
>> >>
>>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Romain Manni-Bucau <rm...@gmail.com>.
without undeploying the other copy? then there is an EJB conflict so
doesn't shock me it doesn't work



Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau


2014-07-21 19:22 GMT+02:00 Bjorn Danielsson <
bjorn-apache@lists.cuspycode.com>:

> I redeploy by copying it a second time to tomee/webapps as
> explained here:
>
>
> https://github.com/cuspycode/apache-stuff/blob/master/schedule-bug/readme.txt
>
> Just touching the .war also reproduces it for me.
>
> --
> Bjorn Danielsson
> Cuspy Code AB
>
>
> Romain Manni-Bucau <rm...@gmail.com> wrote:
> > How do you deploy it? deploying it at startup then hitting several times
> > reload works fine
> >
> >
> >
> > Romain Manni-Bucau
> > Twitter: @rmannibucau
> > Blog: http://rmannibucau.wordpress.com/
> > LinkedIn: http://fr.linkedin.com/in/rmannibucau
> > Github: https://github.com/rmannibucau
> >
> >
> > 2014-07-21 18:52 GMT+02:00 Bjorn Danielsson <
> > bjorn-apache@lists.cuspycode.com>:
> >
> >> Andy,
> >>
> >> No I was just trying to be clever and give a subversion link to
> >> a Github subdirectory. It works with svn but apparently not in
> >> a browser. Try the root link instead and ignore the other stuff:
> >>
> >> https://github.com/cuspycode/apache-stuff
> >>
> >> --
> >> Bjorn Danielsson
> >> Cuspy Code AB
> >>
> >>
> >> Andy Gumbrecht <ag...@tomitribe.com> wrote:
> >> > Bjorn,
> >> >
> >> > I get a 404 on the link, did you kill it already?
> >> >
> >> > Andy.
> >> >
> >> > On 21/07/2014 16:39, Bjorn Danielsson wrote:
> >> >> I checked the URL connectivity with curl, and I checked the 302-
> >> >> redirect host, and both are responsive on the machine in question.
> >> >> Then I temporarily added bogus routes to both hosts, and nothing
> >> >> changed. There are no delays due to failed connection attempts.
> >> >> In fact the webapp starts as usual, and beans and servlets are
> >> >> responsive, it's just that the timers stop working.
> >> >>
> >> >> I noticed one more thing now when taking a second look at the logs.
> >> >> When I redeploy with skipUpdateCheck=true I get log messages about
> >> >> QuartzScheduler shutting down during undeployment and about one
> >> >> second later it is initialized during deployment. With an empty
> >> >> system.properties I get no such messages during redeployment,
> >> >> only at start and stop of tomee itself.
> >> >>
> >> >> Here is a small ant project that reproduces the behaviour:
> >> >>
> >> >> svn co https://github.com/cuspycode/apache-stuff/trunk/schedule-bug
> >> >>
> >>
>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Bjorn Danielsson <bj...@lists.cuspycode.com>.
I redeploy by copying it a second time to tomee/webapps as
explained here:

https://github.com/cuspycode/apache-stuff/blob/master/schedule-bug/readme.txt

Just touching the .war also reproduces it for me.

-- 
Bjorn Danielsson
Cuspy Code AB


Romain Manni-Bucau <rm...@gmail.com> wrote:
> How do you deploy it? deploying it at startup then hitting several times
> reload works fine
>
>
>
> Romain Manni-Bucau
> Twitter: @rmannibucau
> Blog: http://rmannibucau.wordpress.com/
> LinkedIn: http://fr.linkedin.com/in/rmannibucau
> Github: https://github.com/rmannibucau
>
>
> 2014-07-21 18:52 GMT+02:00 Bjorn Danielsson <
> bjorn-apache@lists.cuspycode.com>:
>
>> Andy,
>>
>> No I was just trying to be clever and give a subversion link to
>> a Github subdirectory. It works with svn but apparently not in
>> a browser. Try the root link instead and ignore the other stuff:
>>
>> https://github.com/cuspycode/apache-stuff
>>
>> --
>> Bjorn Danielsson
>> Cuspy Code AB
>>
>>
>> Andy Gumbrecht <ag...@tomitribe.com> wrote:
>> > Bjorn,
>> >
>> > I get a 404 on the link, did you kill it already?
>> >
>> > Andy.
>> >
>> > On 21/07/2014 16:39, Bjorn Danielsson wrote:
>> >> I checked the URL connectivity with curl, and I checked the 302-
>> >> redirect host, and both are responsive on the machine in question.
>> >> Then I temporarily added bogus routes to both hosts, and nothing
>> >> changed. There are no delays due to failed connection attempts.
>> >> In fact the webapp starts as usual, and beans and servlets are
>> >> responsive, it's just that the timers stop working.
>> >>
>> >> I noticed one more thing now when taking a second look at the logs.
>> >> When I redeploy with skipUpdateCheck=true I get log messages about
>> >> QuartzScheduler shutting down during undeployment and about one
>> >> second later it is initialized during deployment. With an empty
>> >> system.properties I get no such messages during redeployment,
>> >> only at start and stop of tomee itself.
>> >>
>> >> Here is a small ant project that reproduces the behaviour:
>> >>
>> >> svn co https://github.com/cuspycode/apache-stuff/trunk/schedule-bug
>> >>
>>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Romain Manni-Bucau <rm...@gmail.com>.
How do you deploy it? deploying it at startup then hitting several times
reload works fine



Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau


2014-07-21 18:52 GMT+02:00 Bjorn Danielsson <
bjorn-apache@lists.cuspycode.com>:

> Andy,
>
> No I was just trying to be clever and give a subversion link to
> a Github subdirectory. It works with svn but apparently not in
> a browser. Try the root link instead and ignore the other stuff:
>
> https://github.com/cuspycode/apache-stuff
>
> --
> Bjorn Danielsson
> Cuspy Code AB
>
>
> Andy Gumbrecht <ag...@tomitribe.com> wrote:
> > Bjorn,
> >
> > I get a 404 on the link, did you kill it already?
> >
> > Andy.
> >
> > On 21/07/2014 16:39, Bjorn Danielsson wrote:
> >> I checked the URL connectivity with curl, and I checked the 302-
> >> redirect host, and both are responsive on the machine in question.
> >> Then I temporarily added bogus routes to both hosts, and nothing
> >> changed. There are no delays due to failed connection attempts.
> >> In fact the webapp starts as usual, and beans and servlets are
> >> responsive, it's just that the timers stop working.
> >>
> >> I noticed one more thing now when taking a second look at the logs.
> >> When I redeploy with skipUpdateCheck=true I get log messages about
> >> QuartzScheduler shutting down during undeployment and about one
> >> second later it is initialized during deployment. With an empty
> >> system.properties I get no such messages during redeployment,
> >> only at start and stop of tomee itself.
> >>
> >> Here is a small ant project that reproduces the behaviour:
> >>
> >> svn co https://github.com/cuspycode/apache-stuff/trunk/schedule-bug
> >>
>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Bjorn Danielsson <bj...@lists.cuspycode.com>.
Andy,

No I was just trying to be clever and give a subversion link to
a Github subdirectory. It works with svn but apparently not in
a browser. Try the root link instead and ignore the other stuff:

https://github.com/cuspycode/apache-stuff

-- 
Bjorn Danielsson
Cuspy Code AB


Andy Gumbrecht <ag...@tomitribe.com> wrote:
> Bjorn,
>
> I get a 404 on the link, did you kill it already?
>
> Andy.
>
> On 21/07/2014 16:39, Bjorn Danielsson wrote:
>> I checked the URL connectivity with curl, and I checked the 302-
>> redirect host, and both are responsive on the machine in question.
>> Then I temporarily added bogus routes to both hosts, and nothing
>> changed. There are no delays due to failed connection attempts.
>> In fact the webapp starts as usual, and beans and servlets are
>> responsive, it's just that the timers stop working.
>>
>> I noticed one more thing now when taking a second look at the logs.
>> When I redeploy with skipUpdateCheck=true I get log messages about
>> QuartzScheduler shutting down during undeployment and about one
>> second later it is initialized during deployment. With an empty
>> system.properties I get no such messages during redeployment,
>> only at start and stop of tomee itself.
>>
>> Here is a small ant project that reproduces the behaviour:
>>
>> svn co https://github.com/cuspycode/apache-stuff/trunk/schedule-bug
>>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Andy Gumbrecht <ag...@tomitribe.com>.
Bjorn,

I get a 404 on the link, did you kill it already?

Andy.

On 21/07/2014 16:39, Bjorn Danielsson wrote:
> I checked the URL connectivity with curl, and I checked the 302-
> redirect host, and both are responsive on the machine in question.
> Then I temporarily added bogus routes to both hosts, and nothing
> changed. There are no delays due to failed connection attempts.
> In fact the webapp starts as usual, and beans and servlets are
> responsive, it's just that the timers stop working.
>
> I noticed one more thing now when taking a second look at the logs.
> When I redeploy with skipUpdateCheck=true I get log messages about
> QuartzScheduler shutting down during undeployment and about one
> second later it is initialized during deployment. With an empty
> system.properties I get no such messages during redeployment,
> only at start and stop of tomee itself.
>
> Here is a small ant project that reproduces the behaviour:
>
> svn co https://github.com/cuspycode/apache-stuff/trunk/schedule-bug
>

-- 
   Andy Gumbrecht

   http://www.tomitribe.com
   agumbrecht@tomitribe.com
   https://twitter.com/AndyGeeDe

   TomEE treibt Tomitribe! | http://tomee.apache.org


Re: non blocking i/o and async servlets (servlet 3.1)

Posted by Alex Soto <as...@gmail.com>.
Well it was a simple HelloWorldServlet which creates an asyncContext, get a
writer from response and prints "Hello World".

it was something like:

public void doGet(HttpServletRequest request, HttpServletResponse response)
 throws ...{

AsyncContext ac = request.startAsync(request, response);
ac.start(()-> {
ac.getResponse().getWriter().println("Hello World");
});
}

Hope this helps but it was as simple as this.

I was using Tomee 1.7 and Java 8



2014-07-25 18:03 GMT+02:00 Vamsee Lakamsani <va...@yahoo.com.invalid>:

> Hi Alex, are you able to share that demo via some git repo?
>
>
> ________________________________
>  From: Alex Soto <as...@gmail.com>
> To: "users@tomee.apache.org" <us...@tomee.apache.org>
> Sent: Thursday, July 24, 2014 11:21 PM
> Subject: Re: non blocking i/o and async servlets (servlet 3.1)
>
>
> Yes I tried yesterday in a demo and it worked. You won't have jax-rs async
> support since Apache cxf3 is integrated but for Servlet no problem at all.
>
>
>
>
>
> 2014-07-25 7:37 GMT+02:00 Romain Manni-Bucau <rm...@gmail.com>:
>
> > Depend which parts but async context is in ee 6 and already helps a lot
> > regarding it.
> >  Le 25 juil. 2014 06:26, "Vamsee Lakamsani" <va...@yahoo.com.invalid> a
> > écrit :
> >
> > > http://docs.oracle.com/javaee/7/tutorial/doc/servlets013.htm
> > >
> > >
> > > Is it possible to do the above by adding "some" EE 7 jars to TomEE 1.6
> or
> > > 1.7 or is it only possible when TomEE 2.0 arrives later this year with
> > > Tomcat8 in it?
> > >
> >
>
>
>
> --
> +----------------------------------------------------------+
>   Alex Soto Bueno - Computer Engineer
>   www.lordofthejars.com
>
> +----------------------------------------------------------+




-- 
+----------------------------------------------------------+
  Alex Soto Bueno - Computer Engineer
  www.lordofthejars.com
+----------------------------------------------------------+

Re: non blocking i/o and async servlets (servlet 3.1)

Posted by Vamsee Lakamsani <va...@yahoo.com.INVALID>.
Hi Alex, are you able to share that demo via some git repo?


________________________________
 From: Alex Soto <as...@gmail.com>
To: "users@tomee.apache.org" <us...@tomee.apache.org> 
Sent: Thursday, July 24, 2014 11:21 PM
Subject: Re: non blocking i/o and async servlets (servlet 3.1)
 

Yes I tried yesterday in a demo and it worked. You won't have jax-rs async
support since Apache cxf3 is integrated but for Servlet no problem at all.





2014-07-25 7:37 GMT+02:00 Romain Manni-Bucau <rm...@gmail.com>:

> Depend which parts but async context is in ee 6 and already helps a lot
> regarding it.
>  Le 25 juil. 2014 06:26, "Vamsee Lakamsani" <va...@yahoo.com.invalid> a
> écrit :
>
> > http://docs.oracle.com/javaee/7/tutorial/doc/servlets013.htm
> >
> >
> > Is it possible to do the above by adding "some" EE 7 jars to TomEE 1.6 or
> > 1.7 or is it only possible when TomEE 2.0 arrives later this year with
> > Tomcat8 in it?
> >
>



-- 
+----------------------------------------------------------+
  Alex Soto Bueno - Computer Engineer
  www.lordofthejars.com

+----------------------------------------------------------+

Re: non blocking i/o and async servlets (servlet 3.1)

Posted by Alex Soto <as...@gmail.com>.
Yes I tried yesterday in a demo and it worked. You won't have jax-rs async
support since Apache cxf3 is integrated but for Servlet no problem at all.


2014-07-25 7:37 GMT+02:00 Romain Manni-Bucau <rm...@gmail.com>:

> Depend which parts but async context is in ee 6 and already helps a lot
> regarding it.
>  Le 25 juil. 2014 06:26, "Vamsee Lakamsani" <va...@yahoo.com.invalid> a
> écrit :
>
> > http://docs.oracle.com/javaee/7/tutorial/doc/servlets013.htm
> >
> >
> > Is it possible to do the above by adding "some" EE 7 jars to TomEE 1.6 or
> > 1.7 or is it only possible when TomEE 2.0 arrives later this year with
> > Tomcat8 in it?
> >
>



-- 
+----------------------------------------------------------+
  Alex Soto Bueno - Computer Engineer
  www.lordofthejars.com
+----------------------------------------------------------+

Re: non blocking i/o and async servlets (servlet 3.1)

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Depend which parts but async context is in ee 6 and already helps a lot
regarding it.
 Le 25 juil. 2014 06:26, "Vamsee Lakamsani" <va...@yahoo.com.invalid> a
écrit :

> http://docs.oracle.com/javaee/7/tutorial/doc/servlets013.htm
>
>
> Is it possible to do the above by adding "some" EE 7 jars to TomEE 1.6 or
> 1.7 or is it only possible when TomEE 2.0 arrives later this year with
> Tomcat8 in it?
>

non blocking i/o and async servlets (servlet 3.1)

Posted by Vamsee Lakamsani <va...@yahoo.com.INVALID>.
http://docs.oracle.com/javaee/7/tutorial/doc/servlets013.htm


Is it possible to do the above by adding "some" EE 7 jars to TomEE 1.6 or 1.7 or is it only possible when TomEE 2.0 arrives later this year with Tomcat8 in it?

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hmm yes
it creates a scheduler by bean then IIRC, can be linked



Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau


2014-07-21 16:39 GMT+02:00 Bjorn Danielsson <
bjorn-apache@lists.cuspycode.com>:

> I checked the URL connectivity with curl, and I checked the 302-
> redirect host, and both are responsive on the machine in question.
> Then I temporarily added bogus routes to both hosts, and nothing
> changed. There are no delays due to failed connection attempts.
> In fact the webapp starts as usual, and beans and servlets are
> responsive, it's just that the timers stop working.
>
> I noticed one more thing now when taking a second look at the logs.
> When I redeploy with skipUpdateCheck=true I get log messages about
> QuartzScheduler shutting down during undeployment and about one
> second later it is initialized during deployment. With an empty
> system.properties I get no such messages during redeployment,
> only at start and stop of tomee itself.
>
> Here is a small ant project that reproduces the behaviour:
>
> svn co https://github.com/cuspycode/apache-stuff/trunk/schedule-bug
>
> --
> Bjorn Danielsson
> Cuspy Code AB
>
>
> Andy Gumbrecht <ag...@tomitribe.com> wrote:
> > Bjorn,
> >
> > We actually check for and explicitly set this property with the
> > default to skip.
> >
> > System.setProperty("org.terracotta.quartz.skipUpdateCheck"
> >             ,
> > System.getProperty("org.terracotta.quartz.skipUpdateCheck", "true"));
> >
> > The 'only' thing I can imagine is that the value is not being read as
> > true' - maybe a typo or codepage issue (check the file encoding of the
> > system.properties file).
> > The actual update check is in Quartz and it uses a host name that
> > needs to be DNS resolved, and then actually polls their server (which
> > can take ages sometimes).
> >
> > It uses this URL
> >
> http://www.terracotta.org/kit/reflector?kitID=quartz&pageID=update.properties
> ',
> > so just out of interest can you try and browse that on the machine
> > that hangs?
> >
> > Thanks,
> >
> > Andy.
> >
> > PS. I hope you're not using TomEE to 'spam spam spam' people :-P
> >
> > On 21/07/2014 12:53, Bjorn Danielsson wrote:
> >> Thanks Andy. Here is the code I used:
> >>
> >> package foo;
> >>
> >> import javax.ejb.*;
> >> import java.util.logging.Logger;
> >>
> >> @Singleton
> >> @Lock(LockType.READ)
> >> @Startup
> >> public class BugBean {
> >>      static final Logger logger =
> Logger.getLogger(BugBean.class.getName());
> >>
> >>      @Lock(LockType.WRITE)
> >>      @Schedule(second="*/5", minute="*", hour="*")
> >>      public void spam() {
> >>      logger.info("Spam spam spam");
> >>      }
> >>
> >> }
> >>
>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Bjorn Danielsson <bj...@lists.cuspycode.com>.
I checked the URL connectivity with curl, and I checked the 302-
redirect host, and both are responsive on the machine in question.
Then I temporarily added bogus routes to both hosts, and nothing
changed. There are no delays due to failed connection attempts.
In fact the webapp starts as usual, and beans and servlets are
responsive, it's just that the timers stop working.

I noticed one more thing now when taking a second look at the logs.
When I redeploy with skipUpdateCheck=true I get log messages about
QuartzScheduler shutting down during undeployment and about one
second later it is initialized during deployment. With an empty
system.properties I get no such messages during redeployment,
only at start and stop of tomee itself.

Here is a small ant project that reproduces the behaviour:

svn co https://github.com/cuspycode/apache-stuff/trunk/schedule-bug

-- 
Bjorn Danielsson
Cuspy Code AB


Andy Gumbrecht <ag...@tomitribe.com> wrote:
> Bjorn,
>
> We actually check for and explicitly set this property with the
> default to skip.
>
> System.setProperty("org.terracotta.quartz.skipUpdateCheck"
>             ,
> System.getProperty("org.terracotta.quartz.skipUpdateCheck", "true"));
>
> The 'only' thing I can imagine is that the value is not being read as
> true' - maybe a typo or codepage issue (check the file encoding of the
> system.properties file).
> The actual update check is in Quartz and it uses a host name that
> needs to be DNS resolved, and then actually polls their server (which
> can take ages sometimes).
>
> It uses this URL
> http://www.terracotta.org/kit/reflector?kitID=quartz&pageID=update.properties',
> so just out of interest can you try and browse that on the machine
> that hangs?
>
> Thanks,
>
> Andy.
>
> PS. I hope you're not using TomEE to 'spam spam spam' people :-P
>
> On 21/07/2014 12:53, Bjorn Danielsson wrote:
>> Thanks Andy. Here is the code I used:
>>
>> package foo;
>>
>> import javax.ejb.*;
>> import java.util.logging.Logger;
>>
>> @Singleton
>> @Lock(LockType.READ)
>> @Startup
>> public class BugBean {
>>      static final Logger logger = Logger.getLogger(BugBean.class.getName());
>>
>>      @Lock(LockType.WRITE)
>>      @Schedule(second="*/5", minute="*", hour="*")
>>      public void spam() {
>> 	logger.info("Spam spam spam");
>>      }
>>
>> }
>>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Andy Gumbrecht <ag...@tomitribe.com>.
Bjorn,

We actually check for and explicitly set this property with the default 
to skip.

System.setProperty("org.terracotta.quartz.skipUpdateCheck"
             , 
System.getProperty("org.terracotta.quartz.skipUpdateCheck", "true"));

The 'only' thing I can imagine is that the value is not being read as 
'true' - maybe a typo or codepage issue (check the file encoding of the 
system.properties file).
The actual update check is in Quartz and it uses a host name that needs 
to be DNS resolved, and then actually polls their server (which can take 
ages sometimes).

It uses this URL 
'http://www.terracotta.org/kit/reflector?kitID=quartz&pageID=update.properties', 
so just out of interest can you try and browse that on the machine that 
hangs?

Thanks,

Andy.

PS. I hope you're not using TomEE to 'spam spam spam' people :-P

On 21/07/2014 12:53, Bjorn Danielsson wrote:
> Thanks Andy. Here is the code I used:
>
> package foo;
>
> import javax.ejb.*;
> import java.util.logging.Logger;
>
> @Singleton
> @Lock(LockType.READ)
> @Startup
> public class BugBean {
>      static final Logger logger = Logger.getLogger(BugBean.class.getName());
>
>      @Lock(LockType.WRITE)
>      @Schedule(second="*/5", minute="*", hour="*")
>      public void spam() {
> 	logger.info("Spam spam spam");
>      }
>
> }
>

-- 
   Andy Gumbrecht

   http://www.tomitribe.com
   agumbrecht@tomitribe.com
   https://twitter.com/AndyGeeDe

   TomEE treibt Tomitribe! | http://tomee.apache.org


Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Bjorn Danielsson <bj...@lists.cuspycode.com>.
Thanks Andy. Here is the code I used:

package foo;

import javax.ejb.*;
import java.util.logging.Logger;

@Singleton
@Lock(LockType.READ)
@Startup
public class BugBean {
    static final Logger logger = Logger.getLogger(BugBean.class.getName());

    @Lock(LockType.WRITE)
    @Schedule(second="*/5", minute="*", hour="*")
    public void spam() {
	logger.info("Spam spam spam");
    }

}

-- 
Bjorn Danielsson
Cuspy Code AB


Andy Gumbrecht <ag...@tomitribe.com> wrote:
> I'll check why this would block your deployment. It really should not hang.
>
> Andy.
>
> On 21/07/2014 12:11, Bjorn Danielsson wrote:
>> Hi,
>>
>> I noticed that all @Schedule methods stop working after hot
>> redeployment on one of my machines, and the culprit turned out
>> to be that I had forgotten to remove this from system.properties
>> after upgrading the machine to TomEE 1.6.0 a long time ago:
>>
>> org.terracotta.quartz.skipUpdateCheck=true
>>
>> This strange behaviour remains in today's 1.7.0-SNAPSHOT.
>>
>> Removing the line makes everything work again.
>>
>> I just thought I'd mention it here for the search engines.
>>

Re: Spooky org.terracotta.quartz.skipUpdateCheck

Posted by Andy Gumbrecht <ag...@tomitribe.com>.
I'll check why this would block your deployment. It really should not hang.

Andy.

On 21/07/2014 12:11, Bjorn Danielsson wrote:
> Hi,
>
> I noticed that all @Schedule methods stop working after hot
> redeployment on one of my machines, and the culprit turned out
> to be that I had forgotten to remove this from system.properties
> after upgrading the machine to TomEE 1.6.0 a long time ago:
>
> org.terracotta.quartz.skipUpdateCheck=true
>
> This strange behaviour remains in today's 1.7.0-SNAPSHOT.
>
> Removing the line makes everything work again.
>
> I just thought I'd mention it here for the search engines.
>

-- 
   Andy Gumbrecht

   http://www.tomitribe.com
   agumbrecht@tomitribe.com
   https://twitter.com/AndyGeeDe

   TomEE treibt Tomitribe! | http://tomee.apache.org