Re: [S2] Trouble getting started [OFF-LIST]

2015-10-01 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Lucasz,

On 9/28/15 2:51 AM, Lukasz Lenart wrote:
>>> It's not deployed as a WAR, but as webapps/ROOT (exploded WAR 
>>> directory).
>> 
>> For completeness, this is what is contained in my ROOT directory 
>> ("deploy" is my CATALINA_BASE for Tomcat):
>> 
>> deploy/webapps/ROOT deploy/webapps/ROOT/WEB-INF 
>> deploy/webapps/ROOT/WEB-INF/classes 
>> deploy/webapps/ROOT/WEB-INF/classes/com 
>> deploy/webapps/ROOT/WEB-INF/classes/my/project 
>> deploy/webapps/ROOT/WEB-INF/classes/my/project/business 
>> deploy/webapps/ROOT/WEB-INF/classes/my/project/business/BaseAction.cl
ass
>>
>> 
deploy/webapps/ROOT/WEB-INF/classes/my/project/business/ListAction.class
>> deploy/webapps/ROOT/WEB-INF/classes/struts.xml 
>> deploy/webapps/ROOT/WEB-INF/lib 
>> deploy/webapps/ROOT/WEB-INF/lib/commons-fileupload-1.3.1.jar 
>> deploy/webapps/ROOT/WEB-INF/lib/commons-io-2.2.jar 
>> deploy/webapps/ROOT/WEB-INF/lib/commons-lang3-3.2.jar 
>> deploy/webapps/ROOT/WEB-INF/lib/commons-logging-1.1.3.jar 
>> deploy/webapps/ROOT/WEB-INF/lib/commons-logging-api-1.1.jar 
>> deploy/webapps/ROOT/WEB-INF/lib/freemarker-2.3.22.jar 
>> deploy/webapps/ROOT/WEB-INF/lib/javassist-3.11.0.GA.jar 
>> deploy/webapps/ROOT/WEB-INF/lib/ognl-3.0.6.jar 
>> deploy/webapps/ROOT/WEB-INF/lib/struts2-core-2.3.24.1.jar 
>> deploy/webapps/ROOT/WEB-INF/lib/xwork-core-2.3.24.1.jar 
>> deploy/webapps/ROOT/WEB-INF/list.jsp 
>> deploy/webapps/ROOT/WEB-INF/web.xml
> 
> Looks good, could you build a war and send it to me or share
> somewhere?

I re-named packages a bit and trimmed it down to the minimum. I
apologize if there is something in there that is really broken, but it
should run as-is.

I've dropped the WAR here:
http://christopherschultz.net/temp/ROOT.war

I have included the Java source within the WAR under src/

Please let me know if you can detect any problems, here.

Thanks,
- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJWDTzEAAoJEBzwKT+lPKRY3Q0P/05X6KLYSFDGShf/udaGkDb4
OC5CLmLFqbh8iDfyAm897GjRXTFNmxhvq0Tx1wYWekQzlFFKXchkgbMwoBcEo36q
83K/27r7Ah9MtccFV31Fd6cr2tCjWx0JkLUqoJjlCD3bvdqLVBGe2lk3FVEjrXU2
rVtPeB/DAePQLNKWxx/wXj+j4EX6eGVC69DX3HvfzuAu3dlaKWSww2uZJHFxJbof
PCfSZ/aLnn0Y+GhJlMTBq1wOVlgcK6b8joknSccps2rlZTEUbCkOUOLWnyNlSAiO
Um5Yxa53wdvMsMuldwh7wAevxcVhiA1WJQ035L4c1LfnBj4IKxoRx2JzlVNURm5b
YgcM7gJgfBfMrfPp2kw1umtT2x8hLQbL+SzRL5ROLLfbyEPFc6/izNt3tnsnIzmE
BQ6fYjrQb6VnZL7/LpdxNFw7PDPcXc0Zise7YvlWh92E0AO8sWb7ZVORk6l/Xd8H
ohAUO+UKlc06XFfDuTwmkaxVCxU/gbc6GTVl2xBDXfkIqsxtp3I2gUuEyTD6AY3W
dG3xcoEPILtttNxEEZ6wm1Bhj8+w7G4NVL5HddD/KoXaDxGZimWZmx4CfVU77jOD
4b/CHjyF4eghBPkqGAfksLh4uxhgD8fBa74wtMlA60YbvqYyoQ0mzqOxZqKCSrTd
jWkbU43vbJgnLZZZAVVW
=1FR9
-END PGP SIGNATURE-

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



Re: [S2] Trouble getting started

2015-10-01 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Christoph,

On 9/28/15 12:11 PM, Christopher Schultz wrote:
> Christoph,
> 
> On 9/28/15 6:52 AM, Christoph Nenning wrote:
>>> From: Christopher Schultz  To: 
>>> Struts Users Mailing List , Date: 
>>> 26.09.2015 23:31 Subject: [S2] Trouble getting started
>>> 
>>> -BEGIN PGP SIGNED MESSAGE- Hash: SHA256
>>> 
>>> All,
>>> 
>>> I'm working on a fresh project and using Struts 2 for the
>>> first time. I've been using Struts 1 for more than 10 years and
>>> I generally know my way around web applications.
>>> 
>>> I just can't seem to get a fairly simple setup working. I'm 
>>> intending to use XML-based configuration and not
>>> annotation-based configuration.
>>> 
>>> Here's what I've got:
>>> 
>>> * Struts 2.3.24.1 * Tomcat 8.0.24 * A simple web app
>>> 
>>> My web.xml looks like this:   Struts 2 
>>> action filter. 
>>> struts2
>>> 
>>> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareA
n
>
>>> 
dEx
>>> 
>>> 
> ecuteFilter
>>>  actionPackages 
>>> my.package.business   
>>> 
>>> 
> 
>> Nope, "actionPackages" is used by convention-plugin only. You
>> don't need it in your case.
> 
> Thanks.
> 
>>>  struts2 
>>> /* 
>>> 
> 
>> This could be the problem. Please try *.action here. Not sure 
>> anymore but I think there are issues when using different 
>> url-patterns.
> 
> /* ought to work, but I'll try *.action.

No change, but I really didn't expect any. The Filter can't tell what
its own url-mapping is, so this shouldn't have made any difference.

- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJWDTwHAAoJEBzwKT+lPKRYC4EP/3VrseXUH2J7MP9Z7TR82DBC
NTkMqUxUGLC/f+d+XjL5v5s0sYJc3KlS/gcl5DN4nbZ2+cRPZwskMqncASLrLQ+2
355+C7jLLKP9Pri7Tl4Bw/RjO53OCFxTqIx7xr12MHwgiq9ZKj3uAJFAXZew7V8/
7aSRjO0FS0yeEXRUiI+u7AeU2Flqv+t6D6OHawbyJ2iQQwQv0cIiQIIqL6HhdR1E
pX421RIFbFna5323s1JuasUgKF+RnTm1T6guw6/ATcbP2qg4on/HjeamQAFsfFO+
FtdFyBmjcjKp6W21e9dvaNQZhrcpet1SavvqjSLuOZ9QEPt50oEmhPDtL6xDpqyE
JYuVYROunH20QS0zV3WxYMexXavdiH2Cp8VxrLj9tzdvCePPc9fPQxC6dhIMp/5P
B5igQmJjt/WVRcKUlBbVEgoz6lJGRnh0VXymx2hY2bZPkSusRw8qPsww72dmsfYl
aRSXy6W6RM2L7mTYO4F2Q45XNM75TKFQbZrwN8vsfrjvVkdf888Yt/1CUR65oOK6
A2qHHNeKh08S6q0yShtazvSi/pGvA+WXzvqXWySCjU725vzha4a/puqciOQWuIt+
SsybXAJyhQYTBBgd6R2ZE0ydfb1NIzZDjtP7kgMwpYXz+bV+L4cNO3OwVEmme6Vh
wY2c5BWdeZSA9ywsqgYM
=DIBz
-END PGP SIGNATURE-

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



Re: [S2] Trouble getting started [OFF-LIST]

2015-10-01 Thread Lukasz Lenart
Works :)

Just dropped your package into webapps folder (Apache Tomcat 7.0.40 on
JDK8) and all is ok - except list.jsp contains some strange XML
definition (in wrong place)

http://screencast.com/t/t8s0xyQCHbG4


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

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



Re: [S2] Trouble getting started [OFF-LIST]

2015-10-01 Thread Dave Newton
I'm not sure what the issue is; it starts up fine for me, except for the
bogus XML in list.jsp.

On Thu, Oct 1, 2015 at 10:06 AM, Lukasz Lenart 
wrote:

> Works :)
>
> Just dropped your package into webapps folder (Apache Tomcat 7.0.40 on
> JDK8) and all is ok - except list.jsp contains some strange XML
> definition (in wrong place)
>
> http://screencast.com/t/t8s0xyQCHbG4
>
>
> Regards
> --
> Łukasz
> + 48 606 323 122 http://www.lenart.org.pl/
>
> -
> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
> For additional commands, e-mail: user-h...@struts.apache.org
>
>


-- 
e: davelnew...@gmail.com
m: 908-380-8699
s: davelnewton_skype
t: @dave_newton 
b: Bucky Bits 
g: davelnewton 
so: Dave Newton 


Re: [S2] Trouble getting started [OFF-LIST]

2015-10-01 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Lucasz,

On 10/1/15 10:06 AM, Lukasz Lenart wrote:
> Works :)
> 
> Just dropped your package into webapps folder (Apache Tomcat 7.0.40
> on JDK8) and all is ok - except list.jsp contains some strange XML 
> definition (in wrong place)
> 
> http://screencast.com/t/t8s0xyQCHbG4

Well, damn. Time to figure out what's wrong with my environment, then.

I have Tomcat running on localhost:8080 so I requested
http://localhost:8080/list.action Is that what you did? Are you
"tailing" catalina.out? (Or running "catalina.sh run" from the CLI?)

Thanks,
- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJWDY2EAAoJEBzwKT+lPKRYuz4P/069K1hak1SJz60awA6VGuYw
KUhGGfegl6DSg68pGPWmygGDzNE0Jnx2iMvoa+tJO3WVgjR+9gvjJJAbmX5NN7ws
FLpLXPFM3UGVw1j6J+JSoCuEEwlPjwsgwkVvS7FqwAuzBBeVD19hBjIBcih5ImgW
VXYYzle9DpBavpdPsb53hwZIPmyuHH+EX6POfUfQgNtR1oTRIGtnsFiq6LMJ1cz7
FoXUajolAASBIBVCTMuF5yWTwpHLev52w/nerxwvKVtRhfpO/epl3xFlFzLD1V+h
aidJxoIf0Rjx7RGB4kdy6b0L4fw3gvJsl9xB8aJ1Jm4VQe53e3XX/RAJlh9aLYm2
ZtH+ATazZ2XyHv+klDexo61YAiQBZ5DIfp2xCfvmuA8rDCJghBD2tFmAAolu5DRp
z59A5gRS5DB4q7gp7PH22QH0hGjSLpXSVXRLxditJz0Ek9Ymerf6L7qEyco8/RcC
35hWPeO035yRhq9s83ZeJwllPhwTiE37ZIVt7r1fbZ4Kl4fClpzG89pYy5prY7lJ
Vcx30B2GOsfWuOJZuKsi3M4XXlZKs/AYwqGN0SEfyxx8Ls3oWkZlGvY0yhPM3qzG
3erpg2Htl3W7BvD7hM4d/N14qVMX6wZwVUb2a6tdzVvtETe20QgdXdSyFAFDEpbN
Z5JBhlv/UT/70nnm4v7e
=sGgN
-END PGP SIGNATURE-

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



Re: [S2] Trouble getting started [OFF-LIST]

2015-10-01 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Lucasz,

On 10/1/15 10:06 AM, Lukasz Lenart wrote:
> Works :)
> 
> Just dropped your package into webapps folder (Apache Tomcat 7.0.40
> on JDK8) and all is ok - except list.jsp contains some strange XML 
> definition (in wrong place)
> 
> http://screencast.com/t/t8s0xyQCHbG4

facepalm

I was missing CATALINA_BASE/conf/web.xml so Tomcat was braindead (with
no logs! yay!).

I'm back on track. Sorry for the foolishness, everyone.

- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJWDZI4AAoJEBzwKT+lPKRYb9UQAIDBH2qGeDpF+Gp3GnkIgVry
Z2ONO4ZFydNkiMf+RDP8/E+MXHhDp/YQG+/DDF9TvYXCn+i1gqK7CpscG0zPooHL
Ws+ceRJu3EYoIgurdLt5orquUfNxgT1+GCjiuEmZPCgXFsVdbG0XYqgsXBxYQ/Xl
KzEl46sXlHLQbOpxUZvsFT+k7zFQSvF2qFMM2UW3wQUZx4VmfSvvB/Dbr0wtRrC6
bgHDeM3AiJPMdJ3tbA/HQTtyCBWVeKJ5S4XpIgr6QlbBsVXlGzVyEwNeSK7XstGp
MLrUx2iqyvUnG9iyw3IKbAXbd/NgHlHjyHo8v5LkfzW/Nl4DHsSs85+dO7RwEHNB
UuvdOvFH9RmPg4VFHrmKCGQQvrgpWxcTiZmGUO5a0TVrlr9QOU1xpp3/0LgAssaW
ghIIhrCIXk+LWTsST+dxsKZYPQJ1hYxdrswLCiOyxZqLn0VON8LtSt4lCJSpoEb8
XjLSCyON/9mmvCj3/vZVwYNlTANKeO6i3nu4dsSTniM/SKZwu+PDdBZkWCsA2Jll
FdniY01NTtnyATyJqLVVwfnA/Q2IrIJFeaM6jfDK7DeKmD18bas8vLD+AphgzSvI
jck3CUQB+8samZDgZGwsy8xOVjp/Hqt6jxNEqx4xbkWk1mOGIuQfPBeO4LjiOeY3
gQlpMV3vSSCEslVME/Z1
=sr1R
-END PGP SIGNATURE-

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



Re: [S2] Trouble getting started

2015-09-28 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Christoph,

On 9/28/15 6:52 AM, Christoph Nenning wrote:
>> From: Christopher Schultz  To:
>> Struts Users Mailing List , Date:
>> 26.09.2015 23:31 Subject: [S2] Trouble getting started
>> 
>> -BEGIN PGP SIGNED MESSAGE- Hash: SHA256
>> 
>> All,
>> 
>> I'm working on a fresh project and using Struts 2 for the first
>> time. I've been using Struts 1 for more than 10 years and I
>> generally know my way around web applications.
>> 
>> I just can't seem to get a fairly simple setup working. I'm
>> intending to use XML-based configuration and not annotation-based
>> configuration.
>> 
>> Here's what I've got:
>> 
>> * Struts 2.3.24.1 * Tomcat 8.0.24 * A simple web app
>> 
>> My web.xml looks like this:   Struts 2
>> action filter.  struts2
>> 
>> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAn
dEx
>>
>> 
ecuteFilter
>>  actionPackages 
>> my.package.business   
>> 
>> 
> 
> Nope, "actionPackages" is used by convention-plugin only. You don't
> need it in your case.

Thanks.

>>  struts2 
>> /* 
>> 
> 
> This could be the problem. Please try *.action here. Not sure
> anymore but I think there are issues when using different
> url-patterns.

/* ought to work, but I'll try *.action.

>> My struts.xml looks like this:
>> 
>>  > "-//Apache Software Foundation//DTD Struts Configuration
>> 2.0//EN" "http://struts.apache.org/dtds/struts-2.0.dtd;>
>> 
>>  
>> 
>>  
>>  
>> /WEB-INF/list.jsp   
>> 
>> 
>> I have a class, my.package.business.ListAction which has a
>> 
>> public String execute()
>> 
>> method. I return "success" from this method (unless an exception
>> is thrown). During startup, I can see that Struts/XWork is being
>> initialize d:
>> 
>> 26-Sep-2015 17:19:32.613 FINE [localhost-startStop-1] 
>> com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.deb
ug
>>
>> 
Loaded
>> list in 'default' package:{ActionConfig //list 
>> (my.package.business.ListAction) - action - 
>> file:/path/to/deploy/webapps/ROOT/WEB-INF/classes/struts.xml: 
>> 9:68}
>> 
>> When I try to access http://localhost:8080/list.action, I get a
>> 404 response with nothing in the logs (except the access log:
>> request to /list.action resulted in a 404).
>> 
> 
> Comes the 404 along with html?

No, there is no content.

> What does it look like?

Blank page. I believe Tomcat returns 404 with no document, but I
haven't looked at the protocol trace, yet.

> Is it a tomcat-error-page?

No.

> Do you have your app deployed as root app? So you don't need
> context-path in URL?

Correct.

- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJWCWbLAAoJEBzwKT+lPKRY0osQAK3Omvyx4+gFCc3qtQ8fuUjI
U0kR9GNww/WbcP3mGgSDxOtntGI2ddw/0mJou4tH7F5NnV69t7PjXF6I0ni9z49p
g/Zz8kjjosfPOInlU65DeH+FMcI+FHH1LS/vbS/iOr7HAMl9O8yEfMniJDQef4DE
haqM/IF/yyvj8cfd9o5eVAcHguIyLw0f+smEms8wgzxvcewyw9NoZqgUGSpK/Uk2
lbOawTsaBg4hcqS3tvwAH1Nj79BPNS+17vFlwLcijv1H0n1bltKxW3DHg6MixHsd
/uEJNlewRjB7A+9n4F13Xhy+Q7wi+Opr3Adj7/1eWY6W8wl+pSg0ff3G4/8uVvZA
3pLLEVIFbMVA1dL9nKuKKqQftiQzf665ngCrLjkd3d0QmtaXzTx8PZc3sMe4EjBy
+lwgImyPt9cM1jwnzlNaxliipopd5qtxb84p5zBWenP3Y0vlma8qEk9DH2kf0klz
Lbdj6wi8ekXNgYZcewcCBPBeJwWK1McpIYQ3ejJd+bdpxX2BDPiZGrjzxwovkan/
wA0K5aXfcvOzhdGO3ew1+EQvEWZ7sPPKj281ozg7KHfqWlCB9hJP6Wch5a8vB0QG
JEXIM2NQgYQyLTb8lAQME72N6op8MS36KwESHUHq9ZLQ5aijdXASLOvbcPGA8edX
i0nAKMO32wkjKJEIQzph
=vk6p
-END PGP SIGNATURE-

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



Re: [S2] Trouble getting started

2015-09-28 Thread Lukasz Lenart
2015-09-27 18:02 GMT+02:00 Christopher Schultz :
>> The best option is to use one of Maven's archetypes
>>
>> http://struts.apache.org/docs/struts-2-maven-archetypes.html#Struts2Ma
> venArchetypes-Quickstart
>
> Yeah...
>>
> I was trying to avoid using Maven, which to me has too much
> opaque hand-waving that I neither understand nor control.
>
> I have what I believe is a fairly simple test app at this point. I
> should be able to get it to work without resorting to drastic measures :
> )

Maven isn't that bad and it's a good time to learn S2 and Maven together ;-)

>> Wrong DTD, please use the latest one
>>
>> > Configuration 2.3//EN"
>> "http://struts.apache.org/dtds/struts-2.3.dtd;>
>
> Yep, I updated to this one this morning, after trying to find out the
> default value for the  "name" attribute. Still no change.

"name" isn't mandatory, it will fallback to "success" if not set. But
maybe you are right and we should define the default value.

>> Are you sure that you have deployed your app as ROOT.war to
>> $TOMCAT_HOME/webapps ?
>
> It's not deployed as a WAR, but as webapps/ROOT (exploded WAR directory)

Could you build a war and deploy it manually?


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

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



Re: [S2] Trouble getting started

2015-09-28 Thread Lukasz Lenart
2015-09-28 6:37 GMT+02:00 Yaragalla Muralidhar :
> Hi Chris,
>   I have not checked the DTD. But i got this idea from sample struts2 apps.
> I dont think there will be a default value for the "name" attribute.

It is, for 'name" and for other parts
http://struts.apache.org/docs/result-configuration.html#ResultConfiguration-IntelligentDefaults


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

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



Re: [S2] Trouble getting started

2015-09-28 Thread Lukasz Lenart
>> It's not deployed as a WAR, but as webapps/ROOT (exploded WAR
>> directory).
>
> For completeness, this is what is contained in my ROOT directory
> ("deploy" is my CATALINA_BASE for Tomcat):
>
> deploy/webapps/ROOT
> deploy/webapps/ROOT/WEB-INF
> deploy/webapps/ROOT/WEB-INF/classes
> deploy/webapps/ROOT/WEB-INF/classes/com
> deploy/webapps/ROOT/WEB-INF/classes/my/project
> deploy/webapps/ROOT/WEB-INF/classes/my/project/business
> deploy/webapps/ROOT/WEB-INF/classes/my/project/business/BaseAction.class
> deploy/webapps/ROOT/WEB-INF/classes/my/project/business/ListAction.class
> deploy/webapps/ROOT/WEB-INF/classes/struts.xml
> deploy/webapps/ROOT/WEB-INF/lib
> deploy/webapps/ROOT/WEB-INF/lib/commons-fileupload-1.3.1.jar
> deploy/webapps/ROOT/WEB-INF/lib/commons-io-2.2.jar
> deploy/webapps/ROOT/WEB-INF/lib/commons-lang3-3.2.jar
> deploy/webapps/ROOT/WEB-INF/lib/commons-logging-1.1.3.jar
> deploy/webapps/ROOT/WEB-INF/lib/commons-logging-api-1.1.jar
> deploy/webapps/ROOT/WEB-INF/lib/freemarker-2.3.22.jar
> deploy/webapps/ROOT/WEB-INF/lib/javassist-3.11.0.GA.jar
> deploy/webapps/ROOT/WEB-INF/lib/ognl-3.0.6.jar
> deploy/webapps/ROOT/WEB-INF/lib/struts2-core-2.3.24.1.jar
> deploy/webapps/ROOT/WEB-INF/lib/xwork-core-2.3.24.1.jar
> deploy/webapps/ROOT/WEB-INF/list.jsp
> deploy/webapps/ROOT/WEB-INF/web.xml

Looks good, could you build a war and send it to me or share somewhere?


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

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



Re: [S2] Trouble getting started

2015-09-28 Thread Christoph Nenning
> From: Christopher Schultz 
> To: Struts Users Mailing List , 
> Date: 26.09.2015 23:31
> Subject: [S2] Trouble getting started
> 
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA256
> 
> All,
> 
> I'm working on a fresh project and using Struts 2 for the first time.
> I've been using Struts 1 for more than 10 years and I generally know
> my way around web applications.
> 
> I just can't seem to get a fairly simple setup working. I'm intending
> to use XML-based configuration and not annotation-based configuration.
> 
> Here's what I've got:
> 
> * Struts 2.3.24.1
> * Tomcat 8.0.24
> * A simple web app
> 
> My web.xml looks like this:
>   
> 
>   Struts 2 action filter.
> 
> struts2
> 
> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndEx
> ecuteFilter
> 
>   actionPackages
>   my.package.business
> 
> 
>   
> 

Nope, "actionPackages" is used by convention-plugin only. You don't need 
it in your case.





>   
> struts2
> /*
>   
> 

This could be the problem. Please try *.action here. Not sure anymore but 
I think there are issues when using different url-patterns.




> My struts.xml looks like this:
> 
> 
>  Configuration 2.0//EN"
> "http://struts.apache.org/dtds/struts-2.0.dtd;>
> 
> 
>   
> 
>   
> 
>   /WEB-INF/list.jsp
> 
>   
> 
> 
> I have a class, my.package.business.ListAction which has a
> 
>   public String execute()
> 
> method. I return "success" from this method (unless an exception is
> thrown). During startup, I can see that Struts/XWork is being initialize
> d:
> 
> 26-Sep-2015 17:19:32.613 FINE [localhost-startStop-1]
> com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.debug
> Loaded
> list in 'default' package:{ActionConfig //list
> (my.package.business.ListAction) - action -
> file:/path/to/deploy/webapps/ROOT/WEB-INF/classes/struts.xml:
> 9:68}
> 
> When I try to access http://localhost:8080/list.action, I get a 404
> response with nothing in the logs (except the access log: request to
> /list.action resulted in a 404).
> 

Comes the 404 along with html?
What does it look like?
Is it a tomcat-error-page?


Do you have your app deployed as root app?
So you don't need context-path in URL?


Regards,
Christoph


This Email was scanned by Sophos Anti Virus


Re: [S2] Trouble getting started

2015-09-27 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Yaragalla,

On 9/27/15 1:38 AM, Yaragalla Muralidhar wrote:
> Try the following.
> 
>  
>   *name="success"*  >/WEB-INF/list.jsp  

No change. Note that I see nothing in the TRACE log for Struts (or,
really, anything) when I make the request to
http://localhost:8080/list.action. It's almost as if the Filter does
not run at all.

What's the default value of 's "name" attribute? It's not
defined in the DTD:


 

Thanks,
- -chris

> On Sun, Sep 27, 2015 at 3:00 AM, Christopher Schultz < 
> ch...@christopherschultz.net> wrote:
> 
> All,
> 
> I'm working on a fresh project and using Struts 2 for the first
> time. I've been using Struts 1 for more than 10 years and I
> generally know my way around web applications.
> 
> I just can't seem to get a fairly simple setup working. I'm
> intending to use XML-based configuration and not annotation-based
> configuration.
> 
> Here's what I've got:
> 
> * Struts 2.3.24.1 * Tomcat 8.0.24 * A simple web app
> 
> My web.xml looks like this:   Struts 2 action
> filter.  struts2
> 
> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAnd
Ex
>
> 
ecuteFilter
>  actionPackages 
> my.package.business   
> 
>  struts2 
> /* 
> 
> My struts.xml looks like this:
> 
>   "-//Apache Software Foundation//DTD Struts Configuration 2.0//EN" 
> "http://struts.apache.org/dtds/struts-2.0.dtd;>
> 
>  
> 
>  
>  
> /WEB-INF/list.jsp   
> 
> I have a class, my.package.business.ListAction which has a
> 
> public String execute()
> 
> method. I return "success" from this method (unless an exception
> is thrown). During startup, I can see that Struts/XWork is being
> initialize d:
> 
> 26-Sep-2015 17:19:32.613 FINE [localhost-startStop-1] 
> com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.debu
g
>
> 
Loaded
> list in 'default' package:{ActionConfig //list 
> (my.package.business.ListAction) - action - 
> file:/path/to/deploy/webapps/ROOT/WEB-INF/classes/struts.xml: 
> 9:68}
> 
> When I try to access http://localhost:8080/list.action, I get a
> 404 response with nothing in the logs (except the access log:
> request to /list.action resulted in a 404).
> 
> I'm sure I'm missing something super simple, here. Can anyone offer
> a suggestion?
> 
> Thanks, -chris
>> 
>> -
>>
>> 
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
>> For additional commands, e-mail: user-h...@struts.apache.org
>> 
>> 
> 
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJWB+T8AAoJEBzwKT+lPKRYvhIP/RTBeHWCeF9X30cOcOUZsWJG
/fYwTOVy3MFCBpdPuiOKwvB0WoketuobsV0T3Qm3qj6Frgi6gfBmeSZtXSV3Osug
RiYj64ZDeVI5UJE8axrp5uNyDySggBcgRxivL5OHkf5xjFGcTxdpVjGhF20/iUm8
xJbkcRn6oXTKhC0xC7JxWAf2K8XI5se+BQAbl9aSPGacDHnseDasfFNsNiaWtAUF
7aMg5Q5FNIS3EQP/1JMQwH5i1o6WDtBhTk2bjGXn31bw7bVG1Ab1ce+HIfB2V1uG
WDt7NuIicl0JiBswvHKeidDfs8LbeR3UyJC543fW2iC1MPKSstHK2voSf/u7jwNC
s1bULHC4ssupMcIh9HuVZWFecxfKO6/eSiAY2SHZ6SHHvaQAWvbjyQ+4+9rSnAwB
/tUIFqfhlR1ngPBdOVE4EnGctcck+TVFLso0MovDSXcbpIRyWUni66Ik4u8KFbpB
Y3HQONn0OGJfC6XymduwO1tyrMLrvKDA07KDpLrtRxHsr/gjSBD4rOswwepBpGUc
NfKhRWzLPPCnJQxHp/2Z5m4NPmW/hCyltonbQ007ho0LBt+OysisRxjRUAaKkx/Z
sxKjVbWoPWQ+l1wzGIeCh12e38dOhXUWXNj5g44TFYobAz3WCAmWdd7SPt4vr1If
ERHlhVfBfRI3YFuYxk17
=Uji8
-END PGP SIGNATURE-

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



Re: [S2] Trouble getting started

2015-09-27 Thread Thomas Sattler
try struts2builder.sourceforge.net



On Sunday, September 27, 2015, Christopher Schultz <
ch...@christopherschultz.net> wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA256
>
> Yaragalla,
>
> On 9/27/15 1:38 AM, Yaragalla Muralidhar wrote:
> > Try the following.
> >
> > 
> >   > *name="success"*  >/WEB-INF/list.jsp  
>
> No change. Note that I see nothing in the TRACE log for Struts (or,
> really, anything) when I make the request to
> http://localhost:8080/list.action. It's almost as if the Filter does
> not run at all.
>
> What's the default value of 's "name" attribute? It's not
> defined in the DTD:
>
> 
>  name CDATA #IMPLIED
> type CDATA #IMPLIED
> >
>
> Thanks,
> - -chris
>
> > On Sun, Sep 27, 2015 at 3:00 AM, Christopher Schultz <
> > ch...@christopherschultz.net > wrote:
> >
> > All,
> >
> > I'm working on a fresh project and using Struts 2 for the first
> > time. I've been using Struts 1 for more than 10 years and I
> > generally know my way around web applications.
> >
> > I just can't seem to get a fairly simple setup working. I'm
> > intending to use XML-based configuration and not annotation-based
> > configuration.
> >
> > Here's what I've got:
> >
> > * Struts 2.3.24.1 * Tomcat 8.0.24 * A simple web app
> >
> > My web.xml looks like this:   Struts 2 action
> > filter.  struts2
> >
> > org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAnd
> Ex
> >
> >
> ecuteFilter
> >  actionPackages
> > my.package.business   
> >
> >  struts2
> > /* 
> >
> > My struts.xml looks like this:
> >
> >   > "-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
> > "http://struts.apache.org/dtds/struts-2.0.dtd;>
> >
> >  
> >
> > 
> > 
> > /WEB-INF/list.jsp   
> >
> > I have a class, my.package.business.ListAction which has a
> >
> > public String execute()
> >
> > method. I return "success" from this method (unless an exception
> > is thrown). During startup, I can see that Struts/XWork is being
> > initialize d:
> >
> > 26-Sep-2015 17:19:32.613 FINE [localhost-startStop-1]
> > com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.debu
> g
> >
> >
> Loaded
> > list in 'default' package:{ActionConfig //list
> > (my.package.business.ListAction) - action -
> > file:/path/to/deploy/webapps/ROOT/WEB-INF/classes/struts.xml:
> > 9:68}
> >
> > When I try to access http://localhost:8080/list.action, I get a
> > 404 response with nothing in the logs (except the access log:
> > request to /list.action resulted in a 404).
> >
> > I'm sure I'm missing something super simple, here. Can anyone offer
> > a suggestion?
> >
> > Thanks, -chris
> >>
> >> -
> >>
> >>
> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org 
> >> For additional commands, e-mail: user-h...@struts.apache.org
> 
> >>
> >>
> >
> -BEGIN PGP SIGNATURE-
> Comment: GPGTools - http://gpgtools.org
>
> iQIcBAEBCAAGBQJWB+T8AAoJEBzwKT+lPKRYvhIP/RTBeHWCeF9X30cOcOUZsWJG
> /fYwTOVy3MFCBpdPuiOKwvB0WoketuobsV0T3Qm3qj6Frgi6gfBmeSZtXSV3Osug
> RiYj64ZDeVI5UJE8axrp5uNyDySggBcgRxivL5OHkf5xjFGcTxdpVjGhF20/iUm8
> xJbkcRn6oXTKhC0xC7JxWAf2K8XI5se+BQAbl9aSPGacDHnseDasfFNsNiaWtAUF
> 7aMg5Q5FNIS3EQP/1JMQwH5i1o6WDtBhTk2bjGXn31bw7bVG1Ab1ce+HIfB2V1uG
> WDt7NuIicl0JiBswvHKeidDfs8LbeR3UyJC543fW2iC1MPKSstHK2voSf/u7jwNC
> s1bULHC4ssupMcIh9HuVZWFecxfKO6/eSiAY2SHZ6SHHvaQAWvbjyQ+4+9rSnAwB
> /tUIFqfhlR1ngPBdOVE4EnGctcck+TVFLso0MovDSXcbpIRyWUni66Ik4u8KFbpB
> Y3HQONn0OGJfC6XymduwO1tyrMLrvKDA07KDpLrtRxHsr/gjSBD4rOswwepBpGUc
> NfKhRWzLPPCnJQxHp/2Z5m4NPmW/hCyltonbQ007ho0LBt+OysisRxjRUAaKkx/Z
> sxKjVbWoPWQ+l1wzGIeCh12e38dOhXUWXNj5g44TFYobAz3WCAmWdd7SPt4vr1If
> ERHlhVfBfRI3YFuYxk17
> =Uji8
> -END PGP SIGNATURE-
>
> -
> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org 
> For additional commands, e-mail: user-h...@struts.apache.org
> 
>
>

-- 
Sent from my iPhone


Re: [S2] Trouble getting started

2015-09-27 Thread Lukasz Lenart
2015-09-26 23:30 GMT+02:00 Christopher Schultz :
> I'm working on a fresh project and using Struts 2 for the first time.
> I've been using Struts 1 for more than 10 years and I generally know
> my way around web applications.
>
> I just can't seem to get a fairly simple setup working. I'm intending
> to use XML-based configuration and not annotation-based configuration.

The best option is to use one of Maven's archetypes

http://struts.apache.org/docs/struts-2-maven-archetypes.html#Struts2MavenArchetypes-Quickstart

> Here's what I've got:
>
> * Struts 2.3.24.1
> * Tomcat 8.0.24
> * A simple web app
>
> My web.xml looks like this:
>   
> 
>   Struts 2 action filter.
> 
> struts2
>
> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndEx
> ecuteFilter
> 
>   actionPackages
>   my.package.business
> 

Not needed, it is useful only when using the Convention plugin

> 
>   
>
>   
> struts2
> /*
>   
>
> My struts.xml looks like this:
>
> 
>  Configuration 2.0//EN"
> "http://struts.apache.org/dtds/struts-2.0.dtd;>

Wrong DTD, please use the latest one

http://struts.apache.org/dtds/struts-2.3.dtd;>

> 
>   
>
>   
> 
>   /WEB-INF/list.jsp
> 
>   
> 
>
> I have a class, my.package.business.ListAction which has a
>
>   public String execute()
>
> method. I return "success" from this method (unless an exception is
> thrown). During startup, I can see that Struts/XWork is being initialize
> d:
>
> 26-Sep-2015 17:19:32.613 FINE [localhost-startStop-1]
> com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.debug
> Loaded
> list in 'default' package:{ActionConfig //list
> (my.package.business.ListAction) - action -
> file:/path/to/deploy/webapps/ROOT/WEB-INF/classes/struts.xml:
> 9:68}
>
> When I try to access http://localhost:8080/list.action, I get a 404
> response with nothing in the logs (except the access log: request to
> /list.action resulted in a 404).
>
> I'm sure I'm missing something super simple, here. Can anyone offer a
> suggestion?

Are you sure that you have deployed your app as ROOT.war to
$TOMCAT_HOME/webapps ?


Regars
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

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



Re: [S2] Trouble getting started

2015-09-27 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Lucasz,

On 9/27/15 12:02 PM, Christopher Schultz wrote:
> On 9/27/15 10:08 AM, Lukasz Lenart wrote:
>> 2015-09-26 23:30 GMT+02:00 Christopher Schultz 
>> :
>>> I'm working on a fresh project and using Struts 2 for the
>>> first time. I've been using Struts 1 for more than 10 years and
>>> I generally know my way around web applications.
>>> 
>>> I just can't seem to get a fairly simple setup working. I'm 
>>> intending to use XML-based configuration and not
>>> annotation-based configuration.
> 
>> The best option is to use one of Maven's archetypes
> 
>> http://struts.apache.org/docs/struts-2-maven-archetypes.html#Struts2M
a
>
>> 
venArchetypes-Quickstart
> 
> Yeah...
> 
> I was trying to avoid using Maven, which to me has too much opaque
> hand-waving that I neither understand nor control.
> 
> I have what I believe is a fairly simple test app at this point. I 
> should be able to get it to work without resorting to drastic
> measures : )
> 
>>> Here's what I've got:
>>> 
>>> * Struts 2.3.24.1 * Tomcat 8.0.24 * A simple web app
>>> 
>>> My web.xml looks like this:   Struts 2 
>>> action filter. 
>>> struts2
>>> 
>>> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareA
n
>
>>> 
dEx
>>> 
>>> 
> ecuteFilter
>>>  actionPackages 
>>> my.package.business 
> 
>> Not needed, it is useful only when using the Convention plugin
> 
>>>  
>>> 
>>>  struts2 
>>> /* 
>>> 
>>> My struts.xml looks like this:
>>> 
>>>  >> PUBLIC "-//Apache Software Foundation//DTD Struts
>>> Configuration 2.0//EN"
>>> "http://struts.apache.org/dtds/struts-2.0.dtd;>
> 
>> Wrong DTD, please use the latest one
> 
>> > Struts Configuration 2.3//EN" 
>> "http://struts.apache.org/dtds/struts-2.3.dtd;>
> 
> Yep, I updated to this one this morning, after trying to find out
> the default value for the  "name" attribute. Still no
> change.
> 
>>>  
>>> 
>>> 
>>>   
>>> /WEB-INF/list.jsp   
>>> 
>>> 
>>> I have a class, my.package.business.ListAction which has a
>>> 
>>> public String execute()
>>> 
>>> method. I return "success" from this method (unless an
>>> exception is thrown). During startup, I can see that
>>> Struts/XWork is being initialize d:
>>> 
>>> 26-Sep-2015 17:19:32.613 FINE [localhost-startStop-1] 
>>> com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.de
b
>
>>> 
ug
>>> 
>>> 
> Loaded
>>> list in 'default' package:{ActionConfig //list 
>>> (my.package.business.ListAction) - action - 
>>> file:/path/to/deploy/webapps/ROOT/WEB-INF/classes/struts.xml: 
>>> 9:68}
>>> 
>>> When I try to access http://localhost:8080/list.action, I get
>>> a 404 response with nothing in the logs (except the access
>>> log: request to /list.action resulted in a 404).
>>> 
>>> I'm sure I'm missing something super simple, here. Can anyone 
>>> offer a suggestion?
> 
>> Are you sure that you have deployed your app as ROOT.war to 
>> $TOMCAT_HOME/webapps ?
> 
> It's not deployed as a WAR, but as webapps/ROOT (exploded WAR
> directory).

For completeness, this is what is contained in my ROOT directory
("deploy" is my CATALINA_BASE for Tomcat):

deploy/webapps/ROOT
deploy/webapps/ROOT/WEB-INF
deploy/webapps/ROOT/WEB-INF/classes
deploy/webapps/ROOT/WEB-INF/classes/com
deploy/webapps/ROOT/WEB-INF/classes/my/project
deploy/webapps/ROOT/WEB-INF/classes/my/project/business
deploy/webapps/ROOT/WEB-INF/classes/my/project/business/BaseAction.class
deploy/webapps/ROOT/WEB-INF/classes/my/project/business/ListAction.class
deploy/webapps/ROOT/WEB-INF/classes/struts.xml
deploy/webapps/ROOT/WEB-INF/lib
deploy/webapps/ROOT/WEB-INF/lib/commons-fileupload-1.3.1.jar
deploy/webapps/ROOT/WEB-INF/lib/commons-io-2.2.jar
deploy/webapps/ROOT/WEB-INF/lib/commons-lang3-3.2.jar
deploy/webapps/ROOT/WEB-INF/lib/commons-logging-1.1.3.jar
deploy/webapps/ROOT/WEB-INF/lib/commons-logging-api-1.1.jar
deploy/webapps/ROOT/WEB-INF/lib/freemarker-2.3.22.jar
deploy/webapps/ROOT/WEB-INF/lib/javassist-3.11.0.GA.jar
deploy/webapps/ROOT/WEB-INF/lib/ognl-3.0.6.jar
deploy/webapps/ROOT/WEB-INF/lib/struts2-core-2.3.24.1.jar
deploy/webapps/ROOT/WEB-INF/lib/xwork-core-2.3.24.1.jar
deploy/webapps/ROOT/WEB-INF/list.jsp
deploy/webapps/ROOT/WEB-INF/web.xml

Thanks,
- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJWCBPJAAoJEBzwKT+lPKRYeJsP/AlAP3VoL16o2MTV3qau+zNQ
YLRPkW2qmP2EwIrDBhuhPJeKy/3pt3292Hit0E9KOfoAw5F5/XSEmaPqw6YsvCUp
SN6LgRm9avhdGZyullnuRba/5RN3epjIdT/T+t33KTIyJ2a1aw5hunnx3mNj3qmZ
h0c3UU4CeJDSCfnzvuF86Tzw3OP2+1H+JyKt2cuZZcIs9YGYvM7szqU22mIZ6JO9
i59D44PNVRLtFV/ijzHB4FRM/OIoDRFYLsnrfDi2aqfoQKMYpw5xzB8sM8wo4Hjt
uC0S9ULdlB4VI15FRun/7xUWjPsFG29EWhPR+GBtRIQ+EBnd7JwmhbNERnlCpah/
FADsrQTc5jFHtKPBcrIZS6MHzzXMW98KG4Yj1+PeXCF6IPJsl4jWCr82xhdA0+RV
k3RgLV8deMypGAKrS9K4NG45dkNOKXUHAg6M3nz/M98XTwKLeoxhRxSJUKDWU0/A
6A37iMOTkjrBNbbIItjiE1RscOo0eiNyV8n5ojZMNZy+QivwtpCfX/K3VcMsCQ6E
zTqebLz3J3ga7WRb1iLYhpQbkSGkO5j51k2lYCsn38pWsAPAMSstX/Zit9eAkSPc

Re: [S2] Trouble getting started

2015-09-27 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Lucaz,

On 9/27/15 10:08 AM, Lukasz Lenart wrote:
> 2015-09-26 23:30 GMT+02:00 Christopher Schultz
> :
>> I'm working on a fresh project and using Struts 2 for the first
>> time. I've been using Struts 1 for more than 10 years and I
>> generally know my way around web applications.
>> 
>> I just can't seem to get a fairly simple setup working. I'm
>> intending to use XML-based configuration and not annotation-based
>> configuration.
> 
> The best option is to use one of Maven's archetypes
> 
> http://struts.apache.org/docs/struts-2-maven-archetypes.html#Struts2Ma
venArchetypes-Quickstart

Yeah...
> 
I was trying to avoid using Maven, which to me has too much
opaque hand-waving that I neither understand nor control.

I have what I believe is a fairly simple test app at this point. I
should be able to get it to work without resorting to drastic measures :
)

>> Here's what I've got:
>> 
>> * Struts 2.3.24.1 * Tomcat 8.0.24 * A simple web app
>> 
>> My web.xml looks like this:   Struts 2
>> action filter.  struts2
>> 
>> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAn
dEx
>>
>> 
ecuteFilter
>>  actionPackages 
>> my.package.business 
> 
> Not needed, it is useful only when using the Convention plugin
> 
>>  
>> 
>>  struts2 
>> /* 
>> 
>> My struts.xml looks like this:
>> 
>>  > "-//Apache Software Foundation//DTD Struts Configuration
>> 2.0//EN" "http://struts.apache.org/dtds/struts-2.0.dtd;>
> 
> Wrong DTD, please use the latest one
> 
>  Configuration 2.3//EN" 
> "http://struts.apache.org/dtds/struts-2.3.dtd;>

Yep, I updated to this one this morning, after trying to find out the
default value for the  "name" attribute. Still no change.

>>  
>> 
>>  
>>  
>> /WEB-INF/list.jsp   
>> 
>> 
>> I have a class, my.package.business.ListAction which has a
>> 
>> public String execute()
>> 
>> method. I return "success" from this method (unless an exception
>> is thrown). During startup, I can see that Struts/XWork is being
>> initialize d:
>> 
>> 26-Sep-2015 17:19:32.613 FINE [localhost-startStop-1] 
>> com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.deb
ug
>>
>> 
Loaded
>> list in 'default' package:{ActionConfig //list 
>> (my.package.business.ListAction) - action - 
>> file:/path/to/deploy/webapps/ROOT/WEB-INF/classes/struts.xml: 
>> 9:68}
>> 
>> When I try to access http://localhost:8080/list.action, I get a
>> 404 response with nothing in the logs (except the access log:
>> request to /list.action resulted in a 404).
>> 
>> I'm sure I'm missing something super simple, here. Can anyone
>> offer a suggestion?
> 
> Are you sure that you have deployed your app as ROOT.war to 
> $TOMCAT_HOME/webapps ?

It's not deployed as a WAR, but as webapps/ROOT (exploded WAR directory)
.

Thanks,
- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJWCBMmAAoJEBzwKT+lPKRYcMEP/0nC4WGuUgnXPL9LHzdYof4J
vtPX/kFId8bd22WlUbmh1Iahjh44T/cP0WbN25wigIfu14YU0HIFnGTUC3J1k8QI
8zftjbIY11N3iSnhOnxWZ6Hsjq2zChHifB0xmqVfkKs1CGcK+XqGgAc6eK+FqA42
45+dRxXvLo5N/5hZ17hLzJHMosYcbisxNPxix4PW5x7kxURkzJ8+fRNv4zL3AuFX
ktqzCBOgMCi1XHi4gKi+5AcKq/ooaQojyvjn7htTGI/5fgJfU2giPOjx/y8jpz08
N6hoZBth45Kwk0GJxXSiXThs2Q9vmE6WFaDifyZ8pbs6aVMeBYEIYBPXsPHVH6Ou
QB2QAkp03c+kzZZxwALLrd2ERxaVEbbX6VmmNQjX7+XDeJrBF46xJtzh5mT5kl8J
bqb/+cUSeguOaUHBlpYZkkLCetHiKTNXsA57e3jvhrsrqZdeGFGtlJ8fgiRkxq+8
S9p43kp/H5FG7y0nhNfiPND8gnfE6nFPMvKM481C8ZUagQfOVe9H3lIF0r/xJPJk
Yod/gUKJycZ2Chr2i2B1UDaEAF14R5XpnCNg8N8JFQQn+oyw44xPz5eWlM/GG0/j
rybMFQKrrAkx65ALpDaWtBSt9Vi2GwV1y2x3rz++xwJomRbN9PPmyLR/G3yAo95k
TOPgghUbBlBnJQbHRYK0
=D4sh
-END PGP SIGNATURE-

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



Re: [S2] Trouble getting started

2015-09-27 Thread Yaragalla Muralidhar
Hi Chris,
  I have not checked the DTD. But i got this idea from sample struts2 apps.
I dont think there will be a default value for the "name" attribute.

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Sun, Sep 27, 2015 at 9:35 PM, Christopher Schultz <
ch...@christopherschultz.net> wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA256
>
> Lucasz,
>
> On 9/27/15 12:02 PM, Christopher Schultz wrote:
> > On 9/27/15 10:08 AM, Lukasz Lenart wrote:
> >> 2015-09-26 23:30 GMT+02:00 Christopher Schultz
> >> :
> >>> I'm working on a fresh project and using Struts 2 for the
> >>> first time. I've been using Struts 1 for more than 10 years and
> >>> I generally know my way around web applications.
> >>>
> >>> I just can't seem to get a fairly simple setup working. I'm
> >>> intending to use XML-based configuration and not
> >>> annotation-based configuration.
> >
> >> The best option is to use one of Maven's archetypes
> >
> >> http://struts.apache.org/docs/struts-2-maven-archetypes.html#Struts2M
> a
> >
> >>
> venArchetypes-Quickstart
> >
> > Yeah...
> >
> > I was trying to avoid using Maven, which to me has too much opaque
> > hand-waving that I neither understand nor control.
> >
> > I have what I believe is a fairly simple test app at this point. I
> > should be able to get it to work without resorting to drastic
> > measures : )
> >
> >>> Here's what I've got:
> >>>
> >>> * Struts 2.3.24.1 * Tomcat 8.0.24 * A simple web app
> >>>
> >>> My web.xml looks like this:   Struts 2
> >>> action filter. 
> >>> struts2
> >>>
> >>> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareA
> n
> >
> >>>
> dEx
> >>>
> >>>
> > ecuteFilter
> >>>  actionPackages
> >>> my.package.business 
> >
> >> Not needed, it is useful only when using the Convention plugin
> >
> >>>  
> >>>
> >>>  struts2
> >>> /* 
> >>>
> >>> My struts.xml looks like this:
> >>>
> >>>   >>> PUBLIC "-//Apache Software Foundation//DTD Struts
> >>> Configuration 2.0//EN"
> >>> "http://struts.apache.org/dtds/struts-2.0.dtd;>
> >
> >> Wrong DTD, please use the latest one
> >
> >>  >> Struts Configuration 2.3//EN"
> >> "http://struts.apache.org/dtds/struts-2.3.dtd;>
> >
> > Yep, I updated to this one this morning, after trying to find out
> > the default value for the  "name" attribute. Still no
> > change.
> >
> >>>  
> >>>
> >>> 
> >>>  
> >>> /WEB-INF/list.jsp  
> >>> 
> >>>
> >>> I have a class, my.package.business.ListAction which has a
> >>>
> >>> public String execute()
> >>>
> >>> method. I return "success" from this method (unless an
> >>> exception is thrown). During startup, I can see that
> >>> Struts/XWork is being initialize d:
> >>>
> >>> 26-Sep-2015 17:19:32.613 FINE [localhost-startStop-1]
> >>> com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.de
> b
> >
> >>>
> ug
> >>>
> >>>
> > Loaded
> >>> list in 'default' package:{ActionConfig //list
> >>> (my.package.business.ListAction) - action -
> >>> file:/path/to/deploy/webapps/ROOT/WEB-INF/classes/struts.xml:
> >>> 9:68}
> >>>
> >>> When I try to access http://localhost:8080/list.action, I get
> >>> a 404 response with nothing in the logs (except the access
> >>> log: request to /list.action resulted in a 404).
> >>>
> >>> I'm sure I'm missing something super simple, here. Can anyone
> >>> offer a suggestion?
> >
> >> Are you sure that you have deployed your app as ROOT.war to
> >> $TOMCAT_HOME/webapps ?
> >
> > It's not deployed as a WAR, but as webapps/ROOT (exploded WAR
> > directory).
>
> For completeness, this is what is contained in my ROOT directory
> ("deploy" is my CATALINA_BASE for Tomcat):
>
> deploy/webapps/ROOT
> deploy/webapps/ROOT/WEB-INF
> deploy/webapps/ROOT/WEB-INF/classes
> deploy/webapps/ROOT/WEB-INF/classes/com
> deploy/webapps/ROOT/WEB-INF/classes/my/project
> deploy/webapps/ROOT/WEB-INF/classes/my/project/business
> deploy/webapps/ROOT/WEB-INF/classes/my/project/business/BaseAction.class
> deploy/webapps/ROOT/WEB-INF/classes/my/project/business/ListAction.class
> deploy/webapps/ROOT/WEB-INF/classes/struts.xml
> deploy/webapps/ROOT/WEB-INF/lib
> deploy/webapps/ROOT/WEB-INF/lib/commons-fileupload-1.3.1.jar
> deploy/webapps/ROOT/WEB-INF/lib/commons-io-2.2.jar
> deploy/webapps/ROOT/WEB-INF/lib/commons-lang3-3.2.jar
> deploy/webapps/ROOT/WEB-INF/lib/commons-logging-1.1.3.jar
> deploy/webapps/ROOT/WEB-INF/lib/commons-logging-api-1.1.jar
> deploy/webapps/ROOT/WEB-INF/lib/freemarker-2.3.22.jar
> deploy/webapps/ROOT/WEB-INF/lib/javassist-3.11.0.GA.jar
> deploy/webapps/ROOT/WEB-INF/lib/ognl-3.0.6.jar
> deploy/webapps/ROOT/WEB-INF/lib/struts2-core-2.3.24.1.jar
> deploy/webapps/ROOT/WEB-INF/lib/xwork-core-2.3.24.1.jar
> deploy/webapps/ROOT/WEB-INF/list.jsp
> deploy/webapps/ROOT/WEB-INF/web.xml
>
> Thanks,
> - -chris
> -BEGIN PGP SIGNATURE-
> Comment: GPGTools - http://gpgtools.org
>
> iQIcBAEBCAAGBQJWCBPJAAoJEBzwKT+lPKRYeJsP/AlAP3VoL16o2MTV3qau+zNQ
> 

Re: [S2] Trouble getting started

2015-09-27 Thread Lukasz Lenart
2015-09-27 7:38 GMT+02:00 Yaragalla Muralidhar :
> Hi Chris,
>
>Try the following.
>
>  
> 
>   /WEB-INF/list.jsp

"success" is the default result name so you can omit, it isn't required.


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

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



Re: [S2] Trouble getting started

2015-09-26 Thread Yaragalla Muralidhar
Hi Chris,

   Try the following.

 

  /WEB-INF/list.jsp

  

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Sun, Sep 27, 2015 at 3:00 AM, Christopher Schultz <
ch...@christopherschultz.net> wrote:

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA256
>
> All,
>
> I'm working on a fresh project and using Struts 2 for the first time.
> I've been using Struts 1 for more than 10 years and I generally know
> my way around web applications.
>
> I just can't seem to get a fairly simple setup working. I'm intending
> to use XML-based configuration and not annotation-based configuration.
>
> Here's what I've got:
>
> * Struts 2.3.24.1
> * Tomcat 8.0.24
> * A simple web app
>
> My web.xml looks like this:
>   
> 
>   Struts 2 action filter.
> 
> struts2
>
> org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndEx
> ecuteFilter
> 
>   actionPackages
>   my.package.business
> 
> 
>   
>
>   
> struts2
> /*
>   
>
> My struts.xml looks like this:
>
> 
>  Configuration 2.0//EN"
> "http://struts.apache.org/dtds/struts-2.0.dtd;>
>
> 
>   
>
>   
> 
>   /WEB-INF/list.jsp
> 
>   
> 
>
> I have a class, my.package.business.ListAction which has a
>
>   public String execute()
>
> method. I return "success" from this method (unless an exception is
> thrown). During startup, I can see that Struts/XWork is being initialize
> d:
>
> 26-Sep-2015 17:19:32.613 FINE [localhost-startStop-1]
> com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.debug
> Loaded
> list in 'default' package:{ActionConfig //list
> (my.package.business.ListAction) - action -
> file:/path/to/deploy/webapps/ROOT/WEB-INF/classes/struts.xml:
> 9:68}
>
> When I try to access http://localhost:8080/list.action, I get a 404
> response with nothing in the logs (except the access log: request to
> /list.action resulted in a 404).
>
> I'm sure I'm missing something super simple, here. Can anyone offer a
> suggestion?
>
> Thanks,
> - -chris
> -BEGIN PGP SIGNATURE-
> Comment: GPGTools - http://gpgtools.org
>
> iQIcBAEBCAAGBQJWBw6LAAoJEBzwKT+lPKRYKAoP/jgtaBdgRYCAKvXlEagne5OM
> RHF+M5jqdzfmpCnEe1071DEAD7Q4wcVtKvkjaYKIczvnfx0ppPShhyE8514Ez+yB
> L7nDw+YunCeZzhAk5KlaDb1piL27r1VrYQ30W9FQTrG2FQc56XW9CEAYz1rOJbZA
> YlzCDWiQPgac/68NLVn2YAO5d+Mf6FBHk20EnMMxp5disRpBSsIiPvpxZQmS0c/k
> eXAJMNFhHeVoUcTWHJGGnM1efV8dKvOXrLgHRPTf3Nts+cIpwRVD2iu70AwjGhdI
> PeNYPb3QMfPJz0PjTTeK418mOa1CMAdUm1O9NqG2dYxdL+/5tlyCC1GsooHtroTp
> gTn8mrQH9FWw87sgw4IL6nEP5x5zFEZJq1NOMOvSQY12in08AAdVFO1XJeAZzhS/
> c1IVrW+zGYGWSra6njGS3uZUDiYOhomSsAkjjNz5G3yjerz6MSCr/rg8cHGnXBdN
> e5eiZhmjfMTewhEsH5IuZKGmtJWPaTwMl9lYtrOMpPX5c4ela0tMluhRocttDKgk
> jlegJsJeaetfMNY66g6kfKCB4DHLeQrghjPWh7Ue5gL611bXYSPZAG58jYzPF+cq
> cR43Qluc1ukaOq/VdnqpYAMQ3pL1kUQDIuYVPOLN6C1YpEFb4o7WiFJbgzoQzJEl
> cQi/KlhVmXmRCFA1qkXH
> =SyBg
> -END PGP SIGNATURE-
>
> -
> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
> For additional commands, e-mail: user-h...@struts.apache.org
>
>