You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Paul Stanton <pa...@mapshed.com.au> on 2011/12/23 08:51:28 UTC

development with eclipse+tomcat

Its been over 2 years since I started a new production tapestry 
application, and once again in the same server environment we need to do 
our development & testing in the environment familiar with the team: ie 
tomcat.

For productivity, live class reloading, the ability to step through code 
and being able to start and stop the container are all required.

Last time around (T5.1) I tried and failed to arrive at a project setup 
which allowed all of the above with tomcat. I tried to get the 
Sysdeotomcat launcher plugin to work without success, among other 
approaches I have since forgotten.

We ended up compiling into "webapp/WEB-INF/classes" and copying all 
dependencies into "webapp/WEB-INF/lib". This allowed us to achieve all 
of the above, except for live class and template reloading.

Are there any improvements in this space since Tapestry 5.1? Has anyone 
come up with an easy to follow formula for configuring 
tapestry+tomcat+eclipse for development?

Thanks, Paul.

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


Re: development with eclipse+tomcat

Posted by Paul Stanton <pa...@mapshed.com.au>.
Actually, my below theory regarding the contribute's was incorrect - it 
seems to be some kind of race condition with my service bindings.

If I do not eagerLoad any the services in my component library, LCR 
works fine.

If I eagerLoad one of my component library services LCR intermittently 
does not work. By this I mean, for >50% of the server restarts, LCR does 
not work at all.

I have no idea how to debug or fix this...

On 16/01/2012 9:23 PM, Paul Stanton wrote:
> After a couple of weeks working with eclipse+tomcat+live class 
> reloading working just fine I've managed to break it all.
>
> I just included a JAR which is a component library I have written 
> (with its own Module). I used the guide 
> (http://tapestry.apache.org/component-libraries.html) to configure my 
> component library.
>
> Suddenly, live class reloading doesn't work anymore!
>
> I narrowed it down to having either of 
> 'contributeComponentClassResolver' or 
> 'contributeClasspathAssetAliasManager' in the component library's 
> module - if I remove them both, LCR works once again.
>
> However, I then can't use my component library...
>
> Can anyone help me use LCR & my component library?
>
> Thanks, Paul.
>
> On 11/01/2012 4:10 PM, Paul Stanton wrote:
>> kalle, one other tip for your document which was a bit of a gotcha 
>> today (when adding a 2nd project):
>>
>> Make sure 'Automatically compute' is checked on the 'Source path' 
>> page of window>preferences>tomcat section.
>>
>> This tip could go between point 6.3 and 6.4.
>>
>> On 7/01/2012 3:24 PM, Kalle Korhonen wrote:
>>> On Fri, Dec 23, 2011 at 1:23 PM, Paul Stanton<pa...@mapshed.com.au>  
>>> wrote:
>>>> That document is great, much better than what I could find last 
>>>> time around.
>>>> The only step which I had to go searching elsewhere to solve was 
>>>> finding
>>>> where the "DevLoader" was!
>>>> I figured out (google) that the devloader package is actually 
>>>> within the
>>>> Sysdeo plugin (as a zip) and that you need to:
>>>> 1. extract Devloader.zip from the Sysdeo tomcat plugin archive
>>>> 2. rename Devloader.zip to Devloader.jar
>>>> 3. move Devloader.jar to tomcat/lib
>>>> adding this to the document might save the next guy 15 minutes ;)
>>> Thanks Paul, added. That part actually wasn't up-to-date - for some
>>> time, I had maintained my own version of the devloader (which was
>>> downloadable from this page) until Sysdeo caught up, but hadn't
>>> updated that part of the guide after the official version was
>>> released. No idea about the classloader issue at the moment, have to
>>> look into it.
>>>
>>> Kalle
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>

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


Re: development with eclipse+tomcat

Posted by Paul Stanton <pa...@mapshed.com.au>.
After a couple of weeks working with eclipse+tomcat+live class reloading 
working just fine I've managed to break it all.

I just included a JAR which is a component library I have written (with 
its own Module). I used the guide 
(http://tapestry.apache.org/component-libraries.html) to configure my 
component library.

Suddenly, live class reloading doesn't work anymore!

I narrowed it down to having either of 
'contributeComponentClassResolver' or 
'contributeClasspathAssetAliasManager' in the component library's module 
- if I remove them both, LCR works once again.

However, I then can't use my component library...

Can anyone help me use LCR & my component library?

Thanks, Paul.

On 11/01/2012 4:10 PM, Paul Stanton wrote:
> kalle, one other tip for your document which was a bit of a gotcha 
> today (when adding a 2nd project):
>
> Make sure 'Automatically compute' is checked on the 'Source path' page 
> of window>preferences>tomcat section.
>
> This tip could go between point 6.3 and 6.4.
>
> On 7/01/2012 3:24 PM, Kalle Korhonen wrote:
>> On Fri, Dec 23, 2011 at 1:23 PM, Paul Stanton<pa...@mapshed.com.au>  
>> wrote:
>>> That document is great, much better than what I could find last time 
>>> around.
>>> The only step which I had to go searching elsewhere to solve was 
>>> finding
>>> where the "DevLoader" was!
>>> I figured out (google) that the devloader package is actually within 
>>> the
>>> Sysdeo plugin (as a zip) and that you need to:
>>> 1. extract Devloader.zip from the Sysdeo tomcat plugin archive
>>> 2. rename Devloader.zip to Devloader.jar
>>> 3. move Devloader.jar to tomcat/lib
>>> adding this to the document might save the next guy 15 minutes ;)
>> Thanks Paul, added. That part actually wasn't up-to-date - for some
>> time, I had maintained my own version of the devloader (which was
>> downloadable from this page) until Sysdeo caught up, but hadn't
>> updated that part of the guide after the official version was
>> released. No idea about the classloader issue at the moment, have to
>> look into it.
>>
>> Kalle
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>

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


Re: development with eclipse+tomcat

Posted by Paul Stanton <pa...@mapshed.com.au>.
kalle, one other tip for your document which was a bit of a gotcha today 
(when adding a 2nd project):

Make sure 'Automatically compute' is checked on the 'Source path' page 
of window>preferences>tomcat section.

This tip could go between point 6.3 and 6.4.

On 7/01/2012 3:24 PM, Kalle Korhonen wrote:
> On Fri, Dec 23, 2011 at 1:23 PM, Paul Stanton<pa...@mapshed.com.au>  wrote:
>> That document is great, much better than what I could find last time around.
>> The only step which I had to go searching elsewhere to solve was finding
>> where the "DevLoader" was!
>> I figured out (google) that the devloader package is actually within the
>> Sysdeo plugin (as a zip) and that you need to:
>> 1. extract Devloader.zip from the Sysdeo tomcat plugin archive
>> 2. rename Devloader.zip to Devloader.jar
>> 3. move Devloader.jar to tomcat/lib
>> adding this to the document might save the next guy 15 minutes ;)
> Thanks Paul, added. That part actually wasn't up-to-date - for some
> time, I had maintained my own version of the devloader (which was
> downloadable from this page) until Sysdeo caught up, but hadn't
> updated that part of the guide after the official version was
> released. No idea about the classloader issue at the moment, have to
> look into it.
>
> Kalle
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>

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


Re: development with eclipse+tomcat

Posted by Kalle Korhonen <ka...@gmail.com>.
On Fri, Dec 23, 2011 at 1:23 PM, Paul Stanton <pa...@mapshed.com.au> wrote:
> That document is great, much better than what I could find last time around.
> The only step which I had to go searching elsewhere to solve was finding
> where the "DevLoader" was!
> I figured out (google) that the devloader package is actually within the
> Sysdeo plugin (as a zip) and that you need to:
> 1. extract Devloader.zip from the Sysdeo tomcat plugin archive
> 2. rename Devloader.zip to Devloader.jar
> 3. move Devloader.jar to tomcat/lib
> adding this to the document might save the next guy 15 minutes ;)

Thanks Paul, added. That part actually wasn't up-to-date - for some
time, I had maintained my own version of the devloader (which was
downloadable from this page) until Sysdeo caught up, but hadn't
updated that part of the guide after the official version was
released. No idea about the classloader issue at the moment, have to
look into it.

Kalle

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


Re: development with eclipse+tomcat

Posted by Paul Stanton <pa...@mapshed.com.au>.
I think I may have one outstanding issue with this configuration 
regarding classloaders...

         ComponentResources cr = container.getComponentResources();
         Component comp = cr.getEmbeddedComponent(zoneClientId);
         log.debug(Zone.class.getName() + " == " + 
comp.getClass().getName());
         log.debug(Zone.class.getClassLoader() + " == " + 
comp.getClass().getClassLoader());
         Zone zone = (Zone) comp; // <-- ClassCastException

Output:

DEBUG org.apache.tapestry5.corelib.components.Zone == 
org.apache.tapestry5.corelib.components.Zone
DEBUG WebappClassLoader
   context: /myapp
   delegate: false
   repositories:
----------> Parent Classloader:
org.apache.catalina.loader.StandardClassLoader@63b660
  == org.apache.tapestry5.internal.plastic.PlasticClassLoader@6d1fa2
...
Caused by: java.lang.ClassCastException: 
org.apache.tapestry5.corelib.components.Zone cannot be cast to 
org.apache.tapestry5.corelib.components.Zone

So the object returned from ComponentResources.getEmbeddedComponent is 
from the tapestry classloader, while the Zone class is from the default 
classloader.

Is there a way to resolve this?

Thanks, p.

On 24/12/2011 8:37 PM, Paul Stanton wrote:
> I solved the problem ..
>
> it seems my changes to the 'tomcat' settings for the project were not 
> persisting or changing the ".tomcatplugin" file which was still 
> referencing the old maven dependencies...
>
> after simplifying the pom, deleting ".tomcatplugin" and re-applying 
> the settings in the "tomcat" settings page, I have it all working!!
>
> very nice, this will save me + team much time in the near future.
>
> thanks for the advice and all the best in the new year.
>
> cheers, Paul.
>
> On 24/12/2011 8:23 AM, Paul Stanton wrote:
>> Thanks Kalle,
>>
>> That document is great, much better than what I could find last time 
>> around.
>>
>> The only step which I had to go searching elsewhere to solve was 
>> finding where the "DevLoader" was!
>>
>> "7. Install devloader for Tomcat (for Tomcat 7.x use devloader from 
>> version 3.3). Unzip and copy the org folder and its contents to 
>> TOMCAT_HOME/lib"
>>
>> I figured out (google) that the devloader package is actually within 
>> the Sysdeo plugin (as a zip) and that you need to:
>> 1. extract Devloader.zip from the Sysdeo tomcat plugin archive
>> 2. rename Devloader.zip to Devloader.jar
>> 3. move Devloader.jar to tomcat/lib
>>
>> adding this to the document might save the next guy 15 minutes ;)
>>
>> Other than that, I think I am almost there, except I am getting then 
>> exception when tomcat starts:
>>
>> ClassCastException "org.apache.tapestry5.TapestryFilter cannot be 
>> cast to javax.servlet.Filter"
>>
>> .. as per the Troubleshooting section.
>>
>> I've commented out the 'servlet-api' dependency from my pom - as well 
>> as the 'jetty' stuff which is in there by default, however I the 
>> problem persists.
>>
>> I can see although I've run "maven install" and "maven clean" 
>> multiple times (and restarted eclipse etc) the "maven dependencies" 
>> still includes "servlet-api-2.5.jar", and "jetty-servlet-7.0.0...jar" 
>> - as well as other jetty jars and tomcat jars such as 
>> "servlet-api-6.0.30.jar" and "coyote-6.0.30.jar" (which I'm guessing 
>> were added when I tried out the maven tomcat plugin).
>>
>> I've also made sure all of these jars are unchecked within the 
>> devloader window, but the ClassCast problem persists...
>>
>> I have no idea why maven insists on including these jars when there 
>> is no remaining dependency.
>>
>> Any advice anyone?
>>
>> Thanks, Paul.
>>
>>
>>
>> On 23/12/2011 7:24 PM, Kalle Korhonen wrote:
>>> On Thu, Dec 22, 2011 at 11:51 PM, Paul Stanton<pa...@mapshed.com.au>  
>>> wrote:
>>>> For productivity, live class reloading, the ability to step through 
>>>> code and
>>>> being able to start and stop the container are all required.
>>>> We ended up compiling into "webapp/WEB-INF/classes" and copying all
>>>> dependencies into "webapp/WEB-INF/lib". This allowed us to achieve 
>>>> all of
>>>> the above, except for live class and template reloading.
>>> Without live class and template reloading, "all of the above" seems to
>>> leave you just debugging. You are missing most of it.
>>>
>>>> Are there any improvements in this space since Tapestry 5.1? Has 
>>>> anyone come
>>>> up with an easy to follow formula for configuring 
>>>> tapestry+tomcat+eclipse
>>>> for development?
>>> This page is up-to-date:
>>> http://tynamo.org/Developing+with+Tomcat+and+Eclipse. Many people have
>>> successfully followed the instructions on it to set their environment.
>>>
>>> Kalle
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>

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


Re: development with eclipse+tomcat

Posted by Paul Stanton <pa...@mapshed.com.au>.
I solved the problem ..

it seems my changes to the 'tomcat' settings for the project were not 
persisting or changing the ".tomcatplugin" file which was still 
referencing the old maven dependencies...

after simplifying the pom, deleting ".tomcatplugin" and re-applying the 
settings in the "tomcat" settings page, I have it all working!!

very nice, this will save me + team much time in the near future.

thanks for the advice and all the best in the new year.

cheers, Paul.

On 24/12/2011 8:23 AM, Paul Stanton wrote:
> Thanks Kalle,
>
> That document is great, much better than what I could find last time 
> around.
>
> The only step which I had to go searching elsewhere to solve was 
> finding where the "DevLoader" was!
>
> "7. Install devloader for Tomcat (for Tomcat 7.x use devloader from 
> version 3.3). Unzip and copy the org folder and its contents to 
> TOMCAT_HOME/lib"
>
> I figured out (google) that the devloader package is actually within 
> the Sysdeo plugin (as a zip) and that you need to:
> 1. extract Devloader.zip from the Sysdeo tomcat plugin archive
> 2. rename Devloader.zip to Devloader.jar
> 3. move Devloader.jar to tomcat/lib
>
> adding this to the document might save the next guy 15 minutes ;)
>
> Other than that, I think I am almost there, except I am getting then 
> exception when tomcat starts:
>
> ClassCastException "org.apache.tapestry5.TapestryFilter cannot be cast 
> to javax.servlet.Filter"
>
> .. as per the Troubleshooting section.
>
> I've commented out the 'servlet-api' dependency from my pom - as well 
> as the 'jetty' stuff which is in there by default, however I the 
> problem persists.
>
> I can see although I've run "maven install" and "maven clean" multiple 
> times (and restarted eclipse etc) the "maven dependencies" still 
> includes "servlet-api-2.5.jar", and "jetty-servlet-7.0.0...jar" - as 
> well as other jetty jars and tomcat jars such as 
> "servlet-api-6.0.30.jar" and "coyote-6.0.30.jar" (which I'm guessing 
> were added when I tried out the maven tomcat plugin).
>
> I've also made sure all of these jars are unchecked within the 
> devloader window, but the ClassCast problem persists...
>
> I have no idea why maven insists on including these jars when there is 
> no remaining dependency.
>
> Any advice anyone?
>
> Thanks, Paul.
>
>
>
> On 23/12/2011 7:24 PM, Kalle Korhonen wrote:
>> On Thu, Dec 22, 2011 at 11:51 PM, Paul Stanton<pa...@mapshed.com.au>  
>> wrote:
>>> For productivity, live class reloading, the ability to step through 
>>> code and
>>> being able to start and stop the container are all required.
>>> We ended up compiling into "webapp/WEB-INF/classes" and copying all
>>> dependencies into "webapp/WEB-INF/lib". This allowed us to achieve 
>>> all of
>>> the above, except for live class and template reloading.
>> Without live class and template reloading, "all of the above" seems to
>> leave you just debugging. You are missing most of it.
>>
>>> Are there any improvements in this space since Tapestry 5.1? Has 
>>> anyone come
>>> up with an easy to follow formula for configuring 
>>> tapestry+tomcat+eclipse
>>> for development?
>> This page is up-to-date:
>> http://tynamo.org/Developing+with+Tomcat+and+Eclipse. Many people have
>> successfully followed the instructions on it to set their environment.
>>
>> Kalle
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>

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


Re: development with eclipse+tomcat

Posted by Paul Stanton <pa...@mapshed.com.au>.
Thanks Kalle,

That document is great, much better than what I could find last time around.

The only step which I had to go searching elsewhere to solve was finding 
where the "DevLoader" was!

"7. Install devloader for Tomcat (for Tomcat 7.x use devloader from 
version 3.3). Unzip and copy the org folder and its contents to 
TOMCAT_HOME/lib"

I figured out (google) that the devloader package is actually within the 
Sysdeo plugin (as a zip) and that you need to:
1. extract Devloader.zip from the Sysdeo tomcat plugin archive
2. rename Devloader.zip to Devloader.jar
3. move Devloader.jar to tomcat/lib

adding this to the document might save the next guy 15 minutes ;)

Other than that, I think I am almost there, except I am getting then 
exception when tomcat starts:

ClassCastException "org.apache.tapestry5.TapestryFilter cannot be cast 
to javax.servlet.Filter"

.. as per the Troubleshooting section.

I've commented out the 'servlet-api' dependency from my pom - as well as 
the 'jetty' stuff which is in there by default, however I the problem 
persists.

I can see although I've run "maven install" and "maven clean" multiple 
times (and restarted eclipse etc) the "maven dependencies" still 
includes "servlet-api-2.5.jar", and "jetty-servlet-7.0.0...jar" - as 
well as other jetty jars and tomcat jars such as 
"servlet-api-6.0.30.jar" and "coyote-6.0.30.jar" (which I'm guessing 
were added when I tried out the maven tomcat plugin).

I've also made sure all of these jars are unchecked within the devloader 
window, but the ClassCast problem persists...

I have no idea why maven insists on including these jars when there is 
no remaining dependency.

Any advice anyone?

Thanks, Paul.



On 23/12/2011 7:24 PM, Kalle Korhonen wrote:
> On Thu, Dec 22, 2011 at 11:51 PM, Paul Stanton<pa...@mapshed.com.au>  wrote:
>> For productivity, live class reloading, the ability to step through code and
>> being able to start and stop the container are all required.
>> We ended up compiling into "webapp/WEB-INF/classes" and copying all
>> dependencies into "webapp/WEB-INF/lib". This allowed us to achieve all of
>> the above, except for live class and template reloading.
> Without live class and template reloading, "all of the above" seems to
> leave you just debugging. You are missing most of it.
>
>> Are there any improvements in this space since Tapestry 5.1? Has anyone come
>> up with an easy to follow formula for configuring tapestry+tomcat+eclipse
>> for development?
> This page is up-to-date:
> http://tynamo.org/Developing+with+Tomcat+and+Eclipse. Many people have
> successfully followed the instructions on it to set their environment.
>
> Kalle
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>

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


Re: development with eclipse+tomcat

Posted by Paul Stanton <pa...@mapshed.com.au>.
Kalle,

I've figured out that it was the tapestry-test etc adding jetty etc to 
my classpath.

After looking into it, I have a simple way to make sure your 'devLoader' 
classpath is correct:

Method 1 - compare to target/[project]/WEB-INF/lib after a maven install
1. run maven install
2. browse to '[project]/target/[context]/WEB-INF/lib'
3. compare listed jars to '[project]/.tomcatplugin'
- there should be no jars referenced which are not in the lib dir
4. if there are extra libs in '.tomcatplugin' open project 
"properties>tomcat>devloader classpath" and disable them

Method 2 - exclusion, configuration then revert
1. open your pom.xml and comment out every dependency of a non-default 
scope (ie, servlet-api, tapestry-test, testng, tapestry-javadoc etc)
2. open project "properties>tomcat>devloader classpath"
3. click 'check all' then uncheck 'target/test-classes', all JRE 
libraries and maven classpath container, hit 'ok'.
4. undo your changes to the pom (step 1).

After following either of these methods, only the required libraries 
will be loaded via tomcat devloader.

I still have one outstanding issue with this configuration regarding 
classloaders...

         ComponentResources cr = container.getComponentResources();
         Component comp = cr.getEmbeddedComponent(zoneClientId);
         log.debug(Zone.class.getName() + " == " + 
comp.getClass().getName());
         log.debug(Zone.class.getClassLoader() + " == " + 
comp.getClass().getClassLoader());
         Zone zone = (Zone) comp; // <-- ClassCastException

Output:

DEBUG org.apache.tapestry5.corelib.components.Zone == 
org.apache.tapestry5.corelib.components.Zone
DEBUG WebappClassLoader
   context: /myapp
   delegate: false
   repositories:
----------> Parent Classloader:
org.apache.catalina.loader.StandardClassLoader@63b660
  == org.apache.tapestry5.internal.plastic.PlasticClassLoader@6d1fa2
...
Caused by: java.lang.ClassCastException: 
org.apache.tapestry5.corelib.components.Zone cannot be cast to 
org.apache.tapestry5.corelib.components.Zone

So the object returned from ComponentResources.getEmbeddedComponent is 
from the tapestry classloader, while the Zone class is from the default 
classloader.

Is there a way to resolve this?

Thanks, p.

On 23/12/2011 7:24 PM, Kalle Korhonen wrote:
> On Thu, Dec 22, 2011 at 11:51 PM, Paul Stanton<pa...@mapshed.com.au>  wrote:
>> For productivity, live class reloading, the ability to step through code and
>> being able to start and stop the container are all required.
>> We ended up compiling into "webapp/WEB-INF/classes" and copying all
>> dependencies into "webapp/WEB-INF/lib". This allowed us to achieve all of
>> the above, except for live class and template reloading.
> Without live class and template reloading, "all of the above" seems to
> leave you just debugging. You are missing most of it.
>
>> Are there any improvements in this space since Tapestry 5.1? Has anyone come
>> up with an easy to follow formula for configuring tapestry+tomcat+eclipse
>> for development?
> This page is up-to-date:
> http://tynamo.org/Developing+with+Tomcat+and+Eclipse. Many people have
> successfully followed the instructions on it to set their environment.
>
> Kalle
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>

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


Re: development with eclipse+tomcat

Posted by Kalle Korhonen <ka...@gmail.com>.
On Thu, Dec 22, 2011 at 11:51 PM, Paul Stanton <pa...@mapshed.com.au> wrote:
> For productivity, live class reloading, the ability to step through code and
> being able to start and stop the container are all required.
> We ended up compiling into "webapp/WEB-INF/classes" and copying all
> dependencies into "webapp/WEB-INF/lib". This allowed us to achieve all of
> the above, except for live class and template reloading.

Without live class and template reloading, "all of the above" seems to
leave you just debugging. You are missing most of it.

> Are there any improvements in this space since Tapestry 5.1? Has anyone come
> up with an easy to follow formula for configuring tapestry+tomcat+eclipse
> for development?

This page is up-to-date:
http://tynamo.org/Developing+with+Tomcat+and+Eclipse. Many people have
successfully followed the instructions on it to set their environment.

Kalle

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


Re: development with eclipse+tomcat

Posted by Nourredine <no...@atos.net>.
Hi Paul,

The live class reloading issue in tomcat has been fixed since tapestry 5.3.
See https://issues.apache.org/jira/browse/TAP5-1336.
For previous releases, you can create your own patch based on this one :
https://issues.apache.org/jira/secure/attachment/12458804/patch_tomcat_reload.txt.
It works like a charm for me.

By the way, I personally use a great maven plugin that allows you to launch
tomcat from maven : https://github.com/t7mp/t7mp/wiki
No longer need to install tomcat in advance, change the tomcat's version
easily, run multiple webapps, ...

Combined with live class reloading, it is a big convenience for
tapestry+openejb+tomcat+eclipse projects !

Nourredine.

--
View this message in context: http://tapestry.1045711.n5.nabble.com/development-with-eclipse-tomcat-tp5096541p5096781.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

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


Re: development with eclipse+tomcat

Posted by Christian Köberl <ta...@gmail.com>.
2011-12-23 08:51, Paul Stanton:
> Its been over 2 years since I started a new production tapestry
> application, and once again in the same server environment we need to do
> our development & testing in the environment familiar with the team: ie
> tomcat.
> 
> For productivity, live class reloading, the ability to step through code
> and being able to start and stop the container are all required.
> 
> Last time around (T5.1) I tried and failed to arrive at a project setup
> which allowed all of the above with tomcat. I tried to get the
> Sysdeotomcat launcher plugin to work without success, among other
> approaches I have since forgotten.
> 
> We ended up compiling into "webapp/WEB-INF/classes" and copying all
> dependencies into "webapp/WEB-INF/lib". This allowed us to achieve all
> of the above, except for live class and template reloading.
> 
> Are there any improvements in this space since Tapestry 5.1? Has anyone
> come up with an easy to follow formula for configuring
> tapestry+tomcat+eclipse for development?
> Thanks, Paul.

Some of us use Tomcat with Sysdeo and DevLoader (adding the needed
library dependencies) without any problem.

-- 
Chris

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