Sysdeo plugin: how to control which directories to pack up as .war file? [message #210522] |
Tue, 18 March 2008 14:50 |
Michael Moser Messages: 914 Registered: July 2009 |
Senior Member |
|
|
Maybe that's the wrong NG, if there is a better suited, please advise!
I am trying to configure my eclipse such that I can conveniently
(re)start Tomcat from within eclipse (to ease and speed up the
turn-around time after a change).
My tomcat installation is preconfigured (i.e. I got it as is and don't
want to change any settings, just adding another servlet to it). it
works fine, when started manually (or via a script)l
When I try to configure WTP (Servers view) to start that Tomcat it
always fails with the message:
---------------------
Publishing failed
Could not load the Tomcat server configuration at \Servers\Test
(Apache Tomcat v5.5) at localhost-config. The configuration may be
corrupt or incomplete.
Could not load the Tomcat server configuration at \Servers\Test
(Apache Tomcat v5.5) at localhost-config. The configuration may be
corrupt or incomplete.
---------------------
Apparently that is, because it expects to find a file "catalina.policy"
in the <tomcat>/conf directory. However, that preconfigured Tomcat I am
using has no such file.
I thus installed the Sysdeo plugin. With that I can nicely start and
stop that Tomcat setup, however, apparently this plugin does not
dynamically add the projects WebContent and the build/classes file to
the Tomcat's classpath. Instead one has to repeatedly "Export the .war
file ...". Not quite a convenient as I would like, but better than
nothing. The export as such works, however, the war contains not only
the mentioned subdirectories but simply the ENTIRE eclipse project. This
is not only too much, but also wrongly arranged, i.e. there is one
directory level too much in that .war file and hence Tomcat then doesn't
find the config files in the expected locations and so this doesn't work
either.
If I select the project and Export ... => Web => WAR file, then the .war
file is correctly created and things work as expected, but I find that a
bit tedious. I would like to (at least semi-)automate that publishing
step. How can one teach Sysdeo to pack only the proper directories into
the .war file?
Hope, I could make myself clear...
Michael
|
|
|
|
|
|
Re: Sysdeo plugin: how to control which directories to pack up as .war file? [message #210854 is a reply to message #210846] |
Tue, 25 March 2008 12:07 |
Larry Isaacs Messages: 1354 Registered: July 2009 |
Senior Member |
|
|
Michael Moser wrote:
> Werner Keil wrote:
>> > ...
>> I am not sure, why you would need both Sysdeo Tomcat Launcher and WTP
>> in the same situation? While it was around much earlier than WTP its
>> features have pretty much taken its place nowadays.
>
> As I mentioned: I am using the Sysdeo plugin, because the WTP pluging
> claims "illegal or corrupted configuration" when I try to use it to
> start up Tomcat, while the Sysdeo plugin starts up Tomcat just fine (and
> it works as expected, so its config can't be THAT wrong...).
>
> Michael
The WTP Tomcat support includes enabling security, which would involve
the use of the catalina.policy file. Since a catalina.policy file is a
standard part of all Apache Tomcat distributions, the Tomcat support
expects to find one, both when importing the file during server creation
and when the server is published. At this point, you should be able to
create an empty one, or one with just a comment, along side of the
server.xml in the Servers project in your workspace, and that publishing
failure should go away. You would need to come up with a real
catalina.policy if you ever decide to enable security.
Cheers,
Larry
|
|
|
Powered by
FUDForum. Page generated in 0.02289 seconds