You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by hussayn <hu...@saxess.com> on 2008/09/09 16:36:01 UTC

how can i disable cocoon's periodic file system checking ?

Hi; 

I detected some cpu-load spikes about every 3 seconds when i run cocoon on a
windows-xp machine (using mvn jetty:run). I guess, this is a periodic file
system checker, which is working in the background.

while this makes sense in a dev system, it will certainly be unnecessary at
least in my production environment...

Well... i can't figure out, how to configure cocoon2-2, especially how to
disable file system checking.

Is there anybody around here, who can give me a hint ? Maybe there is some
documentation available, which i am not aware off ?

thank you in advance,
regards, hussayn

-- 
View this message in context: http://www.nabble.com/how-can-i-disable-cocoon%27s-periodic-file-system-checking---tp19393729p19393729.html
Sent from the Cocoon - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: how can i disable cocoon's periodic file system checking ?

Posted by hussayn <hu...@saxess.com>.
Hi, Grzegorz

Thank you for your quick reply.


Grzegorz Kossakowski-2 wrote:
> 
> Actually, the question is how you build your block.
> 
> Do you just copy generated webapp folder from target directory of your
> _block_?
> 

Yes, somewhat alike that. to be exact, i checked my work (but not the target
folder) 
into our version control system, then went to our test server and checked
out the project and
run mvn jetty:run ... thus i still got the "dev" version. That's the step,
where i made a big 
mistake and trouble started for me...

I was completely unaware of the fact, that i needed to create a webapp using
archetype 3
although it was mentioned somewhere in the tutorial. I just thought i
already have a webapp and 
i only need to configure it correctly... and so i simply missed this "deploy
step". Well then i detected the
file checker and for me naturally i was asking myself, how can i disable it,
or at least how can i
change the checking period.

Well, ok, now as you pointed me to it, and after i carefully reread the
whole basic tutorial, 
i created a deployable webapp according to the docs and now the resource
checker is gone and so is the high cpu-load. Thanks a lot for this !!!!

Maybe it is worthwhile to also mention this:
After i read your remarks above, i first tried to simply chage the plugin
type from "jar" to 
"war" in my "dev" block, but that did not really help. The resource checker
kept in the system.
Only after i worked through the "deploying your block"  manual, the final
result 
behaves as expected (no more cpu-consumption when idle, great!)

For the documentation: 

I propose to add something like the following hint to the end of the
documentation of "your first cocoon-app":

======================================================================
"Now you have created your first cocoon-block and successfully run it using
the jetty-server.
Note, that you have created a development environemt, which allows you to
dynamically change
your resources. And cocoon will always know after a few seconds, which
resources have to be 
dynamically reloaded. Thus your block is now enabled for rapid development:
Just modify the sources,
then reload on your browser and see the changes without
redeploying/reloading your webapp every time. 

On the downside, your block will consume a significant amount of your
computer resources, which is OK for development, but not for  production.
Hence, once you are finished with your development, and move to production
with your block, then we highly recommend, that you proceed according to the
" http://cocoon.apache.org/2.2/1362_1_1.html deploy your first cocoon-app "
tutorial."
======================================================================

thank you again very much for your advice!

Just to be complete: What if i WANTED to have the resource checker in my
productive environment, but change the period from ~3 seconds to 60 seconds
? How would i achieve that ?

regards,
hussayn
-- 
View this message in context: http://www.nabble.com/how-can-i-disable-cocoon%27s-periodic-file-system-checking---tp19393729p19418066.html
Sent from the Cocoon - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: how can i disable cocoon's periodic file system checking ?

Posted by Grzegorz Kossakowski <gr...@tuffmail.com>.
hussayn pisze:
> Hi; 
> 
> I detected some cpu-load spikes about every 3 seconds when i run cocoon on a
> windows-xp machine (using mvn jetty:run). I guess, this is a periodic file
> system checker, which is working in the background.
> 
> while this makes sense in a dev system, it will certainly be unnecessary at
> least in my production environment...
> 
> Well... i can't figure out, how to configure cocoon2-2, especially how to
> disable file system checking.
> 
> Is there anybody around here, who can give me a hint ? Maybe there is some
> documentation available, which i am not aware off ?

Actually, the question is how you build your block.

Do you just copy generated webapp folder from target directory of your _block_?

It's Cocoon Maven plug-in responsible for setting up reloading environment, see [1]. The same 
plug-in (with different goal - cocoon:deploy[2]) can be used to generate production-ready webapp 
which has no reloading or other resource-intensive tasks enabled.

The solution should be to follow "Deploying a Cocoon application" tutorial[3]


[1] http://cocoon.apache.org/2.2/maven-plugins/maven-plugin/1.0/1359_1_1.html
[2] http://cocoon.apache.org/2.2/maven-plugins/maven-plugin/1.0/1358_1_1.html
[3] http://cocoon.apache.org/2.2/1362_1_1.html

-- 
Grzegorz Kossakowski

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org