Erreur lors de l'execution de l'application login en j2ee

rourou0405 Messages postés 1 Date d'inscription mardi 21 décembre 2010 Statut Membre Dernière intervention 9 janvier 2011 - 9 janv. 2011 à 18:01
mahercapone Messages postés 1 Date d'inscription lundi 8 novembre 2010 Statut Membre Dernière intervention 13 mars 2012 - 13 mars 2012 à 23:20
st, je suis débutante en j2ee, je fais un projet de fin d'étude. j'ai crée la première interface d'authentification, mais lors du click sur le bouton se connecter pour passer à la page suivante une erreur s'éproduit, j'ai pas compris la cause de cet erreur.
9 janv. 2011 17:48:54 com.opensymphony.xwork2.util.logging.commons.CommonsLogger warn
ATTENTION: No configuration found for the specified action: 'saisirLogin' in namespace: ''. Form action defaulting to 'action' attribute's literal value.
9 janv. 2011 17:48:54 com.opensymphony.xwork2.util.logging.commons.CommonsLogger warn
ATTENTION: No configuration found for the specified action: 'saisirLogin' in namespace: ''. Form action defaulting to 'action' attribute's literal value.

voila mon fichier struts:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE struts PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
"http://struts.apache.org/dtds/struts-2.0.dtd">

<struts>
<constant name="struts.enable.DynamicMethodInvocation" value="false" />
<constant name="struts.devMode" value="true" />


<default-action-ref name="Login"/>


<result name="error" type="redirectAction">Login.jsp</result>
<result name="success" type="redirectAction">/client/Loginsuccess.jsp</result>



</struts>
et voila mon fichier web.xml
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
id="WebApp_ID" version="2.5">
<display-name>ProjetStruts</display-name>
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>struts2</filter-name>
/*
</filter-mapping>
<welcome-file-list>
<welcome-file>Login.jsp</welcome-file>
</welcome-file-list>
</web-app>

à noter que les bibliothètes sont bien charger. j'attend vos aides svp merci d'avance.

2 réponses

abdellahrah Messages postés 7 Date d'inscription jeudi 7 février 2013 Statut Membre Dernière intervention 9 janvier 2012
9 janv. 2012 à 17:34
bonjour,
c'est normal qu'il donne cette erreur par ce qu'il ne trouve pas l'action par defaut "Login" que tu as déja définie <default-action-ref name="Login"/>. tu doit créer l'action :

<result>Login.jsp</result>

le type="redirectAction" il faut le mettre si tu as besoin d'un redirection vers une action. bon voila j'ai corrigé le fichier struts.xml et web.xml:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE struts PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
"http://struts.apache.org/dtds/struts-2.0.dtd">
<struts>
<constant name="struts.enable.DynamicMethodInvocation" value="false" />
<constant name="struts.devMode" value="false" />

<default-action-ref name="Login"/>

<result name="error" >Login.jsp</result>
<result name="success" >/client/Loginsuccess.jsp</result>



</struts>

et le web.xml :
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_ID" version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
<display-name>
ProjetStruts</display-name>
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
</filter>
<filter-mapping>
<filter-name>struts2</filter-name>
/*
</filter-mapping>
</web-app>
ça doit marché voici mon mail pour plus d'information :
abdellah-rahmouni@hotmail.com
0
mahercapone Messages postés 1 Date d'inscription lundi 8 novembre 2010 Statut Membre Dernière intervention 13 mars 2012
13 mars 2012 à 23:20
SVP abdallah moi aussi g la mm exception mais j'ai deja definie toute les actions
exception : ATTENTION: No configuration found for the specified action: 'connection' in namespace: ''. Form action defaulting to 'action' attribute's literal value.
13 mars 2012 23:12:47 com.opensymphony.xwork2.util.logging.commons.CommonsLogger warn
ATTENTION: No configuration found for the specified action: 'connection' in namespace: ''. Form action defaulting to 'action' attribute's literal value.
...............................................
struts.xml
<struts>


<constant name="struts.enable.DynamicMethodInvocation" value="false" />
<constant name="struts.devMode" value="false" />







<result name="success">acceuil.jsp</result>
<result name="error">index.jsp</result>



<result name="success">ServersActions.jsp</result>
<result name="error">index.jsp</result>



<result name="success">ServersActions.jsp</result>
<result name="error">index.jsp</result>



<result name="success">ServersActions.jsp</result>
<result name="error">index.jsp</result>



<result name="success">ServersActions.jsp</result>
<result name="error">index.jsp</result>





</struts>
............................................................
web.xml :
<display-name>OpenstackClientEsprit</display-name>
<filter>
<filter-name>struts</filter-name>
<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>

actionPackages


com.mycompany.myapp.actions



</filter>

<filter-mapping>
<filter-name>struts</filter-name>
/*
</filter-mapping>


<welcome-file-list>

<welcome-file>index.jsp</welcome-file>

</welcome-file-list>


</web-app>
........................................................
je comprend pas d ou elle sort l exception!!!!!
0
Rejoignez-nous