tomcat

Change Tomcat port on-the-fly

I'd like to store the Tomcat v5.5 port in an environment variable and have Tomcat listen on that port. So far the only way I can see to change the port is by amending $CATALINA_HOME/conf/server.xml. Is there a way to set the port value by supplying an external value when starting Tomcat? I'm running Tomcat on Solaris. ...

Tomcat 6 file upload strategy

Hi Gurus, I have been using tomcat for sometime and still can't find a good way to do file upload. Just wonder how you guys handle file upload. You know how you can create a symlink in the application to another fs. but then by default tomcat removes your symlink and everything within the symlink. so this add extra steps to auto deploy...

Java bean with JNI ?

I have added native method in java bean code. Then i have copied .dll file in System32 folder. while using javabean in JSP. it gives an Error: HTTP Status 500 - type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperE...

Trying to use tomcat with eclipse.

Hey, I am trying to use tomcat with eclipse. I have installed it all and got the tomcat plugin installed. I have put a .war file in the webapps folder of tomcat and have made sure autodeploy is set to true. The problem I am having is that I can't get tomcat to run this .war file. The tomcat server is started and running as it tells me u...

Auth (digest) request from Servlet

Hi guys, I'm creating a small servlet. It's hosted at root, "/", and whatever comes after "/" is a resource, like "/myanim.swf". Most of the files are public, but some are private. For public files, they are just served, but for private files, I wish the browser to present an authentication box and have a Digest authentication sent back ...

Tomcat Clustering and HTTPS Issue

Hi I have two instances of Tomcat 6 with content accessible via HTTP and HTTPS for other pages. I have configured the instances this way: 1) Instance one to listen on port 8080(Http) and 8443(Https) 2) Instance two to listen on port 7080(Http) and 7443(Https) I have mod_proxy configured with Apache 2.2 to do clustering. The re...

Java EE Jar file sharing

At our shop, we are maintaining roughly 20 Java EE web applications. Most of these applications are fairly CRUD-like in their architecture, with a few of them being pretty processor intensive calculation applications. For the deployment of these applications we have been using Hudson set up to monitor our CVS repository. When we have a ...

Unable to Connect to Tomcat Using VisualVM

I am having problems monitoring a remote Tomcat process. I'm trying to use the Java 6 versions of JConsole/JVisualVM. I have jstatd running on the remote server with the appropriate security policy. The process is started and the TCP connections are available. When I try to connect through JConsole, I get 'Connection Failed:jmxrmi'...

Having hard time to publish files to Tomcat from Eclipse

Hello good fellas! Sorry if my question seems dumb. I've started using Eclipse Ganymede 3.4 this week and having hard time publishing my projects to the web app server. First of all you need to know this issue: i installed my Tomcat 6.0.18 from Netbeans that i use for PHP and J2SE project. While i can start that server from either Netb...

Which kind of Tomcat 6 to install

Each of the Tomcat 6 distros (binary core, binary deployer and source) is available as a zip file and a tarball. But binary core also has a Windows Service Installer option. What's the difference between that and the zip file? All I've been able to figure out so far is that the service provides a tray icon and doesn't provide startup/...

When to use Servlet versus JSP Pages in Tomcat?

We have been debating between using servlets or JSP pages and we want to know what the common uses of one versus the other. If you read any online guide that you can point us out, will be very grateful. ...

Tomcat stack overflow error

I have tomcat located here: /work/tomcat So, /work/tomcat/conf is where configuration is located The default webapps are in /work/tomcat/webapps I have created a folder /work/tomcat/foocom I have a virtual host set up to the domain foo.com with an appBase="foocom" I start my server and visit foo.com in the browser and see the index fi...

Eclipse 3.x unable to debug tomcat 5.5 with java 1.6.0_14?

Hi all! I'm trying to launch and debug tomcat 5.5 with a webapp in java 6. I have set up JAVA_HOME in the tomcat's eclipse configuration (in "replace environment" mode) but I get the following error: ERROR: transport error 202: gethostbyname: unknown host ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510) JD...

CSR Generation: Tomcat or Apache?

While not entirely programming related. I recently purchased a SSL certificate, and during the configuration I need to generate as CSR. I am running Tomcat behind Apache via mod_jk. I see two options for generating the CSR one for Apache and one for Java based servers. My question is which do i use? At the moment the site needing th...

Which linux server distro to use for tomcat?

ubuntu 9.04, fedora 11, redhat... what are the differences from a web server/development standpoint? ...

Problem retrieving properties file from webapp in tomcat

Hi, I've developed a web application that worked fine in JBoss 4. Now, I need to make it work in Tomcat 6, but I'm having trouble to access some properties file. I use the following code to read read these files: InputStream is = Thread.currentThread().getContextClassLoader() .getResourceAsStream(fileName); if (is == null) { ...

gwt Comet easier to implement on jetty or tomcat?

gwt Comet easier to implement on jetty or tomcat? ...

Restarting Log4J logging via JMX

It seems a Log4j rolling appender stopped logging because it hit the MaxBackupIndex limit. I've moved the old log files out of the way but Log4j doesn't seem to start logging again. Is there a way to restart Log4J logging via JMX? I'd like to leverage this insteaed of restarting a Tomcat instance. Thanks. ...

Can I implement a socket server on Tomcat using GenericServlet?

I would like to implement a socket server that will be connected to by multiple clients. In order to make the implementation as simple as possible and not have to code management of threads and connections etc I'd like to use Tomcat. We already use tomcat as part of our solution. I am sure that Tomcat can be used for non http servlets a...

automativ thread starting in tomcat

i want a thread to start automaticalyy when my application on tmocat is started. How do i do that.Do i have to add something to web.xml?? ...