JSF - spring - hibernate and session

Hi,
I'm currently using hibernate spring and JSF
1/ the first problem
In the JSF common header page I try to test if a bean is in the session scope in order to show login or logout link, and the test always fails : the logout link is always displayed.
the JSF page :
<f:subview id="header" >
    <h:form id="headerForm">
        <table cellspacing="0" width="100%">
    <tr>
        <td align="left" valign="middle">
              <a href="front.jsf"><img border="0" src="images/logo1.jpg"/></a>
        </td>
    <td align="right" valign="middle"> <br>
   <!--<a href="front.jsf" rendered="#"> Accueil<</a> -->
    <c:choose>
                <c:when test="${empty sessionScope.accountBean}">
                    <h:commandLink action="Sign on">
                        <h:outputText value="Sign on"/>
                    </h:commandLink>  
                </c:when>
                <c:otherwise>
                    <h:commandLink id ="logout" action="#{accountBean.logoutAction}" >
                         <h:outputText value="log out"/>
                    </h:commandLink>
               </c:otherwise>
            </c:choose>
        </td>
    </tr>
</table>
<table cellspacing="0" width="100%">
    <tr>
        <td>
            <hr color="#99ca3c"  size="5" noShade SIZE=1>
        </td>
    </tr>
</table>
     </h:form>
</f:subview>The accountBean code :
public class AccountBean extends BaseBean{
//private Logger log = Log.getLog(this);
    private String uid;
    private String password;
    private boolean loggedIn;
    private AdminService adminService;
    private Admin admin;
    public AccountBean() {
        this.logger.debug("Authentication");
        this.loggedIn = false;
        uid=null;
        password=null;
       // admin=new Admin();
public String loginAction() {
          try {
                    this.logger.debug("loginAction");
                     admin = adminService.login(this.uid, this.password);
                                //this.serviceLocator.getUserService().login(this.username, this.password);
               if (admin != null) {
                            if("".equals(admin.getUid())|| "".equals(admin.getPassword())){
                             this.loggedIn=false;
                                String msg = "Le mot de passe et l'identifiant doivent etre saisis ";
                    addErrorMessage(msg + ", saississez un mot de passe et un identifiant corrects");
                             return NavigationResults.RETRY;
                            else{
                    this.loggedIn = true;
                                HttpSession session = SessionUtil.getSession();
                                session.setAttribute("Admin", this.uid);
                    return NavigationResults.SUCCESS;
               else {
                    this.loggedIn = false;
                    String msg = "Le mot de passe est incorrect ";
                    addErrorMessage(msg + ", saississez un mot de passe correct");
                    this.logger.debug(msg);
                    return NavigationResults.RETRY;
          catch (UsernameNotExistException ue) {
               String msg = "L'identifiant (login) est incorrect";
               this.logger.info(msg);
               addErrorMessage(msg + ", ressaysissez votre identifiant.");
               return NavigationResults.RETRY;
          catch (Exception e) {
               this.logger.error("Could not log in user.", e);
               addInfoMessage("Could not log in user: Internal Error");
               return NavigationResults.FAILURE;
      * The backing bean action to logout a user.
      * @return the navigation result
     public String logoutAction() {
          //this.clear();
           FacesContext fc = FacesContext.getCurrentInstance();
           HttpSession session = (HttpSession) fc.getExternalContext().getSession(false);
           session.invalidate();
          this.logger.debug("Logout successfully.");
          return NavigationResults.MAIN;
    public String getPassword() {
        return password;
    public void setPassword(String password) {
        this.password = password;
    public String getUid() {
        return uid;
    public void setUid(String uid) {
        this.uid = uid;
    public Admin getAdmin() {
        return admin;
    public boolean getLoggedIn() {
        return loggedIn;
    public void setLoggedIn(boolean loggedIn) {
        this.loggedIn = loggedIn;
    public void setAdminService(AdminService adminService) {
        this.adminService = adminService;
}the faces managed bean configuration
<managed-bean-name>accountBean</managed-bean-name>
    <managed-bean-class>fr.cbmjadmin.views.bean.AccountBean</managed-bean-class>
    <managed-bean-scope>session</managed-bean-scope>
    <managed-property>
     <property-name>adminService</property-name>
            <value>#{adminService}</value>
    </managed-property>2/ the second problem :
my application shows a list of datas.
I log on the application , i update this list outside the application ( by using sql command) , i try to list my data using the application : the application does not reflect the modifications. I logout using the log out link, then i log on and the application does not reflect the modifications.
what happens?
How could I resove these problems.
How can i logout properly?
how can i show logout link when the user is logged in? and hide the log out link when the user is logout
Thanks.

It depends on how you want to reprecate the session btwn instances or cluters
there are three kinds File System, Memory to Memory, HA
You can configure it from this property in the admin console
Configuration on a cluster -> Availability Service -> Web Container Availability -> Persistence Type:

Similar Messages

  • Jsf spring hibernate session

    Hi, I'm currently using hibernate spring and JSF  1/ the first problem In the JSF common header page I try to test if a bean is in the session scope in order to show login or logout link, and the test always fails : the logout link is always displayed.  the JSF page : [code] <f:subview id="header" >        <h:form id="headerForm"> <table cellspacing="0" width="100%"> <tr> <td align="left" valign="middle">           <img border="0" src="images/logo1.jpg"/> </td>  <td align="right" valign="middle"> <br> <!--Accueil< -->  <c:choose> <c:when test="${empty sessionScope.accountBean}">  <h:commandLink action="Sign on"> <h:outputText value="Sign on"/> </h:commandLink>  </c:when> <c:otherwise> <h:commandLink id ="logout" action="#{accountBean.logoutAction}" >      <h:outputText value="log out"/> </h:commandLink> </c:otherwise> </c:choose> </td> </tr> </table>  <table cellspacing="0" width="100%"> <tr> <td> <hr color="#99ca3c" size="5" noShade SIZE=1> </td> </tr> </table>       </h:form> </f:subview>   [/code]   The accountBean code : [code] public class AccountBean extends BaseBean{ //private Logger log = Log.getLog(this); private String uid; private String password;  private boolean loggedIn; private AdminService adminService; private Admin admin; public AccountBean() { this.logger.debug("Authentication"); this.loggedIn = false; uid=null; password=null; // admin=new Admin(); } public String loginAction() {           try { this.logger.debug("loginAction");  admin = adminService.login(this.uid, this.password); //this.serviceLocator.getUserService().login(this.username, this.password);                                if (admin != null) { if("".equals(admin.getUid())|| "".equals(admin.getPassword())){ this.loggedIn=false; String msg = "Le mot de passe et l'identifiant doivent etre saisis ";                     addErrorMessage(msg + ", saississez un mot de passe et un identifiant corrects"); return NavigationResults.RETRY; } else{                     this.loggedIn = true; HttpSession session = SessionUtil.getSession(); session.setAttribute("Admin", this.uid);                                          return NavigationResults.SUCCESS; }                }                else {                     this.loggedIn = false;                                          String msg = "Le mot de passe est incorrect ";                     addErrorMessage(msg + ", saississez un mot de passe correct");                     this.logger.debug(msg);                                          return NavigationResults.RETRY;                }           }           catch (UsernameNotExistException ue) {                String msg = "L'identifiant (login) est incorrect";                this.logger.info(msg);                addErrorMessage(msg + ", ressaysissez votre identifiant.");                                return NavigationResults.RETRY;           }           catch (Exception e) {                this.logger.error("Could not log in user.", e);                addInfoMessage("Could not log in user: Internal Error");                                return NavigationResults.FAILURE;           }      }            /**      * The backing bean action to logout a user.      *       * @return the navigation result      */      public String logoutAction() {           //this.clear(); FacesContext fc = FacesContext.getCurrentInstance(); HttpSession session = (HttpSession) fc.getExternalContext().getSession(false); session.invalidate();            this.logger.debug("Logout successfully.");                      return NavigationResults.MAIN;      }        public String getPassword() { return password; }  public void setPassword(String password) { this.password = password; }  public String getUid() { return uid; }  public void setUid(String uid) { this.uid = uid; }  public Admin getAdmin() { return admin; }   public boolean getLoggedIn() { return loggedIn; }  public void setLoggedIn(boolean loggedIn) { this.loggedIn = loggedIn; }  public void setAdminService(AdminService adminService) { this.adminService = adminService; }   }    [/code]  the faces managed bean configuration [code] <managed-bean-name>accountBean</managed-bean-name> <managed-bean-class>fr.cbmjadmin.views.bean.AccountBean</managed-bean-class> <managed-bean-scope>session</managed-bean-scope> <managed-property>      <property-name>adminService</property-name> <value>#{adminService}</value> </managed-property>    [/code] 2/ the second problem : my application shows a list of datas. I log on the application , i update this list outside the application ( by using sql command) , i try to list my data using the application : the application does not reflect the modifications. I logout using the log out link, then i log on and the application does not reflect the modifications.  what happens? How could I resove these problems. How can i logout properly? how can i show logout link when the user is logged in? and hide the log out link when the user is logout Thanks.

    For the first problem, you need to realize that the accountBean always exists since you configured it in the faces-config.xml. So you should use something else (like a property on the bean) to determine if the user has actually logged in.
    Secondly, but still on the first issue, it is preferable to use the rendered attribute on the standard JSF components in this situation, instead of the JSTL tags.
    Now, as to the second problem, there are a number of possibilities:
    - did you commit the changes to the database?
    - did you verify that another connection with the native db client can see the changes?
    - are you using a cache with Hibernate? Are you taking the proper steps to notify the cache it might have stale data?
    - are you keeping the list in session scope in your application? (Logging out doesn't clear the session unless you explicitly code it that way.)

  • Help me out with Directory structure for JSF+SPRING+HIBERNATE Project

    Hi frnds ,
    My name is Walter working for a startup software company . We are working on Hospital Management System (HMS) project .. MVC Architecture ...using Hibernate Spring and JSF ..we need to design Directory Structure for our project..
    plzz help me friends in suggesting MVC Directory structure ...? also plzz help me by directing me with the navigation flow?
    Thnxx in advance
    Regards
    Walter

    Thank you so much .. friends ..for your kind replies..thanks to Illu, anguquga and special thanks to BalusC for giving me the advice for hiring EE Artitech ..
    Anyways I have discussed with my teammates designing the directory structure
    anguquga your directory structure is close to what I have designed ..referiing to a sample application on web..
    Hospital Management system MVC architecture Directory structure
    This is the way the structure goes on ..
    model --> for Hibernate as well as Spring
    View --> for JSF
    src(-)
    |
    ------(-) java
         |
         -------(-) model
              |
              ------(+) businessobject
              |
              ------(-) dao
              |
              ------(+) hibernate
              |
              ------(+) exception
              |
              ------(-) service
              |
              ------ (+) impl
              |
              ------(+) util
              (-) view
              |
              ------(+) bean
              |
              ------(+) builder
              |
              ------(+) bundle
              |
              ------(+) servicelocator
              |
              ------(+) util
              |
              ------(+) validator
    (-) Web or WebRoot
    |
    ----- (-) JSP Files�etc.,
    |
    ----- (-) META-INF
    |
         ------     (+) Images
    |
         ------     (+) Scripts ==== CSS (cascading style sheets, JavaScript files etc.,)
    |
    ----- (-) WEB-INF =========xml files web.xml, faces-config.xml etc.,
         |
         -----(-) Classes
              |
    -----(-) HMS
    |
                   ----- (+) model
                   |
                   ----- (+) view
    |
    ----- (+) lib
    I am sure you may notice few errors .. if u find any plzz reply me back.... thnxx in advance for replies...and thnxx for giving your valuable replies...
    Walter (Kaleem)

  • URGENT methode parametres JSF+ SPRING +HIBERNATE

    hello all the world I'm back
    help me plz :
    I want to search an employee from his number I use a search function (String number), I recalled your JSF + hibernate + spring so I'll post the code :
    code of jsp page
    <f:view>
              <h:form id="RechercheEmp">
                   <h:panelGrid columns="2">
                        <h:outputText  value="Entre le Matricule de l'employ� : "/>                    
                        <h:inputText  id="mat" value="#{todoBean.employes.matricule}"/>                    
                    <h:commandButton value="Submit" action="#{todoBean.chercherEmployer?matricule=mat}"/>
                   </h:panelGrid>
                   </h:form>
    </f:view>and code of bean JSF :
    public String chercherEmployer(String matricule) {
            log.debug("#DDD############ createemployesAction()");
            try {
                this.toDoService.chercherToDo(matricule);
                log.debug("#DDD############ checheremployesAction->success");
                return "success";
            } catch (JoTestException e) {
                e.printStackTrace();
                return "failure";
    }in layer service :
    public void chercherToDo(String matricule) throws JoTestException {
            log.debug("#DDD############ saveToDo(toDo) in Service TODO");
            toDoDao.chercherToDo(matricule);
    }and in the layer dao :
    public void chercherToDo(String matricule){
              log.debug("#DDD######### Savetodo in todoDAO : ");
              this.getHibernateTemplate().load(Employes.class, matricule);
    }but i have this probleme :
    javax.servlet.ServletException: #{todoBean.chercherEmployer?matricule=ma'}: javax.faces.el.MethodNotFoundException: chercherEmployer?matricule='mat': jotodo.gui.bean.ToDoBean.chercherEmployer?matricule='mat'()
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:209)
    cause m�re
    javax.faces.FacesException: #{todoBean.chercherEmployer?matricule=mat}: javax.faces.el.MethodNotFoundException: chercherEmployer?matricule='mat': jotodo.gui.bean.ToDoBean.chercherEmployer?matricule='mat'()
         com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
         javax.faces.component.UICommand.broadcast(UICommand.java:312)
         javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:267)
         javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:381)
         com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:75)
         com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:90)
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)
    note La trace compl�te de la cause m�re de cette erreur est disponible dans les fichiers journaux de Apache Tomcat/5.5.20.
    Apache Tomcat/5.5.20

    i changed my page jsp to this :
    <f:view>
              <h:form id="RechercheEmp">
                        <h:outputText  value="Entre le Matricule de l'employ� : "/>                    
                        <h:inputText  id="mat1" value="" />                    
                        <h:commandLink action="#{todoBean.chercherEmployer}">
                          <h:outputText value="Chercher" />
                          <f:param name="mat1" value="#{todoBean.employes.matricule}"/>
                        </h:commandLink>
                   </h:form>
    </f:view>is correct or no ?????????
    but i get again the same error :
    exception
    javax.servlet.ServletException: #{todoBean.chercherEmployer}: javax.faces.el.MethodNotFoundException: chercherEmployer: jotodo.gui.bean.ToDoBean.chercherEmployer()
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:209)
    cause m�re
    javax.faces.FacesException: #{todoBean.chercherEmployer}: javax.faces.el.MethodNotFoundException: chercherEmployer: jotodo.gui.bean.ToDoBean.chercherEmployer()
         com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
         javax.faces.component.UICommand.broadcast(UICommand.java:312)
         javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:267)
         javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:381)
         com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:75)
         com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:90)
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)Edited by: Maq_Ichigo on Apr 29, 2008 3:09 AM
    Edited by: Maq_Ichigo on Apr 29, 2008 3:19 AM

  • JSF, Springs and Hibernate

    Hi,
    I am a newbie. I would like to know the books i need to refer to, inorder to learn JSF, springs and hibernate.
    Thank you,

    The_Matrix wrote:
    CeciNEstPasUnProgrammeur wrote:
    How about learning Java first?
    At least for JSPs, there are free online tutorials from Sun. There are likely to be similar resources for Spring and Hibernate.I Know Java. I am a Sun Certified Java Programmer. I also know know J2EE. I am trying to learn the new technologies. Therefore i mentioned that i am a newbie, it was pertianing to JSF, Springs and Hibernate. Not to Java.In that case:
    Core Java Server Faces (2nd edition)
    Java Persistence with Hibernate
    Pro Spring 2.5
    Expert Spring MVC and Web Flow
    Together with the product documentation those should make a decent bit of reading.

  • Training material on JSF, Spring and Hibernate

    Hi All,
    I'm new to JSF. I need some good training material on JSF, Spring and Hibernate.
    I've tried lot many tutorials online, but cannot find a real good one.
    Also I need to learn how we can integrate together JSF, Spring and Hibernate to build web applications.
    Thanks
    Payal

    As far as documentation vs examples, that depends on the individual.
    The Spring documentation is quite large, but Spring itself is very modular. So you can pretty much get away with reading the pieces you need when you need them and ignoring the rest.
    Start with inversion of control until you feel you understand the concept. At its core, the idea is simple. Suppose you have a business class, FooService, and it needs to utilize BarService to implement its business logic. The non-Spring way would be to have the FooService class be responsible for getting an instance of BarService. The Spring way is for FooService to have a setter to be given an instance of BarService:
    public class FooServiceImpl implements FooService
        private BarService barService;
        public void setBarService(BarService barService) { this.barService = barService; }
    }Then the Spring container is used to "wire together" the instances:
    <beans>
        <bean id="barService" class="BarServiceImpl" />
        <bean id="fooService" class="FooServiceImpl">
            <property name="barService" ref="barService" />
        </bean>
    </beans>Note the advantage when using the classes in different contexts, e.g. unit testing vs production.
    If I were you, I would take the sample app you have already done with JSF and try to integrate Spring into it. Move all the business logic into beans in the Spring container while keeping the view logic in the JSF layer.

  • Integrate Crystal Reports with Spring MVC and Hibernate

    Hi all,
    having successfully used the JRC version 11.8.4.1094 in a Java environment with:
    1)JBoss 4.2.3,
    2)Oracle 11,
    3)EJB 2,
    4)Crystal Reports 2008,
    I would like to integrate Crystal Reports into my existing spring MVC and hibernate web app using:
    1)CRJ version 12.2.209,
    2)JBoss 5.1,
    3)Oracle 11,
    4)EJB 3,
    5)Crystal Reports 2008,
    reusing code integration. I used ReportExportControl and I produced the PDF directly.
    The error occurs when returning from EJB, into Delegate, and is the following:
    09:36:23,046 WARN  [InterceptorsFactory] EJBTHREE-1246: Do not use InterceptorsFactory with a ManagedObjectAdvisor, InterceptorRegistry should be used via the bean container
    09:36:23,062 WARN  [InterceptorsFactory] EJBTHREE-1246: Do not use InterceptorsFactory with a ManagedObjectAdvisor, InterceptorRegistry should be used via the bean container
    09:38:03,062 ERROR [[dispatcher]] Servlet.service() for servlet dispatcher threw exception
    java.lang.InstantiationException: com.crystaldecisions.sdk.occa.report.exportoptions.ReportExportFormat
         at java.lang.Class.newInstance0(Class.java:340)
         at java.lang.Class.newInstance(Class.java:308)
         at org.jboss.serial.classmetamodel.ClassMetaData.newInstance(ClassMetaData.java:334)
         at org.jboss.serial.persister.RegularObjectPersister.readData(RegularObjectPersister.java:239)
         at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.readObjectDescriptionFromStreaming(ObjectDescriptorFactory.java:412)
         at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.objectFromDescription(ObjectDescriptorFactory.java:82)
         at org.jboss.serial.objectmetamodel.DataContainer$DataContainerInput.readObject(DataContainer.java:845)
         at org.jboss.serial.persister.RegularObjectPersister.readSlotWithFields(RegularObjectPersister.java:353)
         at org.jboss.serial.persister.RegularObjectPersister.defaultRead(RegularObjectPersister.java:273)
         at org.jboss.serial.persister.RegularObjectPersister.readData(RegularObjectPersister.java:241)
         at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.readObjectDescriptionFromStreaming(ObjectDescriptorFactory.java:412)
         at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.objectFromDescription(ObjectDescriptorFactory.java:82)
         at org.jboss.serial.objectmetamodel.DataContainer$DataContainerInput.readObject(DataContainer.java:845)
         at org.jboss.serial.persister.RegularObjectPersister.readSlotWithFields(RegularObjectPersister.java:353)
         at org.jboss.serial.persister.RegularObjectPersister.defaultRead(RegularObjectPersister.java:273)
         at org.jboss.serial.persister.RegularObjectPersister.readData(RegularObjectPersister.java:241)
         at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.readObjectDescriptionFromStreaming(ObjectDescriptorFactory.java:412)
         at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.objectFromDescription(ObjectDescriptorFactory.java:82)
         at org.jboss.serial.objectmetamodel.DataContainer$DataContainerInput.readObject(DataContainer.java:845)
         at org.jboss.serial.io.MarshalledObjectForLocalCalls.get(MarshalledObjectForLocalCalls.java:60)
         at org.jboss.ejb3.remoting.IsLocalInterceptor.invokeLocal(IsLocalInterceptor.java:101)
         at org.jboss.ejb3.remoting.IsLocalInterceptor.invoke(IsLocalInterceptor.java:72)
         at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
         at org.jboss.aspects.remoting.PojiProxy.invoke(PojiProxy.java:62)
         at $Proxy286.invoke(Unknown Source)
         at org.jboss.ejb3.proxy.impl.handler.session.SessionProxyInvocationHandlerBase.invoke(SessionProxyInvocationHandlerBase.java:207)
         at org.jboss.ejb3.proxy.impl.handler.session.SessionProxyInvocationHandlerBase.invoke(SessionProxyInvocationHandlerBase.java:164)
         at $Proxy284.getXXXX(Unknown Source)
         at xx.xxx.xxxxxx.spring.manager.report.ReportManagerImpl.getXXXX(ReportManagerImpl.java:26)
         at xxx.xxxx.springprova.WelcomeController.handleRequestInternal(WelcomeController.java:70)
         at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
         at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48)
         at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:790)
         at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:719)
         at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:644)
         at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:549)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
         at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
         at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
         at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
         at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
         at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
         at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
         at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
         at java.lang.Thread.run(Thread.java:662)
    Have an idea, please?
    Thank you.

    You'll need to install the Crystal .NET that comes with VS 2005. You then install Crystal XI R2 over the top and not only will Crystal be integrated with the IDE, it should use the updated assemblies from R2.
    -Dell
    - A computer only does what you told it to, not what you thought you told it to!</p>

  • Spring hibernate JSF 2.0 Application

    I am trying to deploy application developed using this tutorial http://www.myeclipseide.com/documentation/quickstarts/ME4STutorialScaffoldingJSF/scaffoldingjsfarticle.html to weblogic server and running into all kinds of problem with configuration issues with hiberante properties and persistence.xml files , i was wondering if anybody has links to tutorial or sample project using spring / jsf 2.0 and hibernate developed in jdeveloper
    the sample application works fine in tomcat , not sure how to configure this to weblogic server . trying to rebuild the app in jdeveloper and having problems deploying . my latest error is
    Caused By: org.hibernate.HibernateException: The chosen transaction strategy requires access to the JTA TransactionManager
    if somebody can help me with configurion parameters to connect weblogic server instalation ( ideally to the integratedweblogic server started from jdeveloper) from myeclipseide , that would help as well
    Regards

    Here is an example that concerns running JSF2.0 (it uses NetBeans but you can probably adopt it in JDeveloper as well)
    From the post:
    "You can see that the library reference in weblogic.xml corresponds to the version of the JSF 2.0 JAR that you activated in the Frameworks pane of the New Project wizard."
    <?xml version="1.0" encoding="UTF-8"?>
    <weblogic-web-app xmlns="http://www.bea.com/ns/weblogic/90" xmlns:j2ee="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.bea.com/ns/weblogic/90 http://www.bea.com/ns/weblogic/90/weblogic-web-app.xsd">
      <context-root>/WebLogicCustomer</context-root>
      <library-ref>
          <library-name>jsf</library-name>
          <specification-version>2.0</specification-version>
          <implementation-version>1.0.0.0_2-0-2</implementation-version>
          <exact-match>true</exact-match>
      </library-ref>
    </weblogic-web-app>The example uses a libary reference. The library is located: $WL_HOME/common/deployable-libraries/jsf-2.0.war

  • ANNOUNCE: JSF Summit 2009: New Workshops and Sessions

    We're less than two months away from the 2nd annual JSF Summit conference, co-sponsored by JSFCentral and the No Fluff Just Stuff Symposiums. The conference will take place December 1st-4th in warm, sunny Orlando, FL.
    We already have an all-star lineup of speakers such as Ed Burns, Matthias Wessendorf, Dan Allen, Ted Goddard, Keith Donald, David Geary and several others, covering every aspect of JSF 2.0 plus JSF 1.x, Seam, MyFaces, ICEfaces, Trinidad, Spring/JSF integration, Comet, Portlets, JSR 299, testing, and more.
    But Jay Zimmerman and I wanted to make the show even better, so I'm happy to announce two full-day workshops on Seam and JSF 1.x, and several new sessions covering RichFaces, JSR 299, PrimeFaces, amd more.
    Read more here: http://weblogs.java.net/blog/kito75/archive/2009/10/13/jsf-summit-2009-new-workshops-and-sessions

    The Oracle related ones will probably available for download via the content builder etc shortly.
    Mine can be seen here http://www.slideshare.net/MGralike , but you will not be able to download them (although maybe you are allowed via the Oracle content builder part). The reasons regarding them (aka mine) to be on "seen only", are that there went a lot of work and stress into them, the topics are not always clear if you weren't their (mostly slides with only pictures) so I want it to be in the right context and/or my company paid for the time making them (so I am only the representative on this on behalve of them).
    If you have a valid reason that you me really need them then you could always drop me a line.

  • Reg. JSF Spring Integration issue.

    Hi All,
    I am using JSF for the front end and using the Spring Core, DAO and AOP for the BO and DAO layers. When i try to inject the Objects using the DI to the JSF, i am getting the following error and the objects are not getting set from the Spring.
    Error Log:*
    javax.servlet.ServletException: Unable to create managed bean dataUploadControllerBean. The following problems were found:
    - Bean or property class #{dataUploadVO} for managed bean dataUploadControllerBean cannot be found.
    - Bean or property class #{dataUploadVO} for managed bean dataUploadControllerBean cannot be found.
    - Bean or property class #{dataUploadVO} for managed bean dataUploadControllerBean cannot be found.
    javax.faces.webapp.FacesServlet.service(FacesServlet.java:325)
    org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:112)
    i have defined the respective entries correctly to integrate the JSF & Spring. But still the JSF&Spreing is not integrated successfully. Please find the configs defined and help to resolve the issue. i am stuck in this for 2 days...
    Web.xml
    <listener>
    <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    </listener>
    <context-param>
    <param-name>contextConfigLocation</param-name>
    <param-value>WEB-INF/applicationContext.xml</param-value>
    </context-param>
    Faces-Config.xml
    <application>
    <el-resolver>org.springframework.web.jsf.el.SpringBeanFacesELResolver</el-resolver> <!-- have used this ELResolver to injects objects from Spring-->
    </application>
    <managed-bean>
    <managed-bean-name>dataUploadControllerBean</managed-bean-name>
    <managed-bean-class>com.sgspace.model.dataupload.DataUploadControllerBean</managed-bean-class>
    <managed-bean-scope>session</managed-bean-scope>
    <managed-property>
    <property-name>dataUploadBean</property-name>
    <value>#{dataUploadBean}</value> _<!-- Already present in the faces-config.xml-->_ </managed-property>
    <managed-property>
    <property-name>dataUploadVO</property-name>
    <property-class>#{dataUploadVO}</property-class> _<!-- Injected from Spring DI. This is currently not working.-->_
    <value></value>
    </managed-property>
    <managed-property>
    <property-name>dataUploadBO</property-name>
    <property-class>#{dataUploadBO}</property-class>_<!-- Injected from Spring DI. This is currently not working.-->_ <value></value>
    </managed-property>
    </managed-bean>
    applicationContext.xml:_
    <beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:p="http://www.springframework.org/schema/p"
    xmlns:context="http://www.springframework.org/schema/context"
    xmlns:tx="http://www.springframework.org/schema/tx"
    xmlns:aop="http://www.springframework.org/schema/aop"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
    http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.0.xsd
    http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd
    http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd">
    <bean id="dataUploadDAO"
    class="com.sgspace.dao.dataupload.DataUploadDAOImpl">
    <property name="dataSource" ref="dataSource"></property>
    </bean>
    <bean id="dataUploadBO"
    class="com.sgspace.bo.dataupload.DataUploadBOImpl">
    <property name="dataUploadDAO" ref="dataUploadDAO"></property>
    </bean>
    <bean id="dataUploadVO" class="com.sgspace.vo.dataupload.DataUploadVO"></bean>
    </beans>
    Warm Regards,
    Praveen S

    The TestBean have a property for DeviceManager along with setter/getter methods as shown below. Sorry for not including in earlier posting
    TestBean.java (Backing Bean)
    private DeviceTypeManager deviceManager;
    public DeviceTypeManager getDeviceManager() {
         return deviceManager;
    public void setDeviceManager(DeviceTypeManager deviceManager) {
         this.deviceManager = deviceManager;
    Here are the two scenarios
    Scenario 1 : without <managed-property> the code works fine
    Scenario 2 : with <managed-property> the code results in following error
    javax.faces.FacesException: Cannot get value for expression '#{test.selectedDevice}'
    Scenario 1 has only JSF whereas Scenario 2 has JSF-Spring integration
    The Scenario 1 works absolutely fine as the expression '#{test.selectedDevice}' gets its value from setter/getter method in the backing bean(TestBean.java) . This is expected behaviour & wondering why it doesn't work similarly in Scenario 2 instead it complains
    Cannot get value for expression '#{test.selectedDevice}'
    I am willing to upload the war file. Any pointers/suggestions in resolving the error will be highly appreciated
    Regards
    Bansi

  • EJB annotations are not documented , versus Hibernate and JBoss seam do

    I have an application that contains EJB3 annotations, Hibernate Annotations and JBoss Seam annotations in the java code.
    When I generate the javadoc, the Hibernate and JBoss Seam annotations show by the side of the members and methods who has them, like, for example
    @Name(value="authenticator")
    @Scope(value=SESSION)
    @AutoCreate
    public class AuthenticatorImpl
    <dt>extends java.lang.Object </dt><dt>implements </dt>
    or, another example,
    h3. facesContext{noformat}@In(value="org.jboss.seam.faces.facesContext",
    create=true)
    private javax.faces.context.FacesContext facesContext{noformat}
    However, none of the EJB3 annotations included in the code are being dieplayed in the javadocs.
    Does someone knows if there is any reason why this should happen?
    This is my javadoc command:
    javadoc -version -d doc2 -sourcepath src\model;src\action -classpath "lib/core.jar;lib/jboss-embedded-api.jar;lib/jsr250-api.jar;classes/test;lib/hibernate.jar;lib/log4j.jar;lib/testng.jar;lib/ojdbc14.jar;lib/hibernate-commons-annotations.jar;lib/hibernate-search.jar;lib/hibernate-entitymanager.jar;lib/drools-compiler.jar;lib/richfaces-impl.jar;lib/jboss-cache.jar;lib/jboss-seam.jar;lib/janino.jar;lib/hibernate-annotations.jar;lib/richfaces-api.jar;lib/ejb-api.jar;lib/mvel14.jar;lib/jbosssx.jar;bootstrap;lib/jbpm-jpdl.jar;lib/commons-beanutils.jar;lib/lucene-core.jar;lib/jgroups.jar;lib/jsf-api.jar;lib/jboss-el.jar;lib/el-api.jar;lib/antlr-runtime.jar;lib/jstl.jar;classes/model;lib/antlr.jar;lib/persistence-api.jar;lib/jsf-facelets.jar;classes/action;lib/richfaces-ui.jar;lib/mail.jar;lib/drools-core.jar;lib/jboss-seam-debug.jar;lib/hibernate-validator.jar;lib/servlet-api.jar;lib/jta.jar" -private mil.navy.med.rota.model mil.navy.med.rota.security mil.navy.med.rota.action.util mil.navy.med.rota.action.util.mpd mil.navy.med.rota.action.mpd mil.navy.med.rota.action.referrals mil.navy.med.rota.model.referrals mil.navy.med.rota.action.trainman mil.navy.med.rota.model.trainman -use -version -author -splitindex
    The version of javadoc used is
    Standard Doclet 1.6.0.0_3
    Aticipated thanks!

    Nevermind, the issue was that my persistence.xml did not contain the following property:
    <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
    Therefore, the tables were not being created upon deployment.
    Still, I would expect to see entity beans listed in the WebLogic console.

  • FDS+Spring+Hibernate

    If any body has worked with FDS /Hibernate/Spring
    pls post the sample.
    regards
    anil

    The posts here that point to examples of Spring + FDS and
    separate examples of Hibernate + FDS and then say combining the two
    should be easy seem to be missing the point. This is not as easy an
    straight forward as it seems it should be.
    Spring + Hibernate + FDS is a completely different animal
    because you are getting Spring to handle the Session Factory
    configuration and your DAO's as Spring beans but you also want the
    handling of lazy initialization and proxy serialization as shown in
    the HibernateAssembler.
    The current HibernateAssembler code handles all of the
    Hibernate setup. I would much rather have Spring do this. What I
    would like is for my HibernateProxy's for non initialized
    associations to be serialized rather than traversed resulting
    LazyInitializationExceptions. The HibernateAssembler seems to
    tackle this with a very mysterious piece of code:
    PropertyProxyRegistry.getRegistry().register(HibernateProxy.class,
    new HibernatePropertyProxy());
    PropertyProxyRegistry and HibernatePropertyProxy are not
    documented anywhere, and in fact a Google on PropertyProxyRegistry
    returns 0 results. However, my intuition tells me this piece of
    code should tell serialization to proxy the HibernateProxy with a
    flex class called HibernatePropertyProxy which will just serialize
    an id of an association rather than attempting to serialize the
    uninitialized associated class.
    I cannot get this to work though and as there is no
    documentation and no discussion on these classes, I have no way of
    verifying it. If my intuition is correct, this is a very useful
    mechanism. I only wish it was documented b/c if it did work as
    expected it would make a Hibernate + Spring + FDS implementation
    pretty easy.
    Anyone know anything about this?

  • Mapping Problem using hibernate and annotations

    Hi,
    i am German student and new to hibernate. I established a mn conetction between to entities using hbm.xml mapping files. now I try to create the same connection applying annotations. unfortunately it does not work and I do not now why. First my error message followed by my classes and xml's:
    Initial SessionFactory creation failed.org.hibernate.AnnotationException: mappedBy reference an unknown target entity property: domain.Termin.person in domain.Person.termine
    Exception in thread "main" java.lang.ExceptionInInitializerError
    at services.HibernateUtil.sessionFactory(HibernateUtil.java:39)
    at services.HibernateUtil.getSessionFactory(HibernateUtil.java:20)
    at test.Test.main(Test.java:20)
    Caused by: org.hibernate.AnnotationException: mappedBy reference an unknown target entity property: domain.Termin.person in domain.Person.termine
    at org.hibernate.cfg.annotations.CollectionBinder.bindStarToManySecondPass(CollectionBinder.java:552)
    at org.hibernate.cfg.annotations.CollectionBinder$1.secondPass(CollectionBinder.java:517)
    at org.hibernate.cfg.CollectionSecondPass.doSecondPass(CollectionSecondPass.java:43)
    at org.hibernate.cfg.Configuration.secondPassCompile(Configuration.java:1130)
    at org.hibernate.cfg.AnnotationConfiguration.secondPassCompile(AnnotationConfiguration.java:316)
    at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1286)
    at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:915)
    at services.HibernateUtil.sessionFactory(HibernateUtil.java:36)
    ... 2 more
    package domain;
    import java.util.LinkedList;
    import java.util.List;
    import domain.Termin;
    import javax.persistence.Entity;
    import javax.persistence.GeneratedValue;
    import javax.persistence.GenerationType;
    import javax.persistence.Id;
    import javax.persistence.ManyToMany;
    import javax.persistence.Table;
    @Entity
    @Table(name = "PERSON")
    public class Person {
       private long id;
       private String vorname;
       private String nachname;
       private List<Termin> termine=new LinkedList<Termin>();
       public Person() {
       @Id @GeneratedValue(strategy=GenerationType.AUTO)
       public long getId() {
          return id;
       public void setId(long id) {
          this.id = id;
       public String getNachname() {
          return nachname;
       public void setNachname(String nachname) {
          this.nachname = nachname;
       public String getVorname() {
          return vorname;
       public void setVorname(String vorname) {
          this.vorname = vorname;
       public void addTermin(Termin termin){
          termine.add(termin);
       @ManyToMany(mappedBy="person")
       public List<Termin> getTermine() {
          return termine;
       public void setTermine(List<Termin> termine) {
          this.termine = termine;
    package domain;
    import java.util.ArrayList;
    import java.util.List;
    import javax.persistence.Entity;
    import javax.persistence.GeneratedValue;
    import javax.persistence.GenerationType;
    import javax.persistence.Id;
    import javax.persistence.ManyToMany;
    import javax.persistence.Table;
    @Entity
    @Table(name = "TERMIN")
    public class Termin {
       private long id;
       private String titel;
       private Person eigentuemer;
       private List<Person> teilnehmer= new ArrayList<Person>();
       public void addTeilnehmer(Person person){
          teilnehmer.add(person);
       @ManyToMany
       public List<Person> getTeilnehmer() {
          return teilnehmer;
       public void setTeilnehmer(List<Person> teilnehmer) {
          this.teilnehmer = teilnehmer;
       public Termin() {
       @Id @GeneratedValue(strategy=GenerationType.AUTO)
       public long getId() {
          return id;
       public void setId(long id) {
          this.id = id;
       public String getTitel() {
          return titel;
       public void setTitel(String titel) {
          this.titel = titel;
       public Person getEigentuemer() {
          return eigentuemer;
       public void setEigentuemer(Person eigentuemer) {
          this.eigentuemer = eigentuemer;
    package test;
    import org.hibernate.Session;
    import org.hibernate.SessionFactory;
    import org.hibernate.Transaction;
    import org.hibernate.cfg.Configuration;
    import org.hibernate.tool.hbm2ddl.SchemaExport;
    import services.HibernateUtil;
    import domain.Person;
    import domain.Termin;
    public class Test {
       public static void main(String[] args) {
          Session session = null;
          HibernateUtil.setRecreateDB(true);
          session = HibernateUtil.getSessionFactory().getCurrentSession();
          /*      Person person1 =new Person();
          person1.setNachname("P1");
          Transaction transaction = session.beginTransaction();
          session.save(person1);
          transaction.commit();
          Person person2 =new Person();
          person2.setNachname("P2");
          session = HibernateUtil.getSessionFactory().getCurrentSession();
          transaction = session.beginTransaction();
          session.save(person2);
          transaction.commit();
          Termin termin1 =new Termin();
          termin1.setTitel("T1");
          termin1.setEigentuemer(person1);
          termin1.addTeilnehmer(person1);
          termin1.addTeilnehmer(person2);
          session = HibernateUtil.getSessionFactory().getCurrentSession();
          transaction = session.beginTransaction();
          session.save(termin1);
          transaction.commit();
       Termin termin2 =new Termin();
          termin2.setTitel("t2");
          termin2.setEigentuemer(person1);
          termin2.addTeilnehmer(person1);
          termin2.addTeilnehmer(person2);
          transaction = session.beginTransaction();
          session.save(termin2);
          transaction.commit();
          session.close();
    package services;
    import org.hibernate.SessionFactory;
    import org.hibernate.cfg.AnnotationConfiguration;
    import domain.Person;
    import domain.Termin;
    public class HibernateUtil {
       private static boolean recreateDB = false;
       public static void setRecreateDB(boolean recreateDB) {
          HibernateUtil.recreateDB = recreateDB;
       public static SessionFactory getSessionFactory() {
          if (sessionFactory == null) {
             sessionFactory = sessionFactory("hibernate.cfg.xml");
          return sessionFactory;
       private static SessionFactory sessionFactory = null;
       private static SessionFactory sessionFactory(String configurationFileName) {
          try {
             AnnotationConfiguration annotationConfiguration =
                new AnnotationConfiguration()
                .addAnnotatedClass(Person.class)
                .addAnnotatedClass(Termin.class);
             if (recreateDB) annotationConfiguration.setProperty("hibernate.hbm2ddl.auto", "create");
             annotationConfiguration.configure();
             return annotationConfiguration.buildSessionFactory();
          } catch (Throwable ex){
             System.err.println("Initial SessionFactory creation failed." + ex);
             throw new ExceptionInInitializerError(ex);
    <?xml version="1.0" encoding="utf-8"?>
    <!DOCTYPE hibernate-configuration
        PUBLIC "-//Hibernate/Hibernate Configuration DTD//EN"
        "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
    <hibernate-configuration>
        <session-factory >
          <property name="hibernate.connection.driver_class">org.gjt.mm.mysql.Driver</property>
            <property name="hibernate.connection.password">application</property>
            <property name="hibernate.connection.url">jdbc:mysql://localhost/test</property>
            <property name="hibernate.connection.username">application</property>
            <property name="hibernate.dialect">org.hibernate.dialect.MySQLDialect</property>
           <property name="current_session_context_class">thread</property>
          <property name="hibernate.show_sql">true</property>
        </session-factory>
    </hibernate-configuration>

    The error message is pretty much telling you the problem:
    mappedBy reference an unknown target entity property: domain.Termin.person in domain.Person.termine
    This tells you that there's a mappedBy setting on the Person class's termine property annotation, and that the property it's referring to (the person property of the Termin class) doesn't exist.
    @ManyToMany(mappedBy="person")
    public List<Termin> getTermine() {
       return termine;
    }If we have a look at the Termin class, indeed it has the following properties:
    id
    teilnehmer
    titel
    eigentuemerAnd no person property. Remember, a property is defined by the existence of a get/set pair for the name. It's unrelated to the types returned by them and the private variables implementing them.
    mappedBy has the equivalent effect to the inverse property in a hbm.xml mapping file - it defines which entity's property will cause the foreign key value to be updated (persisting the relationship to the database). From the context of your code, I'm guessing you really want the annotation to read:
    @ManyToMany(mappedBy="teilnehmer")

  • Jsf newbie :: converter and navigation issues

    Hi,
    Iam facing a problem in my first jsf application.
    Iam using jsf 1.1 and tomcat 5.5.7
    I have a UserBean with a single attribute userName (which has public getter and setter methods).
    * I have an index.jsp that redirects to login.faces.
    * I have the appropriate servlet url-mapping in my web.xml that maps *.faces to the FacesServlet
    Here's the code for login.jsp
    <f:view>
       <h:form>
             <h3>Please enter your name </h3>
         <table>
          <tr>
              <td>Name:</td>
            <td><h:inputText id = "name" value="#{user.userName}"/></td>
         </tr>               
         </table>
         <p><h:commandButton value="Login" action="welcome"/>
         </p>
         </h:form>
       </body>
    </f:view>Next I have a welcome.jsp which simply outputs Hello <userName>
    <f:view>
      <h:form>
         <h:outputText value="#{user.userName}"></h:outputText>
      </h:form>
    </f:view>And this is my faces-config.xml
    <?xml version="1.0"?>
    <!DOCTYPE faces-config PUBLIC
      "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
      "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
    <faces-config>
         <managed-bean>
              <managed-bean-name>user</managed-bean-name>
              <managed-bean-class>com.myjsf.UserBean</managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
         </managed-bean>
         <navigation-rule>
              <from-view-id>/index.jsp</from-view-id>
              <navigation-case>
                   <from-outcome>welcome</from-outcome>
                   <to-view-id>/welcome.jsp</to-view-id>
              </navigation-case>
         </navigation-rule>
    </faces-config>Now when I start my application , the index page redirects me to login.faces. I believe the FacesServlet intercepts this call, strips of .faces and forwards to login.jsp. Login.jsp is displayed correctly, so far so good. However from here on, I have all kinds of problems
    1. Should the <from-view-id> be /index.jsp (my actual url) or /login.jsp (the url to which index.jsp forwards me to). Actually both seem to work (or not work depending on how you look at it :( )
    2. Anyways whatever I set it to, the login.jsp is displayed correctly. The action attribute of the commandButton tag is set to 'welcome' which matches with the <from-outcome> value in navigation rule in faces-config.xml and I would have expected the welcome.jsp to load on form submit.
    But the form just reloads itself on clicking submit.
    I googled around and discovered that this may be due to validation errors or conversion errors and adding <h:messages/> would indicate the error source. AQccordingly I added it and got this o/p
    " "name": " Conversion Error setting value 'Duke' for 'null Converter'. To cut a long agony story short, I found that I have to define a converter for some data types for validation and/or display. But all I have is a String property. Doesnt jsf provide a default Converter ?
    3. I couldnt get my app to work when I put my jsps in a folder and access them as /<foldername>/jsp in my faces-config.xml. Isnt this possible ? Should all jsps be under the root folder ?
    Will be thankful for any help.
    cheers,
    ram.
    2. Whenever I click on

    Thanks for the reference , I shall definitely go through it.
    My immediate concern is to get the first program working.
    Here is my source code for the bean.
    package com.myjsf;
    import java.io.Serializable;
    public class UserBean implements Serializable {
        private String userName;  
        public String getUserName() {
            return userName;
        public void setName(String userName) {
            this.userName = userName;
    }Here's my login.jsp which comes up fine
    <f:view>
       <h:form>
         <h:messages/>
             <h3>Please enter your name.</h3>               
                 Name: <h:inputText id = "userName" value="#{user.userName}"/><br>
                  <h:commandButton value="Login" action="welcome"/>
         </h:form>
      </f:view>Here's my faces-config.xml
    <faces-config>
         <managed-bean>
              <managed-bean-name>user</managed-bean-name>
              <managed-bean-class>com.myjsf.UserBean</managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
         </managed-bean>
         <navigation-rule>
              <from-view-id>/login.jsp</from-view-id>
              <navigation-case>
                   <from-outcome>welcome</from-outcome>
                   <to-view-id>/welcome.jsp</to-view-id>
              </navigation-case>
         </navigation-rule>
    </faces-config>     And this is the error that I get
    "userName": Conversion error occurred. The page gets displayed again. One thing I noticed was that in the html - view source the action attribute of the form tag is set to /myjsf/faces/login.jsp. Shouldnt it be welcome.jsp rather ?
    Iam at my wits end. I have decided to write a Converter which may solve my problem, but is it required ?
    Please help.
    Thanks,
    Ram.

  • JSF 1.2  and Weblogic 10.3.6 compatibility issue

    Hi All,
    Our application have been developed in JSF 1.2 and spring DAO. We have deployed it on Weblogic 10.3.6 X86 server.
    We are facing an issue like on page load data are populated in the page. Say for example on page load company list getting populated and displayed in the drop down.
    If we do any operation like select a company code or submit the page all the data are flushed out from the pages. After that navigation of pages also doesnot work.
    We neither get any logs nor exception.
    And i am not getting this issue in my local weblogic server - 10.3.5
    We are struggling with this issue for more than 10 days now and its critical time for us to fix it ASAP.
    Thanks,
    Seetha

    Hi kalyan,
    We are not getting any logs. the control is going to javascript but the page get refreshed and all data are just vanishing.
    We have tried to add below entries in weblogic-application.xml
    <wls:prefer-application-packages>
    <wls:package-name>com.sun.facelets.*</wls:package-name>
    <wls:package-name>com.sun.faces.*</wls:package-name>
    <wls:package-name>javax.faces.*</wls:package-name>
    <wls:package-name>javax.servlet.*</wls:package-name>
    </wls:prefer-application-packages>
    No change.
    Tried this
    <wls:library-ref>
    <wls:library-name>jsf</wls:library-name>
    <wls:specification-version>1.2</wls:specification-version>
    <wls:implementation-version>1.2</wls:implementation-version>
    <wls:exact-match>false</wls:exact-match>
    </wls:library-ref>
    No Change.
    tried this
    <wls:prefer-application-resources>
    <wls:resource-name>APP-INF/lib</wls:resource-name>
    </wls:prefer-application-resources>
    No Change
    Anything we missing here. Why it is working in my local server and not in Integration server?
    Kindly help us.
    Thanks,
    Seetha

Maybe you are looking for

  • My iPhone 5s will send messages, but not receive them. Replies show up on my iPad. How do I fix this?

    Anyone know how to fix imessage and FaceTime issues with iPhone 5s?  I can send messages, but replies only show up on my iPad, not my phone. Can't FaceTime at all, just on iPad.  Says "waiting for activation". Or "Activation unsuccessful. Turn on iMe

  • How can I connect my Apple TV to an enterprise secure network?

    Is it possible to do this?

  • ITMS Music Download (err = -50)

    I've purchased many songs from the iTMS. I'm trying to download a whole album and getting this error message during each song download: +++++++++++++++++++++ There was a problem downloading "song title/Band/Album". An unknown error occurred (-50). Pl

  • How to make use of EP?

    hi friends,         I have a few doubts in EP? My client is already implemented EP for their business. Now my client is trying to implement SOA.. In this point of view... How we can show that the new advntages of EP. like VC.. CAF Guided procedures..

  • Segmenter une image en 4 couleurs sous Vision

    Bonjour, J'ai une image que j'aimerais segmenter en 4 couleurs : rouge, jaune, vert et bleu avec des seuillages en RGB pour avoir uniquement 4 couleurs sur ma photo. J'ai essayé avec Color Segmentation Setup et Class Labels mais malheureusement je n'