Results 1 to 3 of 3
Thread: Questions About JSP?
- 08-17-2008, 08:29 AM #1
Member
- Join Date
- Aug 2008
- Location
- Riyadh - Saudi Arabia
- Posts
- 15
- Rep Power
- 0
Questions About JSP?
hi;
I am php devloper and I am learning Java now.
I am using NB6.1 , Tomcat 6.0 , J2ee 5.
I have some questions about devleoping web application with jsp.
1.What are
/WEB-INF/web.xml
/META-INF/context.xml
/META-INF/MANIFEST.MF
files that generated with NB.are important or optional.are auto generated or may I edit.
2.can I distribute my web application in non text format.How?
3.if I want to add some files to my application that its running in tomcat.how can i do that with out rebuild all.
thank you
- 08-17-2008, 06:56 PM #2
These are magic configuration files. You can edit them manually, but I do not recommend it. Netbeans can edit them for you and you will make fewer mistakes.
Can you be more specific? With servlets and jsp, you typically deploy your application to a webserver for use by clients with browsers. So you don't deploy it to users, you do deploy it to the server. You deploy a WAR file, which is actually just a .zip file of the manifest, config, and other administrivia files, plus the compiled .class files.2.can I distribute my web application in non text format.How?
Can you be more specific? In general, you use Netbeans (or eclipse) to build the war file. You do this when you make any changes to the classes, config, or .jsp files.3.if I want to add some files to my application that its running in tomcat.how can i do that with out rebuild all.
Tomcat, JBoss, etc. will allow you to deploy a new war file while there are users accessing the application, and it does the right thing.
- 08-19-2008, 07:56 PM #3
Member
- Join Date
- Aug 2008
- Location
- Riyadh - Saudi Arabia
- Posts
- 15
- Rep Power
- 0
thank you all for helping.
I will write more information about my questions may this help others:
{ /WEB-INF/web.xml - The +Web Application Deployment
Descriptor+ for your application. This is an XML file describing
the servlets and other components that make up your application,
along with any initialization parameters and container-managed
security constraints that you want the server to enforce for you.
This file is discussed in more detail in the following subsection.
As mentioned above, the /WEB-INF/web.xml file contains the
Web Application Deployment Descriptor for your application. As the filename
extension implies, this file is an XML document, and defines everything about
your application that a server needs to know (except the context path,
which is assigned by the system administrator when the application is
deployed).
The complete syntax and semantics for the deployment descriptor is defined
in Chapter 13 of the Servlet API Specification, version 2.3. Over time, it
is expected that development tools will be provided that create and edit the
deployment descriptor for you. In the meantime, to provide a starting point,
a basic web.xml file
is provided. This file includes comments that describe the purpose of each
included element.
NOTE - The Servlet Specification includes a Document
Type Descriptor (DTD) for the web application deployment descriptor, and
Tomcat 6 enforces the rules defined here when processing your application's
<code>/WEB-INF/web.xml</code> file. In particular, you must
enter your descriptor elements (such as <code><filter></code>,
<code><servlet></code>, and <code><servlet-mapping></code> in
the order defined by the DTD (see Section 13.3).
} from tomcat documentation
{
Tomcat Context Descriptor
A /META-INF/context.xml file can be used to define Tomcat specific configuration options, such as loggers, data sources, session manager configuration and more. This XML file must contain one Context element, which will be considered as if it was the child of the Host element corresponding to the Host to which the The Tomcat configuration documentation contains information on the Context element.
}from tomcat documentation
but I still want more information about this question:
Q2: I want to distribute (sell to another organaization) without give sorce code in jsp files.So I want to precompile it to be just class files or jar files.
I want to use ant that become with netbeans 6.1.can anyone give me information about how to do that.
thank you again
Similar Threads
-
Stuck on Two Questions, Please Help
By sylo18 in forum New To JavaReplies: 5Last Post: 03-11-2008, 01:03 AM -
Just a Few Questions
By pringle in forum New To JavaReplies: 21Last Post: 01-09-2008, 06:21 PM -
few java questions
By hiaslpix in forum New To JavaReplies: 4Last Post: 01-01-2008, 05:47 AM -
questions
By Gilgamesh in forum New To JavaReplies: 3Last Post: 11-27-2007, 11:18 PM -
3 Questions
By hiranya in forum AWT / SwingReplies: 4Last Post: 11-14-2007, 04:57 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks