You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2006/03/21 21:24:40 UTC

DO NOT REPLY [Bug 39053] New: - include Tomcat embedded sample

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39053>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39053

           Summary: include Tomcat embedded sample
           Product: Tomcat 5
           Version: Unknown
          Platform: Other
        OS/Version: other
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Catalina
        AssignedTo: tomcat-dev@jakarta.apache.org
        ReportedBy: juergen@jwi.de


An sample Java program to show how to run Tomcat embedded should be included in
the distribution. It should include a java main program that should not need any
disc based config files. Also there should be included a build.xml to show what
libraries are are needed at compile and run time.

A starting point could be these posts:

http://www.theserverside.com/discussions/thread.tss?thread_id=30625
http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg144216.html

(the sample from theserverside.com fails with
java.lang.NoClassDefFoundError: javax/management/MBeanRegistration)

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 39053] - include Tomcat embedded sample

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39053>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39053


yoavs@computer.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO




------- Additional Comments From yoavs@computer.org  2006-12-24 18:57 -------
Thank you for submitting a sample application.  I don't want to include it in
the distribution until you enhance it to your satisfaction, as you say yourself
it needs to be "much enhanced" before serving as a sample.  Please feel free to
attach an updated sample if/when you feel like it, and I'll be glad to take
another look at it then, and maybe include it in the distro.  (I do agree an
embedded sample would be cool).

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 39053] - include Tomcat embedded sample

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39053>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39053





------- Additional Comments From juergen@jwi.de  2006-04-14 16:06 -------
Created an attachment (id=18100)
 --> (http://issues.apache.org/bugzilla/attachment.cgi?id=18100&action=view)
TomcatServer.java

This is the code I use for starting Tomcat embedded. The code should be very
much enhanced to serve as a sample.

It uses a JNDIRealm.

The webapps are loaded from wars from the default Tomcat ones. The manager app
seems to work, but the ROOT context yields "The requested resource (/) is not
available."

BTW: How does my application know when Tomcat is up and running? This does not
trigger a LifecycleEvent.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 39053] - include Tomcat embedded sample

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39053>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39053





------- Additional Comments From juergen@jwi.de  2006-12-26 13:13 -------
(In reply to comment #4)

I don't feel I am apt to enhance the sample. If I knew so much about Tomcat's 
intricacies I wouldn't have opened the bug in the first place. The sample is
what I could gather from some articles, but it is only rudimentary and should be
over-worked by someone who knows Tomcat very well.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 39053] - include Tomcat embedded sample

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39053>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39053





------- Additional Comments From yoavs@computer.org  2006-04-13 19:33 -------
If you have a sample, submit it, and we will gladly review and add it as relevant.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 39053] - include Tomcat embedded sample

Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39053>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39053





------- Additional Comments From shankarunni@netscape.net  2006-03-22 00:29 -------
I started with that sample (theserverside). One thing I found tricky to emulate
is the behavior of the actual Catalina startup class, where it starts the
connector in a suspended state, and then activates it after all the webapps are
deployed.

This prevents the server from replying back with a 500 code to an overly eager
client who comes in "too early" - today, if they can connect, they'll block till
all webapps are deployed, and then get a proper response.

In my own embedded startup, I had to emulate this by creating the connector (as
described in the article), and then immediately invoking the "pause()" API on
the connector, deploying the webapps, and then invoking the "resume()" API on it.


-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org