You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Dave Newton <ne...@yahoo.com> on 2007/02/02 15:03:34 UTC

[s2] 2.0.4, problem with SlashesInActionNames?

My 2.0.4 config is identical(ish) to my 2.0.3 configs,
I have struts.enable.SlashesInActionNames in both
struts.properties and struts.xml (and in a re-jarred
core, just in case) and I still get the 'no action in
namespace' msg for my actions... um... with slashes.

Non-slashed action names work as expected, my actions
are all in a default pakg extends struts-default and
I've manually set the namespace on the package to "",
also just in case.

BTW, it'd be cool if the properties started with
consistent case or used equalsIgnoreCase :/ Or if
there's a method to the madness, write it down :)

d.



 
____________________________________________________________________________________
Have a burning question?  
Go to www.Answers.yahoo.com and get answers from real people who know.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [s2] 2.0.4, problem with SlashesInActionNames?

Posted by Dave Newton <ne...@yahoo.com>.
--- Don Brown <do...@gmail.com> wrote:
> This doesn't seem right... see if you can't write a
> unit test that replicates this problem and open up a

> ticket on jira.

It wasn't immediately clear to me how to deal with all
the namespace stuff in the test (I don't know if the
namespace is in the pageContext etc.); I probably
won't look at this again until tomorrow. Sorry!

I didn't see any namespace testing in the existing
tests so I didn't have enough to copy off of ;)

Dave




 
____________________________________________________________________________________
Need Mail bonding?
Go to the Yahoo! Mail Q&A for great tips from Yahoo! Answers users.
http://answers.yahoo.com/dir/?link=list&sid=396546091

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [s2] 2.0.4, problem with SlashesInActionNames?

Posted by Don Brown <do...@gmail.com>.
On 2/2/07, Dave Newton <ne...@yahoo.com> wrote:
> One thing that just popped up is:
>
> - I use tiles.
> - I *had* a navigation link <s:url
> action="foo/bar".../>
> - I *now* have a navigation link <s:url
> namespace="foo" action="bar".../>
> - Link renders as "/foo/foo/bar.action" if I'm on
> "/foo/bar.action" page, which I thought was weird,
> since if I'm in the namespace already... but I may
> have outfoxed myself configuration-wise and be in a
> weird state.

This doesn't seem right... see if you can't write a unit test that
replicates this problem and open up a ticket on jira.

Don

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [s2] 2.0.4, problem with SlashesInActionNames?

Posted by Dave Newton <ne...@yahoo.com>.
--- Don Brown <do...@gmail.com> wrote:
> Hmm..they very well could be exclusive.  I put the
> slashes in name thing in there to support folks that

> used XML configuration, but wanted to do more 
> wildcard-type things with it. 

...I also plan on using the new REST-ful mapper, so I
think I might be out of luck? 

> Say more about what you don't like about how
> namespaces are handled.

One thing that just popped up is:

- I use tiles.
- I *had* a navigation link <s:url
action="foo/bar".../>
- I *now* have a navigation link <s:url
namespace="foo" action="bar".../>
- Link renders as "/foo/foo/bar.action" if I'm on
"/foo/bar.action" page, which I thought was weird,
since if I'm in the namespace already... but I may
have outfoxed myself configuration-wise and be in a
weird state.

So...

- I can't just say <s:url action="bar".../>; it's a
site-wide nav link
- I can't say <s:url action="foo/bar".../> if using
code-behind because of the afore-mentioned slash issue
- I'd *rather* not say <s:url
value="/foo/bar.action".../> um... for purity? But
maybe this is the "best" answer.

It all started because I wanted to use the @Result(s)
annotations (code-behind dependent?) but this may not
end well.

I guess it's not so much that I don't like the
namespaces, it's just that I wanted the best of both
worlds, because I'm really lazy.

d.



 
____________________________________________________________________________________
Cheap talk?
Check out Yahoo! Messenger's low PC-to-Phone call rates.
http://voice.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [s2] 2.0.4, problem with SlashesInActionNames?

Posted by Don Brown <do...@gmail.com>.
Hmm..they very well could be exclusive.  I put the slashes in name
thing in there to support folks that used XML configuration, but
wanted to do more wildcard-type things with it.  Codebehind is
generally meant for the more convention-based style.

Say more about what you don't like about how namespaces are handled.

Don

On 2/2/07, Dave Newton <ne...@yahoo.com> wrote:
> --- Don Brown <do...@gmail.com> wrote:
> > Open up JIRA tickets for both.  If possible, write a
> > unit test for the action name slash issue that
> > replicates your situation.
>
> It's a conflict between the codebehind plugin and the
> slashes stuff... when I remove the codebehind plugin
> everything works normally.
>
> Is it still an issue, or are they just mutually
> exclusive? I like the codebehind etc. but the
> namespaces seem to make more work for me when I link
> to non-workspace-relative URLs.
>
> Dave
>
>
>
>
> ____________________________________________________________________________________
> Bored stiff? Loosen up...
> Download and play hundreds of games for free on Yahoo! Games.
> http://games.yahoo.com/games/front
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [s2] 2.0.4, problem with SlashesInActionNames?

Posted by Dave Newton <ne...@yahoo.com>.
--- Don Brown <do...@gmail.com> wrote:
> Open up JIRA tickets for both.  If possible, write a
> unit test for the action name slash issue that 
> replicates your situation.

It's a conflict between the codebehind plugin and the
slashes stuff... when I remove the codebehind plugin
everything works normally.

Is it still an issue, or are they just mutually
exclusive? I like the codebehind etc. but the
namespaces seem to make more work for me when I link
to non-workspace-relative URLs.

Dave



 
____________________________________________________________________________________
Bored stiff? Loosen up... 
Download and play hundreds of games for free on Yahoo! Games.
http://games.yahoo.com/games/front

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [s2] 2.0.4, problem with SlashesInActionNames?

Posted by Don Brown <do...@gmail.com>.
Open up JIRA tickets for both.  If possible, write a unit test for the
action name slash issue that replicates your situation.

Don

On 2/2/07, Dave Newton <ne...@yahoo.com> wrote:
> My 2.0.4 config is identical(ish) to my 2.0.3 configs,
> I have struts.enable.SlashesInActionNames in both
> struts.properties and struts.xml (and in a re-jarred
> core, just in case) and I still get the 'no action in
> namespace' msg for my actions... um... with slashes.
>
> Non-slashed action names work as expected, my actions
> are all in a default pakg extends struts-default and
> I've manually set the namespace on the package to "",
> also just in case.
>
> BTW, it'd be cool if the properties started with
> consistent case or used equalsIgnoreCase :/ Or if
> there's a method to the madness, write it down :)
>
> d.
>
>
>
>
> ____________________________________________________________________________________
> Have a burning question?
> Go to www.Answers.yahoo.com and get answers from real people who know.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org