Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Struts 2.1.6 filter startup problem

 
Lynn Keeling
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I recently ran into a problem with Struts 2.0.11.2 but discovered the problem had been fixed in 2.1.6 so I started upgrading. Little did I know that annotation handling had chnaged so dramatically. I converted my code to use the new conventions plugin but now the filter won't start. I've gone as far as commenting out all of my annotations and the exception still gets thrown. Anyone else seen this error before?

SEVERE: Exception starting filter struts2
java.lang.ArrayIndexOutOfBoundsException: 0
at org.apache.struts2.convention.SEOActionNameBuilder.build(SEOActionNam
eBuilder.java:69)
at org.apache.struts2.convention.PackageBasedActionConfigBuilder.determi
neActionName(PackageBasedActionConfigBuilder.java:601)
at org.apache.struts2.convention.PackageBasedActionConfigBuilder.buildCo
nfiguration(PackageBasedActionConfigBuilder.java:445)
at org.apache.struts2.convention.PackageBasedActionConfigBuilder.buildAc
tionConfigs(PackageBasedActionConfigBuilder.java:278)
at org.apache.struts2.convention.ClasspathPackageProvider.loadPackages(C
lasspathPackageProvider.java:52)
at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContai
ner(DefaultConfiguration.java:200)
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(
ConfigurationManager.java:55)
at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Di
spatcher.java:360)
at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:403)

here is my filter setup. nothing special. it worked fine before:

<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
<init-param>
<param-name>actionPackages</param-name>
<param-value>com.nexus.portal.ctrl.action</param-value>
</init-param>
</filter>

<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>



 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Did you follow the directions for Converting a Codebehind based application to Convention? I'd start there, there's a bit more at Converting application from Codebehind to Convention Plugin.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic