-
300. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
chnar Oct 11, 2004 5:14 PM (in response to vashistvishal)Hello, could i ask if somebody know why , even if i made all the tutorial done without any errors...after restarting the server, several times, i realise that updates in the database are lost after stopping jboss ......
WHY this...
I try to use another DB, such as MySQL, to replace Hsql (that infact interrest me further...) -
301. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
chnar Oct 11, 2004 5:17 PM (in response to vashistvishal)Well, actually, I tryed with a MySQL Database, and it worked as well, ...but no static update :/
-
302. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
kedarlele Nov 16, 2004 11:14 AM (in response to vashistvishal)Dear Vishal
Hi Vishal,
I am on chapter 9 of the tutorial. I am using Eclipse3.0, Lomboz 3.0, Jboss-4.0.0
I am using port 8081 instaed of 8080
Im getting the following error
Can u pls. help me opn the same.
13:46:53,442 ERROR [Engine] StandardWrapperValve[AxisServlet]: Servlet.service() for servlet AxisServlet threw exception
java.lang.NullPointerException
at org.apache.axis.message.BodyBuilder.onStartChild(BodyBuilder.java:209)
at org.apache.axis.encoding.DeserializationContextImpl.startElement(DeserializationContextImpl.java:1188)
at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at javax.xml.parsers.SAXParser.parse(Unknown Source)
at org.apache.axis.encoding.DeserializationContextImpl.parse(DeserializationContextImpl.java:257)
at org.apache.axis.MessagePart.getAsSOAPEnvelope(MessagePart.java:655)
at org.apache.axis.Message.getSOAPEnvelope(Message.java:432)
at org.apache.axis.Message.getContentType(Message.java:498)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:1027)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:372)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:75)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:44)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:169)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
at java.lang.Thread.run(Thread.java:534) -
303. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
kedarlele Nov 16, 2004 11:22 AM (in response to vashistvishal)when I execute the following in the browser it runs perfectly ok
http://localhost:8081/axis/servlet/AxisServlet
And now... Some Services
Version (wsdl)
getVersion
Administration (wsdl)
AdminService
But I get error/blank page with 500 Internal Error when I execute the following in the browser
http://localhost:8081/axis/EchoHeaders.jws?method=list
Im using eclipse 3.0, lomboz 3.0, jboss 4.0.0 and axis 1.1
Has the configuration gone wrong anywhere ?
I have been unable to generate the .wsdl file.
Thanx in Advance
Regards
Kedar Lele -
304. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
vashistvishal Feb 11, 2005 8:18 PM (in response to vashistvishal)Okie after some time i'm back to my favourite area :-).
I have posted the steps for configuring Axis1.1-1/.12 with Jboss -4.0
I hope this helps.
http://www.jboss.org/index.html?module=bb&op=viewtopic&t=60037
Vishal
http://www.tusc.com.au/tutorial/html/index.html -
305. Chapter 3: Session beans not getting data from Database
asty Feb 15, 2005 1:32 AM (in response to vashistvishal)Hi Vishal,
I am doing chapter 3. I have done everything, as told in the previous tutorials. When I run the Test Client, the result is 'null', i.e. it doesn't get any data from the database.
I checked the tables on HSQL, the data is there. Can't understand the problem.
Please help.
Abhishek -
306. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
asty Feb 16, 2005 12:41 AM (in response to vashistvishal)Hi everyone,
Please help me. I am really stuck.
I have developed both stateless and stateful session beans but they are not getting any data from database. For any query the result is null. I can't understand why. Please help me.
Abhishek -
307. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
ingrid Feb 27, 2005 9:29 PM (in response to vashistvishal)Hi,
did anyone extend the tutorial and tried, for example, to create a user ( a new customer) ?
I would like to know :
If the login screen had a 3rd button called "new user" (and suppose CustomerDaoImpl create method was completed).
How and where do you expose the necessary methods ?? -
308. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
vashistvishal Mar 2, 2005 4:56 AM (in response to vashistvishal)Okiee....
I have replied various issues with the tutorial in this thread
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3868463#3868463
as there were few bugs when i created this which i think :-) i have solved in this thread.
Appologies for such a late response..nearly after 2 yrs.. :-).
Won't get much time to update the tutorial so just replied here as i'm doing lot of work
outside my work area so feel free to contact on this.
Vishal -
309. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
ingrid Mar 4, 2005 10:56 AM (in response to vashistvishal)Nice to hear from you Vishal,
but I don't see how the bugs you mentioned in that thread relate to my question above. In my understating your tutorial builds a "read-only" app. I really need to know how to make the session and the bmp that are using dao to have create and store methods working and being used from jsp forms (leaving primary-key generation asside).
Thanks for any guide-lines. -
310. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
jbosszone Mar 5, 2005 9:58 AM (in response to vashistvishal)Changed the database from HypersonicSQL to PostgreSQL(=DefaultDS) as follows.
=== Environment:
- Linux(Red Hat Professional Workstation, Kernel 2.4.21)
- J2SE 1.4.2_04
- Eclipse 2.1.2
- JBoss 3.2.1_Tomcat 4.1.24
- Lomboz 2.1.3
- PostgreSQL 7.4.2
- Axis 1.1= Step 1: Download and install PostgreSQL(see ?INSTALL? in ?postgresql-7.4.2.tar.gz? etc. for details) - The directory is ?/usr/local/pgsql?. - Compile PostgreSQL with ?--with-java? option in ?configure? command to produce the JDBC file ?postgresql.jar?. - Add a user name ?postgres? with no password. - Set up classpath. = Step 2: Make a database in PostgreSQL - Initialize PostgreSQL and create a new database named ?MyStoreDbPgSQL? for the tutorial. - Make the tables and the data using ?myStoreSchema.script? and myStoreSchema.data?(+?myStoreSchemaDrop.script). e.g. a. Change the user in a console, i.e. ?su? then ?su postgres?. Start PostgreSQL with ?pg_ctl -w start?. b. Open a session with ?psql MyStoreDbPgSQL?. c. Copy and paste each SQL code in *.script and *.data files above.(add?;?to each SQL code) d. Keep ?PostgreSQL? running. = Step 3: Add a directory as a new server option - Copy the complete directory of ?all? under ?/JBoss-3.2.1/server? and name it ?postgres?. /JBoss-3.2.1/server |- /all |- /default |- /minimal |- /postgres - Keep the directories ?all?, ?default? & ?minimal? un-touched. - Delete all sub-directories and files under ?/server/postgres/log? and ?/temp?. (adjust access mode if any troubles during start-up of JBoss (Step 12)) = Step 4: Install JDBC driver for PostgreSQL - Delete ?hsqldb.jar? and ?hsqldb-plugin.jar? in ?/server/postgres/lib?. - Copy ?postgrsql.jar? from ?/usr/local/pgsql/share/java? to ?/server/postgres/lib?. = Step 5: Copy and modify the Server Definition File for Lomboz - Make a copy of ?jboss321all.server? in ?/opt/eclipse/plugins/com.objectlearn.jdt.j2ee/servers? as ?jboss321allpgsql.server?. - Add ?.bak? to all ?*.server? files in the directory except for ?jboss321allpgsql.server?. - In ?jboss321allpgsql.server?, a. change name=?JBOSS 3.2.1 ALL? in <serverDefinition> to name=?JBOSS 3.2.1 ALL PGSQL? b. change <startProgramArguments>-c all</startProgramArguments> to <startProgramArguments>-c postgres</startProgramArguments> c. change all of ?.../server/all/...? to ?.../server/postgres/...? d. delete following two lines in <serverClassPath> <jar type=?variable?>${classPathVariableName}/server/postgres/lib/hsqldb.jar</jar> <jar type=?variable?>${classPathVariableName}/server/postgres/lib/hsqldb-plugin.jar</jar> and add <jar type=?variable?>${classPathVariableName}/server/postgres/lib/postgresql.jar</jar> = Step 6: Prepare the Service Description File - Delete ?/server/postgres/deploy/hsqldb-ds.xml? or add ?.bak? to disable. - Copy ?postgres-ds.xml? in ?/jboss-3.2.1/docs/examples/jca? to ?/server/postgres/deploy? - In ?postgres-ds.xml?, the contents of <local-tx-datasource> are as follows; <jndi-name>DefaultDS</jndi-name> <connection-url>jdbc:postgresql://localhost/MyStoreDbPgSQL</connection-url> <driver-class>org.postgresql.Driver</driver-class> <username>postgres</username> <password></password> = Step 7: Modify the Login Config File - In ?/server/postgres/conf/login-config.xml?, the <application-policy> is as follows; <application-policy name = ?PostgresDbRealm?> <authentication> <login-module code = ?org.jboss.resource.security.ConfiguredIdentityLoginModule? flag = ?required?> <module-option name = ?principal?></module-option> <module-option name = ?userName?>postgres</module-option> <module-option name = ?password?></module-option> <module-option name = ?managedConnectionFactoryName?>jboss.jca:service=LocalTxCM,name=DefaultDS</module-option> </login-module> </authentication> </application-policy> = Step 8: Modify ?standardjaws.xml? - In ?/server/postgres/conf/standardjaws.xml?, the top parts of <jaws> are as follows; <jaws> <datasource>java:/DefaultDS</datasource> <type-mapping>PostgreSQL</type-mapping> <debag>false</debug> <default-entity> : = Step 9: Modify ?standardjbosscmp-jdbc.xml? - In ?/server/postgres/conf/standardjbosscmp-jdbc.xml?, the top parts are as follows; <jbosscmp-jdbc> <defaults> <datasource>java:/DefaultDS</datasource> <datasource-mapping>PostgreSQL</datasource-mapping> <create-table>true</create-table> : = Step 10: Modify ?jbossmq-service.xml? (for Chapter 7 and after) - In ?/server/postgres/deploy/jms/jbossmq-service.xml?, the jdbc2 Persistence Manager is as follows; : <depends optional-attribute-name=?ConnectionManager?>jboss.jca:service=LocalTxCM,name=DefaultDS</depends> <attribute name=?SqlProperties?> BLOB_TYPE=BYTES_BLOB INSERT_TX = INSERT INTO JMS_TRANSACTIONS (TXID) values(?) : : CREATE_MESSAGE_TABLE = CREATE TABLE JMS_MESSAGES (MESSAGEID INTEGER NOT NULL, \ DESTINATION VARCHAR(150) NOT NULL, TXID INTEGER, TXOP CHAR(1), \ MESSAGEBLOB BYTEA, PRIMARY KEY (MESSAGEID, DESTINATION) ) CREATE_TX_TABLE = CREATE TABLE JMS_TRANSACTIONS (TXID INTEGER) CREATE_TABLES_ON_STARTUP = true </attribute> : *** Start Eclipse and build a new project as MyStorePgSQL. = Step 11: Confirm ?xdoclet.xml? is with PostgreSQL - In ?/MyStorePgSQL/MyStoreMgr/META-INF/xdoclet.xml?, the JBoss part is as follows; <jboss : datasource=?java:/DefaultDS? datasourcemapping=?PostgreSQL? preferredrelationmapping=?foreign-key? /> : = Step 12: Start JBoss from ?Lomboz J2EE View? - If any failure/error messages such as ?XAConnectionFactory not bound? appear during start-up process, stop JBoss (keep PostgreSQL running) and check the tables in the database. a. $ psql MyStoreDbPgSQL b. =# \dt - if the tables ?jms_messages? and ?jms_transactions? exist, drop both of them. c. =# DROP TABLE jms_messages; d. =# DROP TABLE jms_transactions; - Re-start JBoss
jbosszone -
311. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
chrispp Mar 11, 2005 2:01 AM (in response to vashistvishal)Hi JBoss beginners corner,
I am looking for help about using Lomboz and JBoss within Eclipse IDE. I wanna know latest versions of all the three components that can be used together. I have tried to use JBoss 3.2.6 instead of 3.2.1 in the Tusc tutorial, but no way to find out how to write my own jboss321All.server file correctly. Can anyone tell me more about this !
regards. -
312. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
vashistvishal Mar 23, 2005 8:27 AM (in response to vashistvishal)I 'm currently looking for volunteers to update this tutorial with new JBoss-4.0 and other additions...
I have my own blog site so will be adding the roadmap of this very soon...and also looking for a space to host the new tutorial.
http://vashistvishal.blogspot.com/
Please feel free to contact on this blog.
Vishal -
313. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
vashistvishal Apr 7, 2005 1:32 AM (in response to vashistvishal)I have posted a new thread for the feedback required on the new version of tutorial, please provide yr feedback.
https://www.jboss.org/index.html?module=bb&op=viewtopic&t=62314 -
314. Re: Tutorial on J2EE using JBOSS, Eclipse and Lomboz.
andresfelipeclaros Apr 20, 2005 7:22 PM (in response to vashistvishal)thanks,
Its works.
I had many problems whit this situation. Almost dont found the solution.
Andres Claros