Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

STRUTS + WEBLOGIC 8.1

 
Rajan Janakra
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
I deployed struts 2.0 based application in weblogic 8.1 .Deployment is sucessfull and throws the index page but not able to recognize .do extension. The same war file I was able to run under tomcat and netbeans 4.0. Could someone throw some light on this.
Thanks in advance.
My Web.xml Action Servlet Configuration and Filter Configuration.
<<
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/WEB-INF/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>


<!-- Standard Action Servlet Mapping -->
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>

<filter>
<filter-name>ResponseOverrideFilter</filter-name>
<filter-class>org.displaytag.filter.ResponseOverrideFilter</filter-class>
</filter>

<filter-mapping>
<filter-name>ResponseOverrideFilter</filter-name>
<url-pattern>*.do</url-pattern>
</filter-mapping>


>>
Sincerely,
Rajan.
 
Rajan Janakra
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Guys,
I wonder If someone has done struts 2.0 based application deployment in weblogic 8.1. Any good links would be helpfull.
Rajan
 
Satish SN
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi Rajan,

<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>

i think the hitch is in url-pattern becoz weblogic tend to believe in web-root-context thtat is u need to modify the

<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>/*.do</url-pattern>
</servlet-mapping>


this should solve ur problem..........

Keep Trying .....
 
Tim West
Ranch Hand
Posts: 539
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My WLAS8.1/Struts1.2.4 app has the servlet mapping configured thus, which works fine:



Have you got a (possibly trivial) weblogic.xml in the appropriate part of the war? Also, why do you have load-on-startup as '2'? This is a boolean, so it should be 1 or 0. I've found Weblogic to be very fussy with things like this.

If you can't get it working, post the exception you're getting and perhaps we can help more.

My app has no filters configured though - perhaps you could try getting it going without the filter, to see if that's the problem.


-Tim
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic