Re: Split web.xml into multiple files

2004-05-03 Thread Craig McClanahan
Prasad, Kamakshya wrote:

Hi, 

I tried xml entity. It worked though I have few doubts.

This is part of the xml which have that reference



2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd";
	 [
"file:///F:/struts/web/WEB-INF/servlet.xml" >]>

 Struts POC

 
 &xmlfrag;
 

I presume that "" goes here?

The "&xmlfrag" contains the servlet specification and everything is
working fine but when I start the server it always throw this error.

What has to be done to get rid of this error?

 

Even if this worked, you really don't want to be using absolute paths.  
A more typical scenario would be to put your fragment (say, in a file 
called "action-servlet.xml") in the WEB-INF directory next to web.xml, 
and change the entity declaration to something like:

 

This will work *if* your container parses web.xml files in a manner 
where the XML parser knows the absolute URL of the web.xml file itself, 
so that it can resolve relative references.  Tomcat works this way, but 
I don't know if WebLogic does.

Thanks and Regards,
KP
 

Craig

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Split web.xml into multiple files

2004-05-03 Thread Prasad, Kamakshya
Hi, 

I tried xml entity. It worked though I have few doubts.

This is part of the xml which have that reference


http://java.sun.com/dtd/web-app_2_3.dtd";
 []>

  Struts POC

  
  &xmlfrag;


The "&xmlfrag" contains the servlet specification and everything is
working fine but when I start the server it always throw this error.



What has to be done to get rid of this error?

Thanks and Regards,
KP


-Original Message-
From: Craig McClanahan [mailto:[EMAIL PROTECTED] 
Sent: Monday, May 03, 2004 3:57 PM
To: Struts Users Mailing List
Subject: Re: Split web.xml into multiple files

Prasad, Kamakshya wrote:

>Hi,
>
>We are using the container managed security and we have lot of action
>mapping and roles. Specifying them in one web.xml making it too huge.
We
>want it to split into separate logical files
>
>  
>
If your container is reasonably intelligent about parsing XML documents 
using entities that refer to files in the same directory, this should be

no problem using XML entities for this sort of thing.  Check the Struts 
documentation, Wiki, and mailing list archives for discussions of 
dividing up a struts-config.xml file -- exactly the same techniques will

generally work for web.xml as well.

On the other hand, it makes a *lot* more sense to me to create a build 
environment that dynamically combines all the stuff you need into a 
single web.xml file, to be included in the deployable WAR file, as part 
of the build process.

>KP
>
>  
>
Craig


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Split web.xml into multiple files

2004-05-02 Thread Craig McClanahan
Prasad, Kamakshya wrote:

Hi,

We are using the container managed security and we have lot of action
mapping and roles. Specifying them in one web.xml making it too huge. We
want it to split into separate logical files
 

If your container is reasonably intelligent about parsing XML documents 
using entities that refer to files in the same directory, this should be 
no problem using XML entities for this sort of thing.  Check the Struts 
documentation, Wiki, and mailing list archives for discussions of 
dividing up a struts-config.xml file -- exactly the same techniques will 
generally work for web.xml as well.

On the other hand, it makes a *lot* more sense to me to create a build 
environment that dynamically combines all the stuff you need into a 
single web.xml file, to be included in the deployable WAR file, as part 
of the build process.

KP

 

Craig

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Split web.xml into multiple files

2004-05-02 Thread Prasad, Kamakshya
Hi,

We are using the container managed security and we have lot of action
mapping and roles. Specifying them in one web.xml making it too huge. We
want it to split into separate logical files

KP

-Original Message-
From: Bill Siggelkow [mailto:[EMAIL PROTECTED] 
Sent: Friday, April 30, 2004 10:20 PM
To: [EMAIL PROTECTED]
Subject: Re: Split web.xml into multiple files

Prasad, Kamakshya wrote:

> Hi,
>  
> Is it possible to split web.xml into multiple files?
>  
> KP
> 
AFAIK the web.xml cannot be split.  Most containers, however, do utilize

a container-specific web app deployment descriptor that works with the 
web.xml.  The web.xml for a Struts-based application should be 
relatively small and should not need to be frequently modified.  Why do 
you want/need to split the web.xml?


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]