Questions tagged [xwork]

XWork is a command-pattern framework that is used to power Struts 2 as well as other applications.

XWork is a command-pattern framework that is used to power as well as other applications.

XWork provides an Inversion of Control container, a powerful expression language, data type conversion, validation, and pluggable configuration.

http://www.opensymphony.com/xwork/

43 questions
2
votes
0 answers

Wildfly docker image ERROR [io.undertow.request] UT005023: Exception handling request to /app1/ Unable to load configuration. - Class: java.io.File

We have built an docker image of Wildfly jboss server and deploying the war file on the same. while running the image, deployment of war is getting successful without any error, but while hitting the url on the runtime name it is throwing an…
2
votes
1 answer

How to pass the object property as param to Struts custom validator

This is the custom validator, has getters/setters for countryCode public void validate(Object object) throws ValidationException { String fieldName = getFieldName(); Object zipObj = this.getFieldValue(fieldName, object); String country =…
Naveen
  • 124
  • 1
  • 14
2
votes
1 answer

Why Struts 2 annotations don't have LongRangeFieldValidator

I was working on validation using annotation in Struts2 and i was quite surprised to see that the annotations does not have a LongRangeFieldValidator where as the validations done using xml does have a LongRangeFieldValidator I tried different ways…
maxx777
  • 1,320
  • 1
  • 20
  • 37
2
votes
1 answer
1
vote
0 answers

Struts2 debug=browser does not capture url parameters in action class variables?

I have a very simple action class with one member variable "data". when I submit the normal url it shows value in tomcat console like:Test action data=hello public class ActionTest extends ActionSupport { private static final long serialVersionUID…
samarjit samanta
  • 1,285
  • 2
  • 16
  • 29
1
vote
2 answers

Struts 2 fails to initialize Dispatcher in executable war - Embedded Tomcat

I'm migrating a webapp from JBoss to Embedded Tomcat. It works on intellij but when I run the war file with java -jar myapplication.war it shows the following error. After googling I couldn't find any solution. This problem seems like I have two…
1
vote
1 answer

Java side validation (xwork2) does not work from input error page (Struts2)

I am using Struts2 with jsp pages and xwork validation. My problem is in java side validation, when I first land in input-page due to input errors and after that I leave those errors there and submit again. The very same errors should be shown but…
mico
  • 12,730
  • 12
  • 59
  • 99
1
vote
0 answers

Upgrading Struts from 2.3.16 to 2.3.31

Due to the recent security vulnerability identified in Struts, we are upgrading application from struts version 2.3.16 to 2.3.31. One of the major issues being the naming convention of getter and setter in Action classes. Example: For instance…
1
vote
1 answer

Can classes that extend Struts2/XWork ValidatorSupport have state

If you extend the ValidatorSupport class in Struts 2 can you have instance variables on the class? Can it have state or does it have to be stateless? I know action classes aren't singletons and can have state but I'm not sure about their associated…
Dan King
  • 1,080
  • 1
  • 11
  • 28
1
vote
1 answer

Field Error keys changing with Xwork upgrade to 2.0.6

I've upgraded Xwork from 2.0.4 to 2.0.6 (struts version is 2.0.11.1). The field validation is working correctly, however the keys for the errors are not. For example, I have a required field called profile.name.firstName. The field error key is…
l15a
  • 2,547
  • 5
  • 29
  • 41
1
vote
1 answer

Don't quite understand the mechanism of Dependancy Injection in Struts2 XWork

I'm new to IOC and learning from source code of Struts2 framework currently. Through learning, I've got some basic understanding of the framework like how ActionInvocation handlers interceptors etc. But when I was trying to figure out the…
du369
  • 821
  • 8
  • 22
1
vote
1 answer

The meaning of action's context in Interface ActionValidatorManager method validate

I wanted to use the following method for validation through XMLs on clientside. Can someone please tell me about the context of an action as said in the following method: Interface ActionValidatorManager: void validate(Object object, String context)…
1
vote
1 answer

Reusing a regex in XWork validator

Without making a new class and adding it as a validator type, I'd like to reuse some regular expressions in XWork. I cannot seem to find a tutorial online with the proper syntax. I'd like to change the following:
tzimnoch
  • 216
  • 1
  • 13
1
vote
0 answers

Struts Validation framework to compare two dates

I have a page where I enter Start Date and End Date. I need to validate that End Date should not be less than Start date for that I am trying to implement the same using Xwork Validator, but not Working. Below is the code
Kumar
  • 1,106
  • 4
  • 15
  • 33
1
vote
1 answer

Is there any difference in com.opensymphony.xwork2.inject.Container Class between version 2.3.15.3 to 2.3.16

I think in Earlier version(before 2.3.16) org.springframework.jms.listener.SimpleMessageListenerContainer can cast to com.opensymphony.xwork2.inject.Container. After it it give following error.... org.springframework.beans.TypeMismatchException:…
Jothy
  • 31
  • 5
1
2 3