Re: Jetty lock on JS-files in classpath breaks eclipse autobuild

2009-10-28 Thread Felix Gonschorek

Hi Inge,

one of our developers had the same issues (eclipse, jetty, maven) on 
windows XP - we tried several configurations (including the disabled 
jetty lock) without success. the problem disappeared after a fresh 
install of windows xp; we could not get rid of the problem with in any 
other way (tried several jetty configurations, re-installed eclipse and 
jre, disabled locking, ...)


the lock occured on css files.

the problem has not occured on linux or mac development machines.

just to let you know, that you are not alone with this problem :)


felix

Inge Solvoll schrieb:

Hi!

I'm having problems with my development environment.

First of all: I have set the useFileMappedBuffer=false in
/etc/webdefault.xml

My problem is that Tapestry 5 Javascript files located in WEB-INF/classes
and subfolders are locked by Jetty. This prevents eclipse from deleting
WEB-INF/classes to do a rebuild after I make a change in a java file. The
end result is that most class files are deleted and not rebuilt, so I have
to stop jetty, do a manual rebuild, and then start Jetty again. This if, of
course, a disaster for me...

Does anyone here have a clue on how to prevent Jetty from locking the
resource files in WEB-INF/classes?

  


Re: Jetty lock on JS-files in classpath breaks eclipse autobuild

2009-10-28 Thread Luther Baker
I had this same problem - but it was solved with the
useFileMappedBuffer=false solution. One difference was that I didn't change
/etc/webdefault.xml - I actually copied webdefault.xml into my project and
updated my pom file:

plugin
groupIdorg.mortbay.jetty/groupId
artifactIdmaven-jetty-plugin/artifactId
configuration
contextPath/bingo/contextPath
scanIntervalSeconds3/scanIntervalSeconds

webDefaultXmlsrc/main/config/jetty/webdefault.xml/webDefaultXml
 connectors
connector
implementation=org.mortbay.jetty.nio.SelectChannelConnector
  port9090/port
  maxIdleTime6/maxIdleTime
/connector
  /connectors
  /configuration
/plugin

If it isn't clear, I use jetty:run ala maven from within my Eclipse
environment. Obviously, every project ends up with a copy of webdefault.xml,
but otherwise it turned out to be a straightfoward fix.

-Luther





On Wed, Oct 28, 2009 at 11:02 AM, Felix Gonschorek fe...@ggmedia.netwrote:

 Hi Inge,

 one of our developers had the same issues (eclipse, jetty, maven) on
 windows XP - we tried several configurations (including the disabled jetty
 lock) without success. the problem disappeared after a fresh install of
 windows xp; we could not get rid of the problem with in any other way (tried
 several jetty configurations, re-installed eclipse and jre, disabled
 locking, ...)

 the lock occured on css files.

 the problem has not occured on linux or mac development machines.

 just to let you know, that you are not alone with this problem :)


 felix

 Inge Solvoll schrieb:

  Hi!

 I'm having problems with my development environment.

 First of all: I have set the useFileMappedBuffer=false in
 /etc/webdefault.xml

 My problem is that Tapestry 5 Javascript files located in WEB-INF/classes
 and subfolders are locked by Jetty. This prevents eclipse from deleting
 WEB-INF/classes to do a rebuild after I make a change in a java file. The
 end result is that most class files are deleted and not rebuilt, so I have
 to stop jetty, do a manual rebuild, and then start Jetty again. This if,
 of
 course, a disaster for me...

 Does anyone here have a clue on how to prevent Jetty from locking the
 resource files in WEB-INF/classes?






Re: Jetty lock on JS-files in classpath breaks eclipse autobuild

2009-10-28 Thread Howard Lewis Ship
I've hit this problem too, on a client's project using RunJettyRun.

The solution is to move classpath resources from src/main/java (or
equivalent) to src/main/resources (or equivalent) and add
src/main/resources as a class folder.  Thiis keeps Eclipse from trying
to copy the files (from src/main/java to classes) when they change and
that seems to keep everyone happy.




On Tue, Oct 6, 2009 at 11:40 PM, Inge Solvoll inge.tapes...@gmail.com wrote:
 The file synch approach worked nicely. But it would be nice to hear about
 other and possibly better solutions, as this is a hack that is a bit
 cumbersome to distribute among our developers...

 My environment:

 T5.1.0.5
 Eclipse 3.4
 Vista 64 bit
 Java 1.6u17 64 bit
 Jetty 6.1.12rc1

 I have configured jetty to point to my project directory to launch the
 webapp through a mycontext.xml in jetty-home/contexts. My project
 structure is pretty much a war layout, with all java files and T5 resource
 files in CVS under project-root/src. We're planning migration from ant to
 Maven, but no luck getting the resources needed yet.

 Howard: In what way are classes folders added to the runtime path? I guess
 they are in eclipse, but is the webapp running on a standalone jetty aware
 of their existence? When I set WEB-INF/classes as build target for my src
 folder, all class files end up there, accessible in a standard webapp way.
 Are other classes folders added as jars in WEB-INF/lib?

 On Tue, Oct 6, 2009 at 7:18 PM, Howard Lewis Ship hls...@gmail.com wrote:

 One option here is to put your non-Java resources into a folder,
 src/main/resources, and mark that folder as a classes folder (not a
 source folder). classes folder are simply added to the runtime path
 with no copying. This is what I do.

 On Tue, Oct 6, 2009 at 7:59 AM, Peter Stavrinides
 p.stavrini...@albourne.com wrote:
  What is your exact environment / configuration?
 
  - Original Message -
  From: Inge Solvoll inge.tapes...@gmail.com
  To: Tapestry users users@tapestry.apache.org
  Sent: Tuesday, 6 October, 2009 10:57:30 GMT +02:00 Athens, Beirut,
 Bucharest, Istanbul
  Subject: Jetty lock on JS-files in classpath breaks eclipse autobuild
 
  Hi!
 
  I'm having problems with my development environment.
 
  First of all: I have set the useFileMappedBuffer=false in
  /etc/webdefault.xml
 
  My problem is that Tapestry 5 Javascript files located in WEB-INF/classes
  and subfolders are locked by Jetty. This prevents eclipse from deleting
  WEB-INF/classes to do a rebuild after I make a change in a java file. The
  end result is that most class files are deleted and not rebuilt, so I
 have
  to stop jetty, do a manual rebuild, and then start Jetty again. This if,
 of
  course, a disaster for me...
 
  Does anyone here have a clue on how to prevent Jetty from locking the
  resource files in WEB-INF/classes?
 
  -
  To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
  For additional commands, e-mail: users-h...@tapestry.apache.org
 
 



 --
 Howard M. Lewis Ship

 Creator of Apache Tapestry

 The source for Tapestry training, mentoring and support. Contact me to
 learn how I can get you up and productive in Tapestry fast!

 (971) 678-5210
 http://howardlewisship.com

 -
 To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
 For additional commands, e-mail: users-h...@tapestry.apache.org






-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to
learn how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Jetty lock on JS-files in classpath breaks eclipse autobuild

2009-10-28 Thread Thiago H. de Paula Figueiredo
I'm not using any Eclipse plugins: I just wrote a class (I call it Main)  
in the test sources folder and added Jetty 6.1.14 as a test dependency. My  
Main class has code in its main() method:


Server server = new Server();

Connector connector = new SelectChannelConnector();
connector.setPort(80);
server.setConnectors(new Connector[] { connector });

WebAppContext webapp = new WebAppContext();
webapp.setParentLoaderPriority(true);
webapp.setContextPath(/);
webapp.setResourceBase(src/main/webapp);
webapp.setDefaultsDescriptor(webapp.getResourceBase() +  
/WEB-INF/webdefault.xml);

server.setHandler(webapp);

server.start();
server.join();

--
Thiago H. de Paula Figueiredo
Independent Java consultant, developer, and instructor
http://www.arsmachina.com.br/thiago

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Jetty lock on JS-files in classpath breaks eclipse autobuild

2009-10-07 Thread Inge Solvoll
The file synch approach worked nicely. But it would be nice to hear about
other and possibly better solutions, as this is a hack that is a bit
cumbersome to distribute among our developers...

My environment:

T5.1.0.5
Eclipse 3.4
Vista 64 bit
Java 1.6u17 64 bit
Jetty 6.1.12rc1

I have configured jetty to point to my project directory to launch the
webapp through a mycontext.xml in jetty-home/contexts. My project
structure is pretty much a war layout, with all java files and T5 resource
files in CVS under project-root/src. We're planning migration from ant to
Maven, but no luck getting the resources needed yet.

Howard: In what way are classes folders added to the runtime path? I guess
they are in eclipse, but is the webapp running on a standalone jetty aware
of their existence? When I set WEB-INF/classes as build target for my src
folder, all class files end up there, accessible in a standard webapp way.
Are other classes folders added as jars in WEB-INF/lib?

On Tue, Oct 6, 2009 at 7:18 PM, Howard Lewis Ship hls...@gmail.com wrote:

 One option here is to put your non-Java resources into a folder,
 src/main/resources, and mark that folder as a classes folder (not a
 source folder). classes folder are simply added to the runtime path
 with no copying. This is what I do.

 On Tue, Oct 6, 2009 at 7:59 AM, Peter Stavrinides
 p.stavrini...@albourne.com wrote:
  What is your exact environment / configuration?
 
  - Original Message -
  From: Inge Solvoll inge.tapes...@gmail.com
  To: Tapestry users users@tapestry.apache.org
  Sent: Tuesday, 6 October, 2009 10:57:30 GMT +02:00 Athens, Beirut,
 Bucharest, Istanbul
  Subject: Jetty lock on JS-files in classpath breaks eclipse autobuild
 
  Hi!
 
  I'm having problems with my development environment.
 
  First of all: I have set the useFileMappedBuffer=false in
  /etc/webdefault.xml
 
  My problem is that Tapestry 5 Javascript files located in WEB-INF/classes
  and subfolders are locked by Jetty. This prevents eclipse from deleting
  WEB-INF/classes to do a rebuild after I make a change in a java file. The
  end result is that most class files are deleted and not rebuilt, so I
 have
  to stop jetty, do a manual rebuild, and then start Jetty again. This if,
 of
  course, a disaster for me...
 
  Does anyone here have a clue on how to prevent Jetty from locking the
  resource files in WEB-INF/classes?
 
  -
  To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
  For additional commands, e-mail: users-h...@tapestry.apache.org
 
 



 --
 Howard M. Lewis Ship

 Creator of Apache Tapestry

 The source for Tapestry training, mentoring and support. Contact me to
 learn how I can get you up and productive in Tapestry fast!

 (971) 678-5210
 http://howardlewisship.com

 -
 To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
 For additional commands, e-mail: users-h...@tapestry.apache.org




Re: Jetty lock on JS-files in classpath breaks eclipse autobuild

2009-10-07 Thread Peter Stavrinides
If you are moving to maven the you will have the maven plug-in to run your app, 
and the default maven setup will work out of the box, so really there is very 
little for you to configure. 

Add your source folders (and matching resource folders) to the build path, 
configure the output folder and nothing more.

Peter

-- 
If you are not an intended recipient of this e-mail, please notify the sender, 
delete it and do not read, act upon, print, disclose, copy, retain or 
redistribute it. Please visit http://www.albourne.com/email.html for important 
additional terms relating to this e-mail.

- Original Message -
From: Inge Solvoll inge.tapes...@gmail.com
To: Tapestry users users@tapestry.apache.org
Sent: Wednesday, 7 October, 2009 09:40:36 GMT +02:00 Athens, Beirut, Bucharest, 
Istanbul
Subject: Re: Jetty lock on JS-files in classpath breaks eclipse autobuild

The file synch approach worked nicely. But it would be nice to hear about
other and possibly better solutions, as this is a hack that is a bit
cumbersome to distribute among our developers...

My environment:

T5.1.0.5
Eclipse 3.4
Vista 64 bit
Java 1.6u17 64 bit
Jetty 6.1.12rc1

I have configured jetty to point to my project directory to launch the
webapp through a mycontext.xml in jetty-home/contexts. My project
structure is pretty much a war layout, with all java files and T5 resource
files in CVS under project-root/src. We're planning migration from ant to
Maven, but no luck getting the resources needed yet.

Howard: In what way are classes folders added to the runtime path? I guess
they are in eclipse, but is the webapp running on a standalone jetty aware
of their existence? When I set WEB-INF/classes as build target for my src
folder, all class files end up there, accessible in a standard webapp way.
Are other classes folders added as jars in WEB-INF/lib?

On Tue, Oct 6, 2009 at 7:18 PM, Howard Lewis Ship hls...@gmail.com wrote:

 One option here is to put your non-Java resources into a folder,
 src/main/resources, and mark that folder as a classes folder (not a
 source folder). classes folder are simply added to the runtime path
 with no copying. This is what I do.

 On Tue, Oct 6, 2009 at 7:59 AM, Peter Stavrinides
 p.stavrini...@albourne.com wrote:
  What is your exact environment / configuration?
 
  - Original Message -
  From: Inge Solvoll inge.tapes...@gmail.com
  To: Tapestry users users@tapestry.apache.org
  Sent: Tuesday, 6 October, 2009 10:57:30 GMT +02:00 Athens, Beirut,
 Bucharest, Istanbul
  Subject: Jetty lock on JS-files in classpath breaks eclipse autobuild
 
  Hi!
 
  I'm having problems with my development environment.
 
  First of all: I have set the useFileMappedBuffer=false in
  /etc/webdefault.xml
 
  My problem is that Tapestry 5 Javascript files located in WEB-INF/classes
  and subfolders are locked by Jetty. This prevents eclipse from deleting
  WEB-INF/classes to do a rebuild after I make a change in a java file. The
  end result is that most class files are deleted and not rebuilt, so I
 have
  to stop jetty, do a manual rebuild, and then start Jetty again. This if,
 of
  course, a disaster for me...
 
  Does anyone here have a clue on how to prevent Jetty from locking the
  resource files in WEB-INF/classes?
 
  -
  To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
  For additional commands, e-mail: users-h...@tapestry.apache.org
 
 



 --
 Howard M. Lewis Ship

 Creator of Apache Tapestry

 The source for Tapestry training, mentoring and support. Contact me to
 learn how I can get you up and productive in Tapestry fast!

 (971) 678-5210
 http://howardlewisship.com

 -
 To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
 For additional commands, e-mail: users-h...@tapestry.apache.org



-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Jetty lock on JS-files in classpath breaks eclipse autobuild

2009-10-06 Thread Inge Solvoll
Hi!

I'm having problems with my development environment.

First of all: I have set the useFileMappedBuffer=false in
/etc/webdefault.xml

My problem is that Tapestry 5 Javascript files located in WEB-INF/classes
and subfolders are locked by Jetty. This prevents eclipse from deleting
WEB-INF/classes to do a rebuild after I make a change in a java file. The
end result is that most class files are deleted and not rebuilt, so I have
to stop jetty, do a manual rebuild, and then start Jetty again. This if, of
course, a disaster for me...

Does anyone here have a clue on how to prevent Jetty from locking the
resource files in WEB-INF/classes?


Re: Jetty lock on JS-files in classpath breaks eclipse autobuild

2009-10-06 Thread Peter Stavrinides
What is your exact environment / configuration?

- Original Message -
From: Inge Solvoll inge.tapes...@gmail.com
To: Tapestry users users@tapestry.apache.org
Sent: Tuesday, 6 October, 2009 10:57:30 GMT +02:00 Athens, Beirut, Bucharest, 
Istanbul
Subject: Jetty lock on JS-files in classpath breaks eclipse autobuild

Hi!

I'm having problems with my development environment.

First of all: I have set the useFileMappedBuffer=false in
/etc/webdefault.xml

My problem is that Tapestry 5 Javascript files located in WEB-INF/classes
and subfolders are locked by Jetty. This prevents eclipse from deleting
WEB-INF/classes to do a rebuild after I make a change in a java file. The
end result is that most class files are deleted and not rebuilt, so I have
to stop jetty, do a manual rebuild, and then start Jetty again. This if, of
course, a disaster for me...

Does anyone here have a clue on how to prevent Jetty from locking the
resource files in WEB-INF/classes?

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Jetty lock on JS-files in classpath breaks eclipse autobuild

2009-10-06 Thread Howard Lewis Ship
One option here is to put your non-Java resources into a folder,
src/main/resources, and mark that folder as a classes folder (not a
source folder). classes folder are simply added to the runtime path
with no copying. This is what I do.

On Tue, Oct 6, 2009 at 7:59 AM, Peter Stavrinides
p.stavrini...@albourne.com wrote:
 What is your exact environment / configuration?

 - Original Message -
 From: Inge Solvoll inge.tapes...@gmail.com
 To: Tapestry users users@tapestry.apache.org
 Sent: Tuesday, 6 October, 2009 10:57:30 GMT +02:00 Athens, Beirut, Bucharest, 
 Istanbul
 Subject: Jetty lock on JS-files in classpath breaks eclipse autobuild

 Hi!

 I'm having problems with my development environment.

 First of all: I have set the useFileMappedBuffer=false in
 /etc/webdefault.xml

 My problem is that Tapestry 5 Javascript files located in WEB-INF/classes
 and subfolders are locked by Jetty. This prevents eclipse from deleting
 WEB-INF/classes to do a rebuild after I make a change in a java file. The
 end result is that most class files are deleted and not rebuilt, so I have
 to stop jetty, do a manual rebuild, and then start Jetty again. This if, of
 course, a disaster for me...

 Does anyone here have a clue on how to prevent Jetty from locking the
 resource files in WEB-INF/classes?

 -
 To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
 For additional commands, e-mail: users-h...@tapestry.apache.org





-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to
learn how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org