Re: [JBoss-user] Threads and beans
JBoss *is* acting according to spec and your disappointment is unfounded. You're just confusing your session beans - and what your client stub actually represents. If you are using *stateless* session beans (SLSB), you can have as many threads share that same client stub and use it concurrently. However, that does NOT mean that the same instance of the SLSB is being used on the server side. The server is smart enough to make sure that a different bean in the container is servicing each client. A server can reuse SLSB's for the same or different clients, but *not at the same time*, and it makes sure it starts off at a fresh state before the next usage. Some containers will pool instances, some will just instantiate new ones each call. So basically, each time you call a SLSB, you are not guaranteed the same bean on the server is being used (thus the term "stateless"). Now, if you are using *stateful* session beans (SFSB), your one client stub will always point back to the same instance on the server side (thus you can save "state" in it - sort of like an HTTPSession). Each time you invoke your stub, you are guaranteed that the same instance on the server is being used (until it times out or becomes invalid for whatever reason - in which case you'll need to get a new one). You cannot share that stub with other concurrently running threads. You should probably take a closer look at the ejb spec, specifically the sections on lifecycle. Hope this helps, David -- LaBanca, Rick wrote: > I did read that session beans can't be reentrant, no threads. Well I do have > my client using the stub to one bean reference, and more than one thread use > it. > > Instead of it failing, it appears the server somehow knows, and makes the > required number of sessions needed. So if I cause three threads to go, I'll > get three sessions. > > This is all fine, but unless I'm wrong, I am doing something out of spec > and really shouldn't do what I'm doing. Instead I should have one reference > (Stub) per thread on the client. > > So I'm curious. Does it work for me the way I have it because jboss is going > beyond the spec, or am I missing something and I'm really doing things > correctly?? > > I'm actually disappointed the spec won't let me write a stateless session > bean that can deal with threads (seems pretty safe to me if I intend it). > > Rick --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
Re: AW: [JBoss-user] Jboss.net web-service.dtd?
How shoulf look like "beanJndiName" property for a bean like this: * @ejb:bean * type="Stateless" * name="QueryEngine" * jndi-name="ejb/QueryEngineRemoteHome" * local-jndi-name="ejb/QueryEngineLocalHome" * view-type="both" * * @jboss-net:web-service * urn="query" * expose-all="true" * it produces: is it correct? Conrad Dnia 2002-07-19 11:48, Użytkownik Jung , Dr. Christoph napisał: > You mean the dtd for the web-service.xml? > > Unfortunately there is no such thing, but please look at > > http://cvs.apache.org/viewcvs.cgi/~checkout~/xml-axis/java/docs/reference.ht > ml#Deployment > > for a more verbose description. > > CGJ > > -Ursprüngliche Nachricht- > Von: conrad [mailto:[EMAIL PROTECTED]] > Gesendet: Freitag, 19. Juli 2002 15:08 > An: [EMAIL PROTECTED] > Betreff: [JBoss-user] Jboss.net web-service.dtd? > > > Hi everyone > > Is there web-service.dtd available anywere? > > Cheers > Conrad? > > > > > > --- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf ___ > JBoss-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-user > ### > > This message has been scanned by F-Secure Anti-Virus for Microsoft Exchange. > For more information, connect to http://www.F-Secure.com/ > > > --- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-user > --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Jboss.net web-service.dtd?
Conrad, I'm not sure, but I have had some success creating .wsr's with web-service.xml files that are identical to apache axis WSDD files. description: http://cvs.apache.org/viewcvs.cgi/~checkout~/xml-axis/java/docs/user-guide.h tml#PublishingServices example: http://cvs.apache.org/viewcvs.cgi/~checkout~/xml-axis/java/samples/userguide /example3/deploy.wsdd Not quite a dtd, but a guide to what you can put in there, if that's what you're looking for... - Matt -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of conrad Sent: Friday, July 19, 2002 9:08 AM To: [EMAIL PROTECTED] Subject: [JBoss-user] Jboss.net web-service.dtd? Hi everyone Is there web-service.dtd available anywere? Cheers Conrad? --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
Re: AW: [JBoss-user] Jboss.net web-service.dtd?
Thanks. I'll take a look. Conrad Dnia 2002-07-19 11:48, Użytkownik Jung , Dr. Christoph napisał: > You mean the dtd for the web-service.xml? > > Unfortunately there is no such thing, but please look at > > http://cvs.apache.org/viewcvs.cgi/~checkout~/xml-axis/java/docs/reference.ht > ml#Deployment > > for a more verbose description. > > CGJ > > -Ursprüngliche Nachricht- > Von: conrad [mailto:[EMAIL PROTECTED]] > Gesendet: Freitag, 19. Juli 2002 15:08 > An: [EMAIL PROTECTED] > Betreff: [JBoss-user] Jboss.net web-service.dtd? > > > Hi everyone > > Is there web-service.dtd available anywere? > > Cheers > Conrad? > > > > > > --- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf ___ > JBoss-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-user > ### > > This message has been scanned by F-Secure Anti-Virus for Microsoft Exchange. > For more information, connect to http://www.F-Secure.com/ > > > --- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-user > --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
AW: [JBoss-user] Jboss.net web-service.dtd?
You mean the dtd for the web-service.xml? Unfortunately there is no such thing, but please look at http://cvs.apache.org/viewcvs.cgi/~checkout~/xml-axis/java/docs/reference.ht ml#Deployment for a more verbose description. CGJ -Ursprüngliche Nachricht- Von: conrad [mailto:[EMAIL PROTECTED]] Gesendet: Freitag, 19. Juli 2002 15:08 An: [EMAIL PROTECTED] Betreff: [JBoss-user] Jboss.net web-service.dtd? Hi everyone Is there web-service.dtd available anywere? Cheers Conrad? --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user ### This message has been scanned by F-Secure Anti-Virus for Microsoft Exchange. For more information, connect to http://www.F-Secure.com/ --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] Re: [JBoss-user]Invalid service.xml file (was (no subject)
Hi Karl. There were only two instances that I had this error occur. 1) Incorrect syntax in my oracle-service.xml file (you did name this oracle-service.xml, right? JBoss sometimes does weird behaviour if you don't name these files something-service.xml). 2) (More frequent) The username/password you specify for Oracle don't match a valid User/Password for the Oracle Database. (Use something like SQLPlus and see if you can login using webapp/webappprod as you User/Password. -Steve Karl Koster wrote: > Group, > > I have searched the forums for any resolutions to this problem and haven't found >any. I am simply trying to configure a connection pool for an Oracle database on >JBoss 3.0.1RC1. I followed the Quick Start guide's instructions on how to do this. >The only changes made to the example where to use the thin driver and make the >nessecary changes to use JAAS instead of a user/password in the service xml. This is >the server xml file that I dervied from the example: > > > > > > > > > > > > > > > true > > > name="jboss.jca:service=XaTxCM,name=XAOracleDS"> > > jboss.jca:service=RARDeployer > > > code="org.jboss.resource.connectionmanager.RARDeployment" >name="jboss.jca:service=XaTxDS,name=XAOracleDS"> > > optional-attribute-name="OldRarDeployment">jboss.jca:service=RARDeployment,name=Minerva > JDBC XATransaction ResourceAdapter > > > > name="XADataSourceProperties" >type="java.lang.String">URL=jdbc:oracle:thin:@10.32.12.71:1521:prod > name="XADataSourceClass" >type="java.lang.String">oracle.jdbc.xa.client.OracleXADataSource > > > > > > jts.sempraProd > > > > > code="org.jboss.resource.connectionmanager.JBossManagedConnectionPool" >name="jboss.jca:service=XaTxPool,name=XAOracleDS"> > 2 > 100 > name="BlockingTimeoutMillis">5000 > 15 > > ByContainer > > > optional-attribute-name="CachedConnectionManager">jboss.jca:service=CachedConnectionManager > > > name="SecurityDomainJndiName">java:/jaas/OracleXADBRealm > optional-attribute-name="JaasSecurityManagerService">jboss.security:service=JaasSecurityManager > name="TransactionManager">java:/TransactionManager > > > > This is the login-config.xml fragment that I added: > > > > code="org.jboss.resource.security.ConfiguredIdentityLoginModule" flag="required"> > webapp > webapp > name="password">webappprod > name="managedConnectionFactoryName">jboss.jca:service=XaTxCM,name=XAOracleDS > > > > > When the server is started it produces the following messages and stack trace: > > 16:24:49,620 INFO [MainDeployer] Starting deployment of package: file:/D:/java/ > jboss-3.0.1RC1/server/default/deploy/oracle-service-sempra-prod.xml > 16:24:49,673 INFO [MainDeployer] deployment waiting for deployer: file:/D:/java > /jboss-3.0.1RC1/server/default/deploy/oracle-service-sempra-prod.xml > 16:24:49,674 INFO [MainDeployer] Deployment of package: file:/D:/java/jboss-3.0 > .1RC1/server/default/deploy/oracle-service-sempra-prod.xml is waiting for an app > ropriate deployer. > 16:24:49,692 ERROR [URLDeploymentScanner] Incomplete Deployment listing: > Packages waiting for a deployer: > [org.jboss.deployment.DeploymentInfo@c6bbeab9 { url=file:/D:/java/jboss-3.0.1RC1 > /server/default/deploy/oracle-service-sempra-prod.xml } > deployer: null > status: null > watch: file:/D:/java/jboss-3.0.1RC1/server/default/deploy/oracle-service-sempr > a-prod.xml > lastDeployed: 1026764689674 > lastModified: 1026764689675 > mbeans: > ]Incompletely deployed packages: > [org.jboss.deployment.DeploymentInfo@c6bbeab9 { url=file:/D:/java/jboss-3.0.1RC1 > /server/default/deploy/oracle-service-sempra-prod.xml } > deployer: null > status: null > watch: file:/D:/java/jboss-3.0.1RC1/server/default/deploy
[JBoss-user] Jboss.net web-service.dtd?
Hi everyone Is there web-service.dtd available anywere? Cheers Conrad? --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] JBoss 3.0.1RC1 and MySQL
We have recently upgraded to JBoss 3.0.1RC1, and embedded MySQL as the default database. Though we found it a lot less problematic to do this than in earlier versions of JBoss, we have set up a step-by-step guide on the following page, should it be of use to anyone else. http://www.dodtechnology.ie/jboss.htm --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] CPM2 Container Managed Relationships
Hello LY, not yet. But it's coming. Friday, July 19, 2002, 1:29:24 PM, you wrote: LD> Hi, LD> I'm using a fk-constraint to link two ejbEntity. the JBossCMP will LD> automatically add a foreign key to the tables. the problem is that field is LD> already exist in the table and I want the JBossCMP use this field, not to LD> create a new one. is that possible? LD> 11:39:48,112 DEBUG [Service] Create: pk=43 - 42 LD> 11:39:48,112 DEBUG [Service] Executing SQL: SELECT COUNT(*) FROM LD> SERVICEBEANTABLE WHERE MEV_PRIMARY_KEY=? AND ORDER_MEV_PRIMARY_KEY=? LD> 11:39:48,172 DEBUG [Service] Executing SQL: INSERT INTO SERVICEBEANTABLE LD> (MEV_PRIMARY_KEY, ORDER_MEV_PRIMARY_KEY, ADDITIONAL_ATTRIBUTES, FAILED, LD> FAILED_EXCEPTION, LAST_MODIFIED, MEV_TYPE, POSITION_IN_ORDER_VALUE_ARRAY, LD> SERVICE_ACTIVATOR_HOME_JNDI_NAME, STATE, SUBSCRIBER_ID, LD> ORDER_MEV_PRIMARY_KEY) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? LD> ) LD> 11:39:48,222 ERROR [Service] Could not create entity LD> SQL Exception: Column name 'ORDER_MEV_PRIMARY_KEY' appears more than once LD> times in the column list of an insert statement. LD> at LD> sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteC LD> all.java:245) LD> at LD> sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:220) LD> at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:122) LD> at RmiJdbc.RJConnectionServer_Stub.prepareStatement(Unknown Source) LD> at RmiJdbc.RJConnection.prepareStatement(RJConnection.java:109) LD> at LD> org.jboss.resource.adapter.jdbc.local.LocalConnection.prepareStatement(Local LD> Connection.java:191) LD> at LD> org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.insertEntity(JDBCCrea LD> teEntityCommand.java:186) LD> Thanks for your helps. LD> Best regards LD> LY Daniel LD> --- LD> This sf.net email is sponsored by:ThinkGeek LD> Welcome to geek heaven. LD> http://thinkgeek.com/sf LD> ___ LD> JBoss-user mailing list LD> [EMAIL PROTECTED] LD> https://lists.sourceforge.net/lists/listinfo/jboss-user -- Best regards, Alex Loubyansky --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] CPM2 Container Managed Relationships
Hi, I'm using a fk-constraint to link two ejbEntity. the JBossCMP will automatically add a foreign key to the tables. the problem is that field is already exist in the table and I want the JBossCMP use this field, not to create a new one. is that possible? 11:39:48,112 DEBUG [Service] Create: pk=43 - 42 11:39:48,112 DEBUG [Service] Executing SQL: SELECT COUNT(*) FROM SERVICEBEANTABLE WHERE MEV_PRIMARY_KEY=? AND ORDER_MEV_PRIMARY_KEY=? 11:39:48,172 DEBUG [Service] Executing SQL: INSERT INTO SERVICEBEANTABLE (MEV_PRIMARY_KEY, ORDER_MEV_PRIMARY_KEY, ADDITIONAL_ATTRIBUTES, FAILED, FAILED_EXCEPTION, LAST_MODIFIED, MEV_TYPE, POSITION_IN_ORDER_VALUE_ARRAY, SERVICE_ACTIVATOR_HOME_JNDI_NAME, STATE, SUBSCRIBER_ID, ORDER_MEV_PRIMARY_KEY) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? ) 11:39:48,222 ERROR [Service] Could not create entity SQL Exception: Column name 'ORDER_MEV_PRIMARY_KEY' appears more than once times in the column list of an insert statement. at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteC all.java:245) at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:220) at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:122) at RmiJdbc.RJConnectionServer_Stub.prepareStatement(Unknown Source) at RmiJdbc.RJConnection.prepareStatement(RJConnection.java:109) at org.jboss.resource.adapter.jdbc.local.LocalConnection.prepareStatement(Local Connection.java:191) at org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.insertEntity(JDBCCrea teEntityCommand.java:186) Thanks for your helps. Best regards LY Daniel --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] Entity-to-Entity
Vijay@winfoware wrote: >Hi all, > >Can an entity lookup another entity? >If yes how? >I am using JBOSS2.4.4 > >reply if anybody has done that. > > Sure they can. They do it exactly like everyone else. Do you have some problem with them? -- jK.MkIII --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
AW: [JBoss-user] Help on how to setup JBoss.NET with JBossAuthent icationHandler
Mitch, Please see my reply to the forum threads that explains that there are two independent security mechanisms going on and how to set them up. Wrt the AuthenticationHandler, please note that you can link it to any security domain that accepts simple principals with char[] based passwords (as the default jaas/other that comes with the jboss distro). CGJ -Ursprüngliche Nachricht- Von: Kim, Yong [mailto:[EMAIL PROTECTED]] Gesendet: Donnerstag, 18. Juli 2002 22:40 An: '[EMAIL PROTECTED]' Betreff: RE: [JBoss-user] Help on how to setup JBoss.NET with JBossAuthent icationHandler I got something from JBoss forum... but still don't know how to go about doing this... http://www.jboss.org/forums/thread.jsp?forum=137&thread=17493 Let me start with this question first. In that forum thread, it starts as "Hi, I'm using JBoss 3 + JBoss.NET server, and .NET client I set up login-config.xml, and put mailto:[EMAIL PROTECTED]] Sent: Thursday, July 18, 2002 2:55 PM To: '[EMAIL PROTECTED]' Subject: [JBoss-user] Help on how to setup JBoss.NET with JBossAuthenticationHandler Can anyone direct me where to start? Mitch --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user ### This message has been scanned by F-Secure Anti-Virus for Microsoft Exchange. For more information, connect to http://www.F-Secure.com/ --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] Entity-to-Entity
Hi all, Can an entity lookup another entity? If yes how? I am using JBOSS2.4.4 reply if anybody has done that. vijay --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] JBoss 3.0 Documentation
But to use this workbook effectively you need to have a copy of Richard Monson-Haefel's "Enterprise JavaBeans 3r edition" (ORielly), right? On 19 Jul 2002, Andreas Kuckartz wrote: > > Is JBoss 3.0 Documentation available anywhere? > > In addition to the current draft of the Quick Start guide already mentioned > several times I would like to recommend the beta version of the book "The > JBoss 3.0 Workbook For Enterprise Java Beans, 3rd Edition" which you can > download at: > http://www.titan-books.net/jbos30worfor.html > > Andreas > > > > > --- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-user > -- And did they get you to trade your heroes for ghosts? Hot ashes for trees? Hot air for a cool breeze? Cold comfort for change? And did you exchange a walk on part in the war for a lead role in a cage? - PF --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user