RE: Struts tags and Filter Dispatcher Url Pattern-struts 2.1.1

2008-01-31 Thread Sanjeev Vijapurapu
That's what I thought but why does tags need stack when I am not
accessing any of the values. It just has sx:head. 
So my question is am I right in saying that struts should be able to
render struts tags as it does jstl tags without worrying abt any stack.
If stack is null, it should treat it as an empty stack rather than
throwing null pointer.

Thanks

 
-Original Message-
From: Dave Newton [mailto:[EMAIL PROTECTED] 
Sent: Thursday, January 31, 2008 1:33 PM
To: Struts Users Mailing List
Subject: Re: Struts tags and Filter Dispatcher Url Pattern-struts 2.1.1

--- Sanjeev Vijapurapu <[EMAIL PROTECTED]> wrote:
> So does this mean that if my jsp is using struts tags, it has to go
> through filter dispatcher?

The filter is what puts the stack into scope so the tags have data to
access
(more or less).

Dave


-
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]



Struts tags and Filter Dispatcher Url Pattern-struts 2.1.1

2008-01-31 Thread Sanjeev Vijapurapu
Hi,

I have recently upgraded to struts 2.1.1 and if my struts filter
dispatcher url pattern is not "/*" instead it is "/actions/*,
/struts/*".

And now if I am trying to access a jsp page that is not under that url
pattern ( something like /test.jsp), struts tags in that jsp page fail.

I get the following stack trace

 

java.lang.NullPointerException
at
org.apache.struts2.views.jsp.TagUtils.getStack(TagUtils.java:55)
at
org.apache.struts2.views.jsp.StrutsBodyTagSupport.getStack(StrutsBodyTag
Support.java:46)
at
org.apache.struts2.views.jsp.ComponentTagSupport.doStartTag(ComponentTag
Support.java:47)
at
org.apache.jsp.test_jsp._jspx_meth_sx_head_0(org.apache.jsp.test_jsp:95)
at
org.apache.jsp.test_jsp._jspService(org.apache.jsp.test_jsp:65)
at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:93)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja
va:373)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:470)
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:364)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
 
So does this mean that if my jsp is using struts tags, it has to go
through filter dispatcher?
 
Thanks

 



RE: Struts 2.1.1 and Tiles

2008-01-29 Thread Sanjeev Vijapurapu
It's actually because of the standard taglib. I am using core taglib for
some use case and if I remove that code it works fine. But what I am not
able to understand is that why does struts2.0.9 works fine with it where
as struts 2.1.1 doesnt

-Original Message-
From: Sanjeev Vijapurapu [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 29, 2008 2:48 PM
To: user@struts.apache.org
Subject: Struts 2.1.1 and Tiles

Hi,

Has anybody tried using tiles2 with struts 2.1.1? I had a working app
with tiles2 and struts 2.0.9; but when I upgraded to 2.1.1 it just
stopped working.

Stack Trace is:

javax.servlet.jsp.JspException: Error executing tag: JSPException while
including path '/layouts/layout-template.jsp'. ServletException while
including page.

at
org.apache.tiles.jsp.taglib.RoleSecurityTagSupport.doEndTag(RoleSecurity
TagSupport.java:80)

at
org.apache.tiles.jsp.taglib.ContainerTagSupport.doEndTag(ContainerTagSup
port.java:80)

at
org.apache.jsp.security.login_jsp._jspx_meth_tiles_insertDefinition_0(or
g.apache.jsp.security.login_jsp:87)

at
org.apache.jsp.security.login_jsp._jspService(org.apache.jsp.security.lo
gin_jsp:57)

at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:93)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper

.java:373)

at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:4

70)

at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:364)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

at
org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487

)

at
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet

Handler.java:1093)

 

Any pointers on how to resolve this?

 

Thanks


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



Struts 2.1.1 and Tiles

2008-01-29 Thread Sanjeev Vijapurapu
Hi,

Has anybody tried using tiles2 with struts 2.1.1? I had a working app
with tiles2 and struts 2.0.9; but when I upgraded to 2.1.1 it just
stopped working.

Stack Trace is:

javax.servlet.jsp.JspException: Error executing tag: JSPException while
including path '/layouts/layout-template.jsp'. ServletException while
including page.

at
org.apache.tiles.jsp.taglib.RoleSecurityTagSupport.doEndTag(RoleSecurity
TagSupport.java:80)

at
org.apache.tiles.jsp.taglib.ContainerTagSupport.doEndTag(ContainerTagSup
port.java:80)

at
org.apache.jsp.security.login_jsp._jspx_meth_tiles_insertDefinition_0(or
g.apache.jsp.security.login_jsp:87)

at
org.apache.jsp.security.login_jsp._jspService(org.apache.jsp.security.lo
gin_jsp:57)

at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:93)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper

.java:373)

at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:4

70)

at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:364)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

at
org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487

)

at
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet

Handler.java:1093)

 

Any pointers on how to resolve this?

 

Thanks



Struts2 and CMS

2008-01-28 Thread Sanjeev Vijapurapu
Is there any content management support in struts2; like special tags or
interceptors which reads the CMS markers from the result and fetches it
before processing the result? 

 

Thanks

-Sanjeev



FW: Struts 2.1.1-SNAPSHOT upgrade

2008-01-28 Thread Sanjeev Vijapurapu
I have upgraded from Struts 2.0.7 to 2.1.1-SNAPSHOT and my current
working app doesn't work any more. Thru el mapping for my struts filters
are "/*".

1.  The welcome page is not being picked up from welcome file list
as  struts was acting on it and trying to find an action named "."  in
namespace "/".Why doesn't it forward the request so that it can be
fulfilled by welcome file list. Is this a bug or was it changed to do
that?
2.  My tiles app is broken. It suddenly cannot run the jsp anymore.
It throws some RoleSecurity tag issue. I have checked that I don't have
any duplicate jstl or standard jars. I have cleared my work folder and
tried running it, still it doesn't work. It's the same case even with
2.0.11. Was anything changed in the tiles plugin? It doesn't seem to be
struts issue because its jsp failure but it only happens when I upgrade
struts.

 

Thanks

 

 

 

 



RE: Struts2 JSF Plugin

2008-01-11 Thread Sanjeev Vijapurapu
So you mean we should push all JSF actions onto OGNL stack?
Shouldn't the jsf interceptor stack do it for us?
I mean if you are using plain jsf, whatever backing beans you configure
in faces-config, can be invoked from any jsf component from anywhere and
not just the action which renders it which is the case with struts-jsf
plugin.

So what I am suggesting is :
1) if you have action config like :




>From a jsf component you should be able to invoke it as


Thanks

-Original Message-
From: Martin Gainty [mailto:[EMAIL PROTECTED] 
Sent: Thursday, January 10, 2008 12:47 PM
To: Sanjeev Vijapurapu
Subject: Re: Struts2 JSF Plugin

provisionally yes (for a static invocation)
@[EMAIL PROTECTED]()

for non-static would have to know if you pushed the object onto OGNL
stack
via request/session/application or root e.g.
assuming action is the ONLY single root object you can access
doSomething()
method via this mechanism
#action.doSomething()

Martin--
- Original Message -
From: "Sanjeev Vijapurapu" <[EMAIL PROTECTED]>
To: 
Sent: Thursday, January 10, 2008 2:49 PM
Subject: Struts2 JSF Plugin


I was trying to create a prototype of struts2 + jsf. In the process I
found that the mappings have to be used with "action" as default.

Like



or





instead of using action names from struts configuration directly. For
example if I have configured an action as login in struts config, I
should able to use it in jsf component like





But interestingly thats not the case. I thought that in Struts2
framework all the actions with interceptor stack as jsf would act
similar to managed beans in a JSF framework. I mean use them by the
names configured in faces-config.xml.



But if I want to do that in struts2, I need faces-config.xml and normal
struts2 actions which is disappointing. I mean what about the scenario
where I have to send a jsf request to different action than the one
which last rendered it?  So my main question is how can I use action
names in the jsf component?



Am I missing something here or is that the way it was designed?





Thanks



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



Struts2 JSF Plugin

2008-01-10 Thread Sanjeev Vijapurapu
I was trying to create a prototype of struts2 + jsf. In the process I
found that the mappings have to be used with "action" as default.

Like 



or



 

instead of using action names from struts configuration directly. For
example if I have configured an action as login in struts config, I
should able to use it in jsf component like



 

But interestingly thats not the case. I thought that in Struts2
framework all the actions with interceptor stack as jsf would act
similar to managed beans in a JSF framework. I mean use them by the
names configured in faces-config.xml. 

 

But if I want to do that in struts2, I need faces-config.xml and normal
struts2 actions which is disappointing. I mean what about the scenario
where I have to send a jsf request to different action than the one
which last rendered it?  So my main question is how can I use action
names in the jsf component?

 

Am I missing something here or is that the way it was designed?

 

 

Thanks