Thanks for your reply.

Do you know what method really applies the mapping?
And, is it possible to make my  own implementation of the mapping
digester(?)?"

Regards, 

Auke

-----Oorspronkelijk bericht-----
Van: news [mailto:[EMAIL PROTECTED] Namens Bill Barker
Verzonden: dinsdag 23 oktober 2007 3:27
Aan: users@tomcat.apache.org
Onderwerp: Re: Start tomcat without Connector

It is possible, but not easy.  The Connector is integrated pretty tightly 
with the Catalina code now.  In particular, you can't just call the invoke 
method on the Context, since the mappings are done via the Connector.

It will probably be easier to create a Connector using the 
MemoryProtocolHandler (in org.apache.coyote.memory).  You're code can get a 
reference to it by calling getProtocolHandler() on the Connector, and then 
feed your request through the process method of MemoryProtocolHandler.

"Auke Noppe" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]
Hi there,



Is it possible to start an instance of (embedded)tomcat without connector,
and to invoke pages through the context.invoke(request, response) method?

I have written a small application which starts embedded tomcat with a
server, engine, host and context, but without connector.

And the application invokes the invoke method of the context. But I don’t
get a response back.



public void startTomcat() throws LifecycleException {

        embedded = new Embedded();



        engine = embedded.createEngine();

        engine.setName("Catalina");



        host = embedded.createHost("localhost", getPath() + "/webapps");

        engine.addChild(host);



        context = embedded.createContext("",
"C:/stage_auke/workspace/trunk/web");

        context.setPrivileged(false);

        host.addChild(context);

        String config = host.getConfigClass();


((StandardContext)context).setDefaultWebXml(getPath()+"/conf/web.xml");



        context.setAvailable(true);

        embedded.addEngine(engine);

        embedded.start();

    }



The other method calls context.invoke with a filled request and response.







Anyone an idea?



Regards,



Auke




No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.5.488 / Virus Database: 269.15.5/1084 - Release Date: 21-10-2007
15:09





---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

No virus found in this incoming message.
Checked by AVG Free Edition. 
Version: 7.5.503 / Virus Database: 269.15.6/1086 - Release Date: 22-10-2007
19:57
 

No virus found in this outgoing message.
Checked by AVG Free Edition. 
Version: 7.5.503 / Virus Database: 269.15.6/1086 - Release Date: 22-10-2007
19:57
 


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to