Home Answers Viewqa JSF-Questions problem with executing JSF file(Build failed)

 
 


B.sucharitha
problem with executing JSF file(Build failed)
2 Answer(s)      a year and 11 months ago
Posted in : Java Server Faces Questions

*while executing below code i am getting problem as
**init:
deps-module-jar:
deps-ear-jar:
deps-jar:
library-inclusion-in-archive:
library-inclusion-in-manifest:
compile:
compile-jsps:
Created dir: /root/NetBeansProjects/JSFProject3/build/generated/src
Created dir: /root/NetBeansProjects/JSFProject3/build/generated/classes
Compiling 1 source file to /root/NetBeansProjects/JSFProject3/build/generated/classes
In-place deployment at /root/NetBeansProjects/JSFProject3/build/web
deploy?config=file%3A%2Ftmp%2Fcontext443.xml&path=/JSFProject3
FAIL - Deployed application at context path /JSFProject3 but context failed to start
/root/NetBeansProjects/JSFProject3/nbproject/build-impl.xml:594: The module has not been deployed.
BUILD FAILED (total time: 9 seconds)***

Please any one give me solution for this?

**strong text**resources of application are:

    login.jsp:

    <%@taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
    <%@taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
    <html>
        <body>
            <f:view>
                <h:form id="loginfrm">
                    <h:outputLabel value="username : "/>
                    <h:inputText id="uname" value="#{login_bean.uname}"></h:inputText>
                    <h:outputLabel value="password : "/>
                    <h:inputText id="pwd" value="#{login_bean.pwd}" required="true"></h:inputText>
                    <h:commandButton value="Login" action="#{login_bean.validate}" type="submit"/>
                    <h:message for="uname" />
                    <h:message for="pwd" />
                </h:form>
            </f:view>

        </body>
    </html>


 // LoginBean.java

    /*
     * To change this template, choose Tools | Templates
     * and open the template in the editor.
     */
    package beans;

    /**
     *
     * @author root
     */
    import java.sql.*;
    import java.io.*;

    public class LoginBean {

        private String uname;
        private String pwd;
        Connection con = null;
        ResultSet rs = null;

        Statement st = null;

        public void setPwd(String pwd) {
            this.pwd = pwd;
        }

        public void setUname(String uname) {
            this.uname = uname;
        }

        public String getPwd() {
            return pwd;
        }

        public String getUname() {
            return uname;
        }

        public String validate() {
            boolean b = false;
            try {
                System.out.println("uname::" + uname);
                Class.forName("com.mysql.jdbc.Driver");
                con = DriverManager.getConnection("jdbc:mysql://localhost:3306/livepbx", "root", "worksmart");
                st = con.createStatement();
                String qry = "select agentid from agent where agentid = 'abcd@pbxtesting'";
                rs = st.executeQuery(qry);
                while (rs.next()) {
                    b = true;
                }

            } catch (Exception e) {
               // System.out.println("ERRor in Logbeanpage@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@s");
            } finally {
                try {
                    rs.close();
                    st.close();
                    con.close();
                } catch (Exception e) {
                    //e.printStackTrace();
                }



            }
            if (b) {
                return "valid";
            } else {
                return "invalid";
            }



        }
    }

    success.jsp 

    <%-- 
        Document   : success
        Created on : Jun 25, 2011, 11:17:08 AM
        Author     : root
    --%>

    <%@page contentType="text/html" pageEncoding="UTF-8"%>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
       "http://www.w3.org/TR/html4/loose.dtd">
    <%
    String val=request.getParameter("val");
    out.println("value in success pageis ::"+val);
    %>

    <html>
        <head>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
            <title>JSP Page</title>
        </head>
        <body>
            <h1>valid successfully</h1>
        </body>
    </html>

   // failure.jsp 


    <%-- 
        Document   : failure
        Created on : Jun 25, 2011, 11:17:37 AM
        Author     : root
    --%>

    <%@page contentType="text/html" pageEncoding="UTF-8"%>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
       "http://www.w3.org/TR/html4/loose.dtd">
    <%
    String val=request.getParameter("val");
    out.println("value in failurepage is ::"+val);
    %>

    <html>
        <head>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
            <title>JSP Page</title>
        </head>
        <body>
            <h1>in valid credentials</h1>
        </body>
    </html>


  // faces-config.xml

    <?xml version="1.0"?>
    <faces-config>

    <managed-bean>
       <description>TreeDemo</description>
       <managed-bean-name>treeDemo</managed-bean-name>
      <managed-bean-class>
      beans.TreeDemo
      </managed-bean-class>
      <managed-bean-scope>
      request
      </managed-bean-scope>
    </managed-bean>
    <managed-bean>
       <description>CCBean</description>
       <managed-bean-name>newfile</managed-bean-name>
      <managed-bean-class>
     beans.CCBean
      </managed-bean-class>
      <managed-bean-scope>
      request
      </managed-bean-scope>
    </managed-bean>
    <managed-bean>
        <managed-bean-name>login_bean</managed-bean-name>
        <managed-bean-class>beans.LoginBean</managed-bean-class>
        <managed-bean-scope>request</managed-bean-scope>
    </managed-bean>
     <navigation-rule>
                <description>Loging Page</description>
                <from-view-id>/login.jsp</from-view-id>
                <navigation-case>
                        <from-action>#{login_bean.validate}</from-action>
                    <from-outcome>valid</from-outcome>
                    <to-view-id>/success.jsp?val=yes</to-view-id>
                </navigation-case>
                <navigation-case>
                    <from-action>#{login_bean.validate}</from-action>
                    <from-outcome>invalid</from-outcome>
                    <to-view-id>/failure.jsp?val=no</to-view-id>
                </navigation-case>

            </navigation-rule>

    </faces-config>

   // web.xml 

    <?xml version="1.0" encoding="UTF-8"?>
    <web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
        <context-param>
            <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
            <param-value>server</param-value>
        </context-param>
        <context-param>
            <param-name>javax.faces.CONFIG_FILES</param-name>
            <param-value>/WEB-INF/faces-config.xml</param-value>
        </context-param>
        <listener>
            <listener-class>com.sun.faces.config.ConfigureListener</listener-class>
        </listener>
        <servlet>
            <servlet-name>Rcfaces Framework Contents</servlet-name>
            <servlet-class>org.rcfaces.renderkit.html.internal.resource.ResourcesServlet</servlet-class>
            <init-param>
                <param-name>org.rcfaces.renderkit.html.javascript.sets.CORE</param-name>
                <param-value>
                    basicComponent,message,extraButton,tree,dataGrid
                </param-value>
            </init-param>
            <load-on-startup>1</load-on-startup>
        </servlet>
        <servlet>
            <servlet-name>
                Rcfaces Application Contents
            </servlet-name>
            <servlet-class>
                org.rcfaces.core.internal.contentStorage.ContentStorageServlet
            </servlet-class>
            <load-on-startup>1</load-on-startup>
        </servlet>
        <servlet>
            <servlet-name>Serv</servlet-name>
            <servlet-class>beans.Serv</servlet-class>
        </servlet>
        <servlet-mapping>
            <servlet-name>
                Rcfaces Framework Contents
            </servlet-name>
            <url-pattern>/rcfaces/*</url-pattern>
        </servlet-mapping>
        <servlet-mapping>
            <servlet-name>
                Rcfaces Application Contents
            </servlet-name>
            <url-pattern>/rc-content/*</url-pattern>
        </servlet-mapping>
        <servlet>
            <servlet-name>Faces Servlet</servlet-name>
            <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
            <load-on-startup>1</load-on-startup>
        </servlet>
        <servlet-mapping>
            <servlet-name>Faces Servlet</servlet-name>
            <url-pattern>/faces/*</url-pattern>
        </servlet-mapping>
        <servlet-mapping>
            <servlet-name>Serv</servlet-name>
            <url-pattern>/Serv</url-pattern>
        </servlet-mapping>
        <session-config>
            <session-timeout>
                30
            </session-timeout>
        </session-config>
        <welcome-file-list>
            <welcome-file>faces/SampleTree.jsp</welcome-file>
        </welcome-file-list>

    </web-app>


  // context.xml

    <?xml version="1.0" encoding="UTF-8"?>
    <Context antiJARLocking="true" path="/JSFProject3"/>
View Answers

June 28, 2011 at 12:43 PM


Check your xml files.Anyways, go through the following link:

JSF Tutorials


June 28, 2011 at 3:18 PM


The below is complete stack trace while running above JSF application:

----------

**strong text**JSFProject3(run)
______________
Incrementally deploying http://localhost:8083/JSFProject3
Completed incremental distribution of http://localhost:8083/JSFProject3
Incrementally redeploying http://localhost:8083/JSFProject3
Deploy is in progress...
deploy?config=file%3A%2Ftmp%2Fcontext448.xml&path=/JSFProject3
FAIL - Deployed application at context path /JSFProject3 but context failed to start
/root/NetBeansProjects/JSFProject3/nbproject/build-impl.xml:594: The module has not been deployed.
BUILD FAILED (total time: 5 seconds)


----------


**Tomcat 6.0JSf**
_____________
Listening for transport dt_socket at address: 11550
Jun 28, 2011 12:55:34 PM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/java/jdk1.5.0_08/jre/lib/i386/server:/usr/java/jdk1.5.0_08/jre/lib/i386:/usr/java/jdk1.5.0_08/jre/../lib/i386:/usr/java/jdk1.5.0_08/jre/lib/i386/client:/usr/java/jdk1.5.0_08/jre/lib/i386:/usr/java/jdk1.5.0_08/jre/../lib/i386
Jun 28, 2011 12:55:34 PM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8083
Jun 28, 2011 12:55:34 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1154 ms
Jun 28, 2011 12:55:35 PM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Jun 28, 2011 12:55:35 PM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.20
Jun 28, 2011 12:55:37 PM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8083
Jun 28, 2011 12:55:38 PM org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8009
Jun 28, 2011 12:55:38 PM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/261  config=null
Jun 28, 2011 12:55:38 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 3683 ms
Jun 28, 2011 12:55:42 PM org.apache.catalina.core.StandardContext addApplicationListener
INFO: The listener "com.sun.faces.config.ConfigureListener" is already configured for this context. The duplicate definition has been ignored.
Jun 28, 2011 12:55:43 PM com.sun.faces.config.ConfigureListener contextInitialized
INFO: Initializing Sun's JavaServer Faces implementation (1.2_04-b20-p03) for context '/JSFProject3'
Jun 28, 2011 12:55:44 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Jun 28, 2011 12:55:44 PM org.apache.catalina.core.StandardContext start
SEVERE: Context [/JSFProject3] startup failed due to previous errors
Jun 28, 2011 3:26:47 PM org.apache.catalina.core.StandardContext stop
INFO: Container org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/JSFProject3] has not been started
Jun 28, 2011 3:26:47 PM org.apache.catalina.startup.HostConfig checkResources
INFO: Undeploying context [/JSFProject3]
Jun 28, 2011 3:26:48 PM org.apache.catalina.core.StandardContext addApplicationListener
INFO: The listener "com.sun.faces.config.ConfigureListener" is already configured for this context. The duplicate definition has been ignored.
Jun 28, 2011 3:26:49 PM com.sun.faces.config.ConfigureListener contextInitialized
INFO: Initializing Sun's JavaServer Faces implementation (1.2_04-b20-p03) for context '/JSFProject3'
Jun 28, 2011 3:26:51 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Jun 28, 2011 3:26:51 PM org.apache.catalina.core.StandardContext start
SEVERE: Context [/JSFProject3] startup failed due to previous errors









Related Pages:
problem with executing JSF file(Build failed)
problem with executing JSF file(Build failed)  *while executing below... deployed. BUILD FAILED (total time: 9 seconds)*** Please any one give me solution... deployed. BUILD FAILED (total time: 5 seconds) Tomcat 6.0JSf Listening
Executing JAR file - Swing AWT
Manifest.txt secl/*.class and my jar file is created. But there is a problem, when...Executing JAR file  Hello Friends! I have successfully created the JAR file of my project with the Manifest File including my Main
Problem in executing query....
Problem in executing query....  Suppose there is a textbox or a text... it is showing error because of the '.I understand where the problem is.If the user does not enter ' then there is no problem while executing.But suppose the user
Problem in executing macro enabled excel sheet using java
Problem in executing macro enabled excel sheet using java  Hi, I have written a java code which will read a excel sheet with macro enabled... to execute VB script it is unable to execute macro and cannot generate the script file
Executing code upon folder/drive access
Executing code upon folder/drive access  I would be glad if someone... of drive you can use Autorun.inf file. In the Autorun.inf file you can include... this will solve your problem. Thanks
I got build failed when deploying enterprise application - EJB
I got build failed when deploying enterprise application  I created...(Deployment.java:160) ... 16 more BUILD FAILED (total time: 2 seconds)   ...: library-inclusion-in-archive: library-inclusion-in-manifest: Copying 1 file to E
JBoss deployment problem for jsf - Java Server Faces Questions
JBoss deployment problem for jsf  HI all, I am unable to deploy the .war file with richfacess implemnation of jst. Get foolowing eror... org.jboss.web.jsf.integration.config.JBossJSFConfigureListener com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED
jsf - Java Server Faces Questions
jsf  Hi, In my project there are 3 jsp pages and one jsf page ,first jsp page forwarding the request to jsf page then this jsf gives the greeting page means if it is success it goes to success page otherwise it goes to failed
SEVERE: Context [/hospital] startup failed due to previous errors
SEVERE: Context [/hospital] startup failed due to previous errors  Hi my application is hospital i am facing this problem my build.xml file is build success but in the Tomcat Web Application Manager path showing false message
executing Hibernate application
executing Hibernate application  when i am executing the hibernate application the following error occured. log4j:WARN No appenders could be found...) Java Result: 1 BUILD SUCCESSFUL (total time: 2 seconds) can you tell me
executing a batch file which depends on jar files from a system tray but console should not display.
executing a batch file which depends on jar files from a system tray... to run a batch file which is depending on some jar files and it displays a frame... in a system tray. Please help me in resolving this problem. Am not receiving
Nota ble to build EJB application - EJB
Nota ble to build EJB application  hi , am beginner to EJB i tried this building EJB application am getting follwoing error BUILD FAILED D...\tempAnt.xml:69: Can't create a mdb element under ejbdoclet. Make sure the jar file
jsf
jsf  two datatables displaying in the tab but we are using same file.jspx in two different tabs how to solve this problem
maven build failed
maven build failed  Hi, I have downloaded the maven 3.0.4 and extracted it.and I have seted the path correctly. I am following steps from this url. http://www.roseindia.net/maven2/installingandgettinghandson
maven build failed
maven 3.0.4 build failed  Hi, I have downloaded the maven 3.0.4 and extracted it.and I have seted the path correctly. I am following steps from this url. http://www.roseindia.net/maven2/installingandgettinghandson
executing java program with 2 classes
); } }   Executing java program with 2 classes save the file with D.java...executing java program with 2 classes  how to run a program of java containing more than one class....ex of program is given below.... class C
JSF with Facelets - Problem setting attribute maxlength - Java Server Faces Questions
JSF with Facelets - Problem setting attribute maxlength  Hi, I have just started working on JSF along with facelets. I have created a xhtml file that contains a widget. I want to set the maxlength attribute of the text field
JSF Command button problem - Java Server Faces Questions
JSF Command button problem  Hi Frnds... I have retrieved the records from the mdb file in backing bean..if i click the submit button those records will be displayed in the form of table... Records are displaying
JSF Tutorial For Beginners
and event driven way that runs on the server side. JSF also allows to build.... JSF provided the facility of reusability of code. Problem of working... then it may cause to security problem. JSF has resolve this problem. Features
Empty screen after executing servlet - Development process
Empty screen after executing servlet  Hi, After executing...) and export it (saved war file) 2)started server (weblogic) 3)Go to console 4)Locate war file and deployed 5)Then test , but am getting empty screen . Plz give
FTP file copy problem? - Java Beginners
FTP file copy problem?  Hi, Can any one tell me how to set file...) { throw new Exception ("Storing of remote file failed. ftp.storeFile...-net-1.4.1.jar to copy files from local system to server. Eg: local file name ?test.doc
How create csv format in jsf ?
How create csv format in jsf ?  Dear Friends , Good morning to all of you? I have a problem to create .CSV format in jsf. Actully I have successfully created .PDF files of my jasper report form jrxml in jsf
Eclipse-launch failed binaries not found
. "LAUNCH FAILED NO BINARIES". Can anyone please explain me what's going on or problem...Eclipse-launch failed binaries not found  I recently downloaded..., right click on it > new > source file 3.In there I have written some
JSF - Java Server Faces Tutorials
in JSF In this section you will learn how to use properties file...JSF - Java Server Faces Tutorials Complete Java Server Faces (JSF) Tutorial - JSF Tutorials. JSF Tutorials at Rose India covers
jsf image problem - Java Server Faces Questions
jsf image problem  Dear Sir My doubt is about displAying a java.awt.image in the jsf page. Here i had a object of java.awt.image in manage bean i want to display that image contained in that object to the jsf page.This
problem in database
problem in database   thanks for web site. I want change this code..."); } else{ out.println("failed to insert the data...-mapping&gt; &lt;welcome-file-list&gt; &lt;welcome
Problem to print from my properties file - Java Server Faces Questions
Problem to print from my properties file  Hi, I am a new user of this site. It is very interesting. So this is my problem: I have a jsp file where i try to print some messages from my properties file but when i execute
Problem to print from my properties file - Java Server Faces Questions
Problem to print from my properties file  Hi, I am a new user of this site. It is very interesting. So this is my problem: I have a jsp file where i try to print some messages from my properties file but when i execute
JSF Forms - Developing form based application
the build.xml file and directories necessary to build the application. Download...JSF Forms - Developing form based application          Complete Java Server Faces (JSF
JSF-Error - Java Server Faces Questions
JSF-Error  Error in JSP when I used to run loging.jsp the below... Could u please resolve this problem. THanks joti  Hi friend, Please add servlet-api.jar file in lib and check facesContext file . Now
problem in creating create .ipa file in my iPhone app
problem in creating create .ipa file in my iPhone app  Hi, does anyone have idea on how to create a .create .ipa file for my iPhone / iPad application? Also do i need to delete the previous build to create .ipa file? Thanks
jsf table
as myproject.in this project, i have a file named as index.jsp. now i want to create a jsf table in this index.jsp file.this jsf file should be able to retrieve the data from...jsf table  hi, my question is as follows : i am using front end
Backbase AJAX for JSF
Backbase AJAX for JSF       Backbase AJAX for JSF is a complete AJAX - JSF programming framework build on top of Apache MyFaces and Eclipse it's Pre-build AJAX-JSF components andEclipse
Problem reading word file
Problem reading word file  Deepak you provide me code for extarcting equation from a word file and also to write in a word file.But when I again want to read preveously created word file(created by your code) it gives an error
application context file problem
application context file problem  how to configure junit application context file with struts........? it is not finding sessionfactory method
File Uploading Problem
File Uploading Problem  I have a file uploading code but it create problem $(document).ready(function(){ $('#upload').click(function(){ var... it gives the problem org.apache.commons.fileupload.FileUploadException
File Uploading Problem
File Uploading Problem  I have a file uploading code but it create problem $(document).ready(function(){ $('#upload').click(function(){ var... it gives the problem org.apache.commons.fileupload.FileUploadException
JSF Navigation By Example
are managed by the controller i.e. the faces-config.xml file in JSF...JSF Navigation By Example     .... This section illustrates you about the JSF navigation by providing the example
JSF Tutorial for Beginners
build asp.net pages by hand-coding, we can build JSF also by hand-coding... INTRODUCING   JAVA  SERVER  FACES (JSF) by ... (www.developeriq.com)   JSF Home | PART-1 | PART-2 | PART-3    
JSF security design problem - Java Server Faces Questions
jsf at all? Please, provide your ideas of solving this problem. Thanks...JSF security design problem  Hi! I have to manage security (the quantity of roles and groups is rather huge) in java ee 5 + jsf (1.x) project
JSF Tomahawk date problem - Java Server Faces Questions
JSF Tomahawk date problem  hi i am working with jsf. I have... full details with source code to solve the problem and visit to : http://www.roseindia.net/jsf/apache-myfaces-tomahawk/tomahawk_inputDate_tag.shtml http
JSF - JSP-Interview Questions
JSF  How to embedded PDF in JSF page(jsp file created
Build File in java - Development process
Build File in java   Hi Friends, Can u explain me what is necessary for build file in java application. I mean it contains war file or anything
JBoss Application Server Start Failed. HTTP Connector port 8080 is already in use.
) ... 16 more BUILD FAILED (total time: 4 seconds...JBoss Application Server Start Failed. HTTP Connector port 8080 is already in use.  Please help me to solve the following problem: init: deps-module
struts jar file problem
struts jar file problem  hi.. I'm using struts-core-1.3.9.jar. it works well if am using ma application with internet but it shows me an error while initializing ActionServlet when i disconnected to Internet The error stack trace
Problem in my code - Development process
Friend, It seems that the jsp file you are executing or you are calling...Problem in my code  Plz go thru this code. I want to check login... executing code am getting 404 error User Name Password
JSF Introduction - An Introduction to JSF Technology
JSF Introduction - An Introduction to JSF Technology...; Java Server Faces or JSF for short is another new exciting technology for developing web applications based on Java technologies. This JSF
jsf graphicImage onclick problem - Java Server Faces Questions
jsf graphicImage onclick problem  hello I have a problem on netbeans-jsf-graphicImage component. I want to get image coordinate and write it to staticText component, when I clicked on the map. But I couldn't achieve
pagination in jsf
pagination in jsf  Hi , i am implemeting an online exam system , i have placed my questions as an arraylist in my jsp file within tag , but now i want to paginate these questions based on respective questions by clicking
problem with applet plugin - Applet
problem with applet plugin  hello friends, iam using Eclipse IDE...) Caused by: java.io.IOException: open HTTP connection failed:http://localhost...: com.ezsoft.applets.Upload.class --------------------------------------- i saved that file in src

Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.