RE: [JBoss-user] JBoss Book
All what I can tell you is that I bought the book and alreay received two mails from flashline that warned me to download updated version...for free. The book is always acurate to latest 2.4 branch as far as I have seen. As the jboss site tells you it will be the SAMS printed book. Do not hesitate one second to buy the book, 10$ for 448 pages. Jboss is explained in great detail. You learn how to deploy on Jboss but also what is an EJB container and how it does work from the trenches. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] On Behalf Of Keith Kee Sent: jeudi 24 janvier 2002 18:51 To: [EMAIL PROTECTED] Subject: [JBoss-user] JBoss Book Hi: I am considering buying the latest softcopy of the JBoss book written by Scott. However, one thing that came to mind is that if I bought it now, how do I get subsequent updates for that book? Is this going to be the eventual printed book by SAMS? Thanks keith ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Updating CastorJDO plugin for 2.4.4
I apologize in advance for introducing me in this thread... > Dain, > > full rundown is at http://www.castor.org/locking.html but my > brief version here... (forgive me if any of this comes > across as patronizing, not sure how much exposure you've had > to castor) > > say I had ejb and web tiers in the same jvm, and a jsp was > provided with a collection of objects to display. > > in castor, I could have two requests at the same time, both > given the same collection of objects, and access them in a > read-only fashion concurrently. > > (as I understand) with entity beans, using finder methods, as > soon as one entity was accessed, even in a read-only fashion, > it would be locked for the duration of that tx yes? so the > second request would have to wait until the first tx has > finished. the common workaround is to write the query > yourself in jdbc, and use a non-ejb approach Is this problem not solved using EntityMultiInstanceInterceptor ? I mean commit-option "any" / EntityInstanceInterceptor seems to serialize access to the Cache. Then I agree with you. Have you try to swicth to commit-option B/C / EntityMultiInstanceInterceptor ? What I don't understand yet is that plus the Entity/Method Lock interceptors plus the locking-policy that can be used along with that. That mixed with the fact that finder methods create multiple instances and I am in a black hole... > > I know that read-only beans could solve this in some cases, > but obviously not all. My real problem with the jdbc > approach is that hte container already has all the > information required to create the sql. > > a while back, I tried to create some new functionality for > jboss, got it working nicely, but then faded away - > essentially, for each finder method, I made a query method - > basically following the architecture you have for the jaws > stuff - I mirrored FindEntitiesCOmmand with a > QueryEntitiesCommand (with a little refactoring to suit), and > in jboss.xml had a spot for someone to declare the class the > populate. so the home interface then has: > > public Collection findByXXX(); > public Collection queryByXXX(); > > the finder method of course returns ejbobjects, with all the > spec behaviour. the query method returns a collection of > dataobjects, the dataobject having the same set/get methods > as the entity bean, but is actually a copy of the data. > > I had a fair bit of fun doing this, but got stumped on how to > handle relationships anyway, not sure that you couldn't > think of a much better way to solve the problem, but thought > it might be worth sharing, just seems that using jdbc for > read-only access was quite common, and could be another area > where jboss could make it easier for the user > > would like to hear your thoughts on this, and also any more > feedback on the castor issue. > > cheesr > dim > _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Mbean classloader bug !
Marc, This is as it should be, ok. But,... We loose the RE deployment facility because lib/ext is not dynamic. We have to shutdown/restart Jboss to see the changes. Does Jboss 3.0 have re-deployment facility of lib/ext classes ? Or is it recommended to put a "proxy" or "command" ejb between Mbean and the EJB we want to talk to. This EJB would never change and so does not need re-deployment. I don't specifically see re-deployment of ejbs as a developement facility but also as a configuration one. Regards. Vincent. > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]] On Behalf Of > marc fleury > Sent: jeudi 1 novembre 2001 0:24 > To: Carsten Rhod Gregersen; David Jencks; > [EMAIL PROTECTED] > Subject: RE: [JBoss-user] Mbean classloader bug ! > > > reread david's mail > > marcf > > |-Original Message- > |From: [EMAIL PROTECTED] > |[mailto:[EMAIL PROTECTED]]On Behalf Of Carsten > |Rhod Gregersen > |Sent: Wednesday, October 31, 2001 5:49 PM > |To: David Jencks; [EMAIL PROTECTED] > |Subject: RE: [JBoss-user] Mbean classloader bug ! > | > | > |Hej David, > | > |Sorry, by either I do not understand you, or I my earlier posts was > |inprecise. > | > |Yes, the mbean should be able to see the interfaces, no > doubt.. It's a > |client just like anyone else... > | > |But hello... I'm not saying that you should put the > implementation in > |the mbean path... I'm saying that it should be posible to > both put the > |interfaces in the mbean.jar and in the ejb.jar > | > |But the problem arises if you put the interfaces in the > lib/ext somehow > |together with the mbean. > | > |Jboss will then go bazuka if you also put them together with the > |ejbclasses (implementation)... And this I find to be a problem. > | > |For example sessionbeans mostly need to see the remote and home > |interface of certain entity beans. Therefore I will need to > package an > |application in one way if I use some of the interfaces from > an mbean, > |and another way if I dont > | > |This, I find wrong... my 2 øre :-) > | > |/Carsten > | > | > |-Original Message- > |From: [EMAIL PROTECTED] > |[mailto:[EMAIL PROTECTED]]On Behalf Of David > |Jencks > |Sent: 31. oktober 2001 23:17 > |To: [EMAIL PROTECTED] > |Subject: Re: [JBoss-user] Mbean classloader bug ! > | > | > |This is as it should be, IMHO. the mbeans are part of the > server, the > |ejb interfaces are by default part of the application. Why > should the > |server be able to see the application classes? The > application classes > |can see the server classes, but not vice versa. If you want > the server > |to use application classes, put those in the "server > classpath", namely > |lib.ext > | > |david jencks > | > |On 2001.10.31 14:57:54 -0500 Carsten Rhod Gregersen wrote: > |> Hi, > |> > |> From what I've heard so far, I'm pretty sure that there's > |> a bug in the Mbean classloader. Everybody that has gotten > mbean's to > |> interact with the container does it via this method: > |> > |> 1. Put interfaces in the mbean jar files > |> 2. Put the rest in the ejb files... > |> > |> This is wrong aprocedure is it not ? > |> Normally you package both the implementation AND the > interfaces and > |> deploy them into the container, or ??? > |> > |> Still as I say, I will look into it if necesarry, but if > |> the container is allready acting as it should (e.g. pr > specification > |> of mbeans), I would just be wasting my time (and we can't have > |> that :-) > |> > |> My wish would be that each mbean gets it's own > classloader, or that > |> you at least could specify the ones that should be loaded without > |> interfering with other lib/ext jar's or ejb packages. This way we > |> would not get all the classloading conflicts... > |> > |> /Carsten > |> > |> -Original Message- > |> From: [EMAIL PROTECTED] > |> [mailto:[EMAIL PROTECTED]]On Behalf > Of Carsten > |> Rhod Gregersen > |> Sent: 31. oktober 2001 17:15 > |> To: [EMAIL PROTECTED] > |> Subject: RE: [JBoss-user] Mbean using the home and remote beans - > |> classloader bug in mbeans ? > |> > |> > |> Hi, > |> > |> I actually think we can do that too... > |> But that's a hack... isn't it ? > |> You package ONLY the bean implementation in the > |> ear file, and that is not correct as to the ejb > |> standard where you have to package both the remote > |> homes and beans together, or am I wrong ? > |> > |> /Carsten > |> > |> -Original Message- > |> From: [EMAIL PROTECTED] > |> [mailto:[EMAIL PROTECTED]]On Behalf > Of Sternagel > |> Annegret (PN-SYS/PE) > |> Sent: 31. oktober 2001 15:05 > |> To: [EMAIL PROTECTED] > |> Subject: Re: [JBoss-user] Mbean using the home and remote beans - > |> classloader bug in mbeans ? > |> > |> > |> I don't know if this will help You ... > |> > |> We are using jboss 2.4.3 (standalone) on Windows NT / 2000 and we > |> access Stateful SessionBeans in a MBean using reflection. > We package
RE: [JBoss-user] DataSource declaration. Help again!
Hi, > Hi, > > I always have the problem of datasource declaration. I found a "solution" > (from these mailing-list threads) but I don't understand how it > can work! :o) > > jboss.xml: > > [...] > "http://www.jboss.org/doco_files/jboss.dtd";> > > > > > ConnectionFactory > ejb/ConnectionFactoryEJB > > > jdbc/DbPool > javax.sql.DataSource > java:/DbPool > > > > > > Then my EJB can access to this pool, with > lookup("java:comp/env/jbdc/DbPool"), as expected (I assume here the > ejb-jar.xml respect the EJB 1.1 specification recommendation). > > First of all, why does JBoss accept this jboss.xml file that > doesn't respect > the DTD?... The element is supposed to accept only two > elements, and . This way of defining resource is correct. Go through a resource manager is not "absolutely" needed. > > The correct datasource declaration may be this one: > > > [...] > > > [...] > > jdbc/DbPool > DbPool > > > > > > DbPool > java:/DbPool > > > > > > But, then my EJB can't access to this pool with a > lookup("java:comp/env/jbdc/DbPool"), but with a lookup("java:/DbPool"). It should work as you explain it. I will try that. The use of resource-manager is simply an indirection inside the DD. A summary could be : A resource reference is unique for a Bean A resource manager is unique for an ejb jar A Connection Pool is unique for the JBoss server. > > More than two days on this problem, but I still miss something... ;o) > > Any JBoss gurus there that can help the poor JBoss newbie I am ? > > > Daniel > > "Rien n'est moins sûr que l'incertain..." [Pierre Dac] Vincent. "Maintenant je sais,... je sais qu'on ne sait jamais" [Jean Gabin] ;-) _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Possible Bug with Minerva XADataSourceImpl and Opta's XDataSource
Hi, Strange. What is the trans-attribute of your session bean method ? And more generally : is it really the jdbc layer that is in cause ? Are you sure to not have a transaction open ? Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Kevin > Meldorf (NBK) > Envoyé : vendredi 3 août 2001 16:16 > À : '[EMAIL PROTECTED]' > Cc : '[EMAIL PROTECTED]' > Objet : [JBoss-user] Possible Bug with Minerva XADataSourceImpl and > Opta's XDataSource > > > There seems to be a problem when declaring a method with the > RequiresNew transaction attribute. I have tested this with both > Minerva's org.opentools.minerva.jdbc.xa.wrapper.XADataSourceImpl > and Opta's com.inet.tds.XDataSource -- in fact, Opta's was *really* not > working, but they have recently implemented a fix which now > duplicates what > I see to be a problem with the Minerva XADataSource. > > Here's the deal for those of you still with me: > > I have a PkEntity Bean that performs one function getNextId(). I have > declared this method with the RequiresNew Transaction attribute in > ejb-jar.xml. > > > > > PkTable > getNextId > > RequiresNew > > > > > Now I have a method in a session bean that performs 3 calls: > 1. getNextId() > 2. creates an entity in a user table (where the id is used) > 3. create an entity in a user address table. > > If I throw a RemoteException in #3, all 3 transactions roll back. > > Correct me if I am wrong, but #1 getNextId, since it is declared as > RequiresNew, should have completed/committed and not rolled back. > > Has anyone else experienced this problem? Am I doing something wrong? > > I am using jboss version 2.2.2 on Windows 2000 with MSSQLServer2000 > using the Opta2000jdbc driver and I have the very latest version of the > driver. > > If this is a bug, I will be happy to post it on Source Forge. > > Thanks, > > Kevin > > Kevin Meldorf > Systems Analyst > WorldTravel BTI > 400 Skokie Blvd > Northbrook, IL 60062 > Phone: (847) 480-8340 > [EMAIL PROTECTED] > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] JBoss and JDO
Hi, AFAIK, Sap announces the support of JCA through InQMy Resource Adapter. Nothing about JDO. I still don't see JDO as widely accepted and avoid to use it. Are you talking about this product ? Else can you point me which one ? I have looking for such a SAP RA for some time now and was always amazed by the price of them. Regards. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Paul > McLachlan > Envoyé : mercredi 1 août 2001 6:47 > À : [EMAIL PROTECTED] > Objet : RE: [JBoss-user] JBoss and JDO > > > I have to integrate JBoss with SAP I have found an SAP resourceAdapter > which seems to work and integrate with JBoss what would be great would > be an SAP JDO compliant data store which integrates with JBoss, > > am I asking too much? > > Paul. > > > -Original Message- > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] > > Sent: Wednesday, 1 August 2001 12:18 PM > > To: [EMAIL PROTECTED] > > Cc: [EMAIL PROTECTED]; > > [EMAIL PROTECTED] > > Subject: Re: [JBoss-user] JBoss and JDO > > > > > > > > I wholeheartedly agree with this article. I am on a project where we > > originally were using entity beans, but we switched to using > > JDO because > > they are much easier to program with a LOT less overhead. > > Most of the time > > developers end up writing dependent objects for entity beans > > anyway, so why > > not just program like that from the start? Actually, I > > haven't seen any > > situations where I would use entity beans over JDO (and would > > love it if > > someone could suggest why I would). All the hype over CMP 2.0 > > seems way > > overdone considering JDO has provided relationships for a while. > > > > The good news is that JBoss does support JDO! It uses the > > Castor plugin > > (note Castor isn't a Sun-compatible JDO implementation, but it works > > great). Check out http://www.jboss.org/jboss-castor.jsp. > > Castor is easy to > > use, and it integrates right into a J2EE server like JBoss > > (for example, it > > will use the resource manager and transaction attributes of the method > > under which it is called). > > > > Alex > > > > > > > > > > > > "Paul McLachlan" > > > > <[EMAIL PROTECTED]> To: > > <[EMAIL PROTECTED]> > > Sent by:cc: > > > > [EMAIL PROTECTED] > > Subject: [JBoss-user] JBoss and JDO > > > > eforge.net > > > > > > > > > > > > 07/31/2001 08:26 PM > > > > Please respond to jboss-user > > > > > > > > > > > > > > > > > > > > This is an interesting discussion on the benefits and drawbacks on JDO > > and ejb2.0 > > > > I would be interested to know if JBoss will implement JDO. > > > > http://www.theserverside.com/discussion/thread.jsp?thread_id=771 > > > > > > ___ > > JBoss-user mailing list > > [EMAIL PROTECTED] > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > > > > > > > > > > ___ > > JBoss-user mailing list > > [EMAIL PROTECTED] > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] release date for 2.4? Tomcat 3.2.3?
Hi, About tomcat 3.2.3: It is a minor update, Just 3 jars have changed, the conf/ did not change at all. Download from Jakarta, overwrite the tomcat/lib/ directory and it works. About 2.4: I think it was planned for end of july. Vincent. > Just wondering when 2.4 is expected to be out of beta. Also, curious > if, for the Tomcat bundling, if 3.2.3 will be used. _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] altered entity bean deployment
http://www.jboss.org/documentation/HTML/ch05s03.html > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de ALex > Loubyansky > Envoyé : mercredi 18 juillet 2001 10:27 > À : [EMAIL PROTECTED] > Objet : [JBoss-user] altered entity bean deployment > > > hi > > I developed an enitity bean with two cmp fields and > deployed it. Then I > added to it one more cmp field and deployed it again. But I can't > work with > it. Because table in Hypersonic still has only two fields. How can I solve > it? > > ALex > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Jboss and sapdb
http://www.jboss.org/documentation/HTML/ch06s08.html > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Hermann > RANGAMANA > Envoyé : mercredi 18 juillet 2001 10:02 > À : [EMAIL PROTECTED] > Objet : Re: [JBoss-user] Jboss and sapdb > > > Hi all, > > how can specify commit options for entity beans ?? > > --Hermann > > PS : Forgive for the elementary question > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Where are ejb.jar and ejb2.0.jar in 2.4?
They are now part of jboss-j2ee.jar (along with jms, transaction and jca). > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Hunter > Hillegas > Envoye : mardi 17 juillet 2001 18:11 > A : JBoss 2 > Objet : [JBoss-user] Where are ejb.jar and ejb2.0.jar in 2.4? > > > I just noticed that ejb.jar and ejb2.0.jar not in jboss/lib/ext > in the 2.4.0 > binary. > > Where are they now? > > I checked the CHANGELOG and no mention of them moving... Also, a mailing > list search turned up nothing... > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] DataSource
jboss-jdbc_ext.jar > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Richard > Bottoms > Envoye : dimanche 8 juillet 2001 19:06 > A : [EMAIL PROTECTED] > Objet : Re: [JBoss-user] DataSource > > > At 07:15 AM 7/8/01 -0400, you wrote: > >your lookup is wrong. assuming you have a resource reference in your > >web.xml and a mapping in jboss-web.xml then you should be able to > >lookup the datasource with... > > > >DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/mysql"); > > > >Al > > I must be missing an import of some kind: > > org.apache.jasper.JasperException: Unable to compile class for > JSP/usr/jboss2/tomcat/work/localhost_8080%2Fj2ee/_0002ftestMysql_0 > 0032_0002e > jsptestMysql2_jsp_3.java:80: Class DataSource not found. > DataSource ds = > (DataSource)ctx.lookup("java:comp/env/jdbc/mysql"); > ^ > > > r.b. > > > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] [Microsoft][ODBC SQL Server Driver]Optional feature not implemented
INET drivers need 4.10FIX version (info coming to me privately last week). Use Minerva Pool for the moment(don't know if this version is downloadable) org.jboss.pool.jdbc.xa.wrapper.XADataSourceImpl <=== or org.minerva.blablabla for JBoss 2.2 SQLServerPool jdbc:inetdae7:localhost sa JDBC-ODBC have not enough implemented fetaures to be usable, if I am wrong I would like to know someone that uses it... Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Guy Laurent > Envoyé : dimanche 8 juillet 2001 15:47 > À : [EMAIL PROTECTED] > Objet : Re: [JBoss-user] [Microsoft][ODBC SQL Server Driver]Optional > feature not implemented > > > The server log follow for the error in the Subject field when > using the ODBC > bridge. Also, see below, I have changed the driver to the inet > one. Still no > luck but an error of a similar nature. > > [JAWS] java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Optional > feature not implemented > [JAWS] at sun.jdbc.odbc.JdbcOdbc.createSQLException(JdbcOdbc.java:6031) > [JAWS] at sun.jdbc.odbc.JdbcOdbc.standardError(JdbcOdbc.java:6188) > [JAWS] at > sun.jdbc.odbc.JdbcOdbc.SQLBindInParameterNull(JdbcOdbc.java:922) > [JAWS] at > sun.jdbc.odbc.JdbcOdbcPreparedStatement.setNull(JdbcOdbcPreparedSt > atement.ja > va:359) > [JAWS] at > org.opentools.minerva.jdbc.PreparedStatementInPool.setNull(Prepare > dStatement > InPool.java:92) > [JAWS] at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand.setParameter(JDBCComma > nd.java:28 > 0) > [JAWS] at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCreateEntityCommand.setParamet > ers(JDBCCr > eateEntityCommand.java:165) > [JAWS] at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand.jdbcExecute(JDBCComman > d.java:159 > ) > [JAWS] at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCreateEntityCommand.execute(JD > BCCreateEn > tityCommand.java:135) > [JAWS] at > org.jboss.ejb.plugins.jaws.JAWSPersistenceManager.createEntity(JAW > SPersisten > ceManager.java:122) > [JAWS] at > org.jboss.ejb.plugins.CMPPersistenceManager.createEntity(CMPPersis > tenceManag > er.java:207) > [JAWS] at > org.jboss.ejb.EntityContainer.createHome(EntityContainer.java:441) > [JAWS] at java.lang.reflect.Method.invoke(Native Method) > [JAWS] at > org.jboss.ejb.EntityContainer$ContainerInterceptor.invokeHome(Enti > tyContaine > r.java:639) > [JAWS] at > org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invokeHome( > EntitySync > hronizationInterceptor.java:160) > [JAWS] at > org.jboss.ejb.plugins.EntityInstanceInterceptor.invokeHome(EntityI > nstanceInt > erceptor.java:87) > [JAWS] at > org.jboss.ejb.plugins.TxInterceptorCMT.invokeNext(TxInterceptorCMT > .java:135) > [JAWS] at > org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInter > ceptorCMT. > java:263) > [JAWS] at > org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT > .java:86) > [JAWS] at > org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInter > ceptor.jav > a:164) > [JAWS] at > org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:106) > [JAWS] at > org.jboss.ejb.EntityContainer.invokeHome(EntityContainer.java:316) > [JAWS] at > org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invokeHome( > JRMPContai > nerInvoker.java:369) > [JAWS] at java.lang.reflect.Method.invoke(Native Method) > [JAWS] at > sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:241) > [JAWS] at sun.rmi.transport.Transport$1.run(Transport.java:142) > [JAWS] at java.security.AccessController.doPrivileged(Native Method) > [JAWS] at sun.rmi.transport.Transport.serviceCall(Transport.java:139) > [JAWS] at > sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:443) > [JAWS] at > sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransp > ort.java:6 > 43) > [JAWS] at java.lang.Thread.run(Thread.java:484) > [Bean Cache] Resized cache for bean Advert: old capacity = 1000, new > capacity = 50 > > > I have defined that table in my jaxs.xml and im sure the jcml > file is right. > Those are also pasted below. Sorry for the amount of text. > > [JAWS] java.sql.SQLException: [GUY]Invalid object name 'ADVERT'. > [JAWS] at com.inet.tds.a.a(Unknown Source) > [JAWS] at com.inet.tds.b.do(Unknown Source) > [JAWS] at com.inet.tds.b.executeQuery(Unknown Source) > [JAWS] at com.inet.pool.b.executeQuery(Unknown Source) > [JAWS] at > org.jboss.ejb.plugins.jaws.jdbc.JDBCQueryCommand.executeStatementA > ndHandleRe > sult(JDBCQueryCommand.java:58) > [JAWS] at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand.jdbcExecute(JDBCComman > d.java:160 > ) > [JAWS] at > org.jboss.ejb.plugins.jaws.jdbc.JDBCBeanExistsCommand.execute(JDBC > BeanExists > Command.java:46) > [JAWS] at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCreateEntityCommand.execute(JD > BCCreateEn > tityCommand.java:126) > [JAWS] at > org.jboss.ejb.plugins.jaws.JAWSPersistenceManager.createEntity(JAW > SPersisten > ceManager.java:122) > [
RE: [JBoss-user] Problem with cmp-jaws example
You find a 2.2 non compliant feature. It is a 2.4 feature. I will update the zip files on the web site. For you to continue, comment out lesson.subject and lesson.hours in jaws.xml. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Laurel > Neustadter > Envoyé : vendredi 6 juillet 2001 19:09 > À : '[EMAIL PROTECTED]' > Objet : [JBoss-user] Problem with cmp-jaws example > > > Hi: > > I am working through the examples in the JBoss Manual. Everything > has worked > fine until Chapter 5: Customizing Jaws. > I successfully ran "ant cmp-jaws-compile", but when I drop > "documentation-example/build-examples/cmp-jaws/ejb/class.jar" into the > deploy directory I get the following error. How do I fix this? Thanks. > > [J2EE Deployer Default] Starting class.jar failed! > [Auto deploy] org.jboss.ejb.DeploymentException: Could not deploy > file:/D:/JBoss > -2.2.2_Tomcat-3.2.2/jboss/tmp/deploy/Default/class.jar, > Cause:org.jboss.ejb.Depl > oymentException: Error in jaws.xml for Entity ClassBean: cmp-field > lesson.subjec > t is not a field in ejb class org.jboss.docs.cmp.jaws.bean.ClassBean > [Auto deploy] at > org.jboss.ejb.ContainerFactory.deploy(ContainerFactory.java:3 > 65) > [Auto deploy] at > org.jboss.ejb.ContainerFactory.deploy(ContainerFactory.java:2 > 75) > [Auto deploy] at java.lang.reflect.Method.invoke(Native Method) > [Auto deploy] at > com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl > .java:1628) > [Auto deploy] at > com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl > .java:1523) > [Auto deploy] at > org.jboss.deployment.J2eeDeployer.startApplication(J2eeDeploy > er.java:415) > [Auto deploy] at > org.jboss.deployment.J2eeDeployer.deploy(J2eeDeployer.java:17 > 8) > [Auto deploy] at java.lang.reflect.Method.invoke(Native Method) > [Auto deploy] at > com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl > .java:1628) > [Auto deploy] at > com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl > .java:1523) > [Auto deploy] at > org.jboss.ejb.AutoDeployer.deploy(AutoDeployer.java:358) > [Auto deploy] at org.jboss.ejb.AutoDeployer.run(AutoDeployer.java:221) > [Auto deploy] at java.lang.Thread.run(Unknown Source) > [J2EE Deployer Default] Module class.jar is not running > [J2EE Deployer Default] Destroying application class.jar > [Auto deploy] Deployment > failed:file:/D:/JBoss-2.2.2_Tomcat-3.2.2/jboss/deploy/c > lass.jar > [Auto deploy] org.jboss.deployment.J2eeDeploymentException: Error while > starting > class.jar: Could not deploy > file:/D:/JBoss-2.2.2_Tomcat-3.2.2/jboss/tmp/deploy/ > Default/class.jar > [Auto deploy] at > org.jboss.deployment.J2eeDeployer.startApplication(J2eeDeploy > er.java:442) > [Auto deploy] at > org.jboss.deployment.J2eeDeployer.deploy(J2eeDeployer.java:17 > 8) > [Auto deploy] at java.lang.reflect.Method.invoke(Native Method) > [Auto deploy] at > com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl > .java:1628) > [Auto deploy] at > com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl > .java:1523) > [Auto deploy] at > org.jboss.ejb.AutoDeployer.deploy(AutoDeployer.java:358) > [Auto deploy] at org.jboss.ejb.AutoDeployer.run(AutoDeployer.java:221) > [Auto deploy] at java.lang.Thread.run(Unknown Source) > > Laurel > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] EJBDoclet / JBoss entity bean Cache Problems / IllegalStateException in JDBCCommand
Hi, This problem may be interresting for ejbdoclet/jboss users. But it can happen to other as well, if you picked up your template PK class from a book, ... I faced a problem, in fact different problems during... well some time now... on entity beans accessed by session beans. It gives strange things like - having database updated but not the bean instance - IllegalStateException in JDBCCommand() - maybe others I shout on JBoss, on the cache, on myself, ... Very stange things that were in fact caused by a very simple stuff: the hashCode() method of the Primary Key class. If it contains private attributes, you have to make these as transient. Another solution was to add a toString() method, which in fact is not bad idea, a lot more easy to follow what happens in debug mode :) For EJBDoclet, this means having : ==> transient private int _hashCode = Integer.MIN_VALUE; <== here we are !!! public java.lang.String pk; public MasterDOPK() { } public MasterDOPK(java.lang.String pk) { this.pk = pk; } public java.lang.String getPk() { return pk; } public int hashCode() { if (_hashCode == Integer.MIN_VALUE) { _hashCode += this.pk.hashCode(); } return _hashCode; } public boolean equals(Object obj) { if (!(obj instanceof com.hm.test.jboss.interfaces.MasterDOPK)) return false; com.hm.test.jboss.interfaces.MasterDOPK pk = (com.hm.test.jboss.interfaces.MasterDOPK)obj; boolean eq = true; eq = eq && this.pk.equals(pk.pk); return eq; } Hope this can solve other nights ;) It was a weird one really. A good rule to follow is If your entity bean and your db does not go OK 1. Play with commit-option A, B, C / understand what is a transaction (run alone on the system) 2. Set the cache-size to min/max 1/1 OR to very big values as well as the overager periods (to reproduce the problem) 3. don't shout on JBoss Cache bug 4. Look at your hashCode method of your PK Class, add a toString method 5. Blame yourself not JBoss Regards. Vincent. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] CDBean example - error when running Upload - jboss2.2.2
It seems you have spaces in the directory where JBoss is installed ? Don't do that. IMHO Interest work because you do not have a intra-JBoss JNDI lookup. Vincent. -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de Store Builder - info Envoyé : jeudi 5 juillet 2001 20:27 À : [EMAIL PROTECTED] Objet : [JBoss-user] CDBean example - error when running Upload - jboss2.2.2 I just downloaded jboss2.2.2 to try it out. Setup and ran the "interest" example ok, but when running the upload client for "CDBean" example after compiling and deploying with ANT, I get the following output in my jboss console: btw, I'm running win2000 workstation, not the server (does this matter?). I've been struggling with this for a day now. Any help is appreciated. [CDCollectionBean] TRANSACTION ROLLBACK EXCEPTION:null; nested exception is: javax.ejb.EJBException [CDCollectionBean] javax.naming.CommunicationException. Root exception is java. net.MalformedURLException: no protocol: files/JBoss-2.2.2/tmp/deploy/Default/cd. jar/ejb1004.jar [CDCollectionBean] at java.net.URL.(Unknown Source) [CDCollectionBean] at java.net.URL.(Unknown Source) [CDCollectionBean] at java.net.URL.(Unknown Source) [CDCollectionBean] at sun.rmi.server.LoaderHandler.pathToURLs(Unknown Sourc e) [CDCollectionBean] at sun.rmi.server.LoaderHandler.loadClass(Unknown Source ) [CDCollectionBean] at sun.rmi.server.MarshalInputStream.resolveClass(Unknow n Source) [CDCollectionBean] at java.io.ObjectInputStream.inputClassDescriptor(Unknow n Source) [CDCollectionBean] at java.io.ObjectInputStream.readObject(Unknown Source) [CDCollectionBean] at java.io.ObjectInputStream.readObject(Unknown Source) [CDCollectionBean] at java.io.ObjectInputStream.inputClassFields(Unknown So urce) [CDCollectionBean] at java.io.ObjectInputStream.defaultReadObject(Unknown S ource) [CDCollectionBean] at java.io.ObjectInputStream.inputObject(Unknown Source) [CDCollectionBean] at java.io.ObjectInputStream.readObject(Unknown Source) [CDCollectionBean] at java.io.ObjectInputStream.readObject(Unknown Source) [CDCollectionBean] at org.jboss.ejb.plugins.jrmp.interfaces.HomeProxy.readE xternal(HomeProxy.java:267) [CDCollectionBean] at java.io.ObjectInputStream.inputObject(Unknown Source) [CDCollectionBean] at java.io.ObjectInputStream.readObject(Unknown Source) [CDCollectionBean] at java.io.ObjectInputStream.inputClassFields(Unknown So urce) [CDCollectionBean] at java.io.ObjectInputStream.defaultReadObject(Unknown S ource) [CDCollectionBean] at java.io.ObjectInputStream.inputObject(Unknown Source) [CDCollectionBean] at java.io.ObjectInputStream.readObject(Unknown Source) [CDCollectionBean] at java.io.ObjectInputStream.readObject(Unknown Source) [CDCollectionBean] at java.rmi.MarshalledObject.get(Unknown Source) [CDCollectionBean] at org.jnp.interfaces.NamingContext.lookup(NamingContext .java:353) [CDCollectionBean] at org.jnp.interfaces.NamingContext.lookup(NamingContext .java:333) [CDCollectionBean] at javax.naming.InitialContext.lookup(Unknown Source) [CDCollectionBean] at org.jboss.docs.cmp.cd.bean.CDCollectionBean.getHome(C DCollectionBean.java:32) [CDCollectionBean] at org.jboss.docs.cmp.cd.bean.CDCollectionBean.findAll(C DCollectionBean.java:130) [CDCollectionBean] at java.lang.reflect.Method.invoke(Native Method) [CDCollectionBean] at org.jboss.ejb.StatelessSessionContainer$ContainerInte rceptor.invoke(StatelessSessionContainer.java:472) [CDCollectionBean] at org.jboss.ejb.plugins.StatelessSessionInstanceInterce ptor.invoke(StatelessSessionInstanceInterceptor.java:87) [CDCollectionBean] at org.jboss.ejb.plugins.TxInterceptorCMT.invokeNext(TxI nterceptorCMT.java:133) [CDCollectionBean] at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransac tions(TxInterceptorCMT.java:263) [CDCollectionBean] at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInter ceptorCMT.java:99) [CDCollectionBean] at org.jboss.ejb.plugins.SecurityInterceptor.invoke(Secu rityInterceptor.java:190) [CDCollectionBean] at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterc eptor.java:195) [CDCollectionBean] at org.jboss.ejb.StatelessSessionContainer.invoke(Statel essSessionContainer.java:271) [CDCollectionBean] at org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoke r.invoke(JRMPContainerInvoker.java:392) [CDCollectionBean] at java.lang.reflect.Method.invoke(Native Method) [CDCollectionBean] at sun.rmi.server.UnicastServerRef.dispatch(Unknown Sour ce) [CDCollectionBean] at sun.rmi.transport.Transport$1.run(Unknown Source) [CDCollectionBean] at java.security.AccessController.doPrivileged(Native Me thod) [CDCollectionBean] at sun.rmi.transport.Transport.serviceCall(Unknown Sourc e) [CDCollectionBean] at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unk now
RE: [JBoss-user] CMP Entity Bean using Opta2000 Driver - Has Anyone got this to work???
I faced the problem also. I cime back to using Minerva Pool DataSource instead of the inet one : org.jboss.pool.jdbc.xa.wrapper.XADataSourceImpl SQLServerPool jdbc:inetdae7:localhost sa etc... This is for 2.4, on 2.2 change the package to minerva. What remains a ? for me, it's that the doco explain it using inet datasource. BTW, have you a full license ? (I tried with the demo version, maybe a problem...) Have you tried 4.00 or previous versions ? Have you strong relationships with the support to ask them the sources to debug this problem ourselves, or ask them to look at the jboss code, I mean they could have a return on investment,... Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Mark > Crowley > Envoyé : mercredi 4 juillet 2001 20:01 > À : [EMAIL PROTECTED] > Objet : [JBoss-user] CMP Entity Bean using Opta2000 Driver - Has Anyone > got this to work??? > > > I and a number of other Opta2000 users are trying > without success to create CMP Entity bean. The bean > deploys correctly, the datasource starts happily and > JBoss creates the necessary table (proving the > datasource is setup and working correctly), but when > ever the bean is accessed (for example using a finder > method) the following exception is generated (looging > has been turned on as well): > > [MSADictionary] [TDS Driver]XA_CONNECTION_GET > [MSADictionary] SQL Server 7 unicode mode > [MSADictionary] Single Server License > [MSADictionary] Driver: i-net OPTA 2000 4.10 > [MSADictionary] Statement.close > [MSADictionary] SELECT server,catalog,chartID FROM > ChartData > [MSADictionary] Statement.close > [MSADictionary] [TDS Driver]XA_CONNECTION_FREE > [MSADictionary] javax.transaction.xa.XAException: The > Xid is not valid.(XidImpl [FormatId=257, > GlobalId=ZEBEDEE//0, BranchQual=1]) resource > manager:com.inet.tds.k@785d65 > [ChartData] XAException: tx=XidImpl [FormatId=257, > GlobalId=ZEBEDEE//0, BranchQual=] errorCode=XAER_NOTA > [ChartData] javax.transaction.xa.XAException: The Xid > is not valid.(XidImpl [FormatId=257, > GlobalId=ZEBEDEE//0, BranchQual=1]) resource > manager:com.inet.tds.k@785d65 > [ChartData] at com.inet.tds.k.if(Unknown Source) > > We have been in touch with the tech-support for the > driver who eventually came to the following > conclusion: > > "The exception occurs because there is a rollback of > the transaction with a specific XID but no transaction > has been started. There seem be a bug in JBoss. JBoss > is calling a rollback for a DT without starting a DT". > > I find it hard to believe there arent 1000's of people > complaining about this, and therefore believe there is > no bug, just a problem in my set up. > > My environment is > > OS: Win2K > App Server: JBoss 2.2.2 with Tomcat 3.2.2 > JDBC: Opta2000 Tds driver 4.10 > > Has anybody actually managed to get a CMP Entity bean > working in JBoss with the Opta driver? > > Any thoughts, help, pointers would be much > appreciated. > > Thanks in advance. > > > Do You Yahoo!? > Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk > or your free @yahoo.ie address at http://mail.yahoo.ie > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [Ejbdoclet-user] AW: [JBoss-user] Help with another one - ejbdoclet/jboss.dtd not found
I wanted to say remove the dtd from the template... > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Jan > Heise > Envoyé : mercredi 4 juillet 2001 17:18 > À : [EMAIL PROTECTED]; ejbdoclet > Objet : [Ejbdoclet-user] AW: [JBoss-user] Help with another one - > ejbdoclet/jboss.dtd not found > > > But I want to get around editing the automatically generated > files by hand. That does not fit very well into my build.xml. > > jan > > -- > Jan Heise / Tel: +49-170-4803237 / E-Mail: [EMAIL PROTECTED] > > -Ursprüngliche Nachricht- > Von: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]Im Auftrag von Vincent > Harcq > Gesendet: Mittwoch, 4. Juli 2001 13:01 > An: [EMAIL PROTECTED]; ejbdoclet > Betreff: RE: [JBoss-user] Help with another one - ejbdoclet/jboss.dtd > not found > > > Remove the DTD from jboss.xml. There is no validation anyway. > Normally JBoss will find it in jboss.jar but I am not sure on 2.2. > > > -Message d'origine- > > De : [EMAIL PROTECTED] > > [mailto:[EMAIL PROTECTED]]De la part de Jan Heise > > Envoyé : mercredi 4 juillet 2001 12:40 > > À : ejbdoclet > > Cc : jboss-user > > Objet : [JBoss-user] Help with another one - ejbdoclet/jboss.dtd not > > found > > > > > > hi folks, > > > > regarding ejbdoclet - thanks for your help so far. > > > > my other question is: on deployment of my beans, jboss is > > complaining about the jboss.dtd which can't be found: > > > > [Auto deploy] org.jboss.ejb.DeploymentException: > > Could not deploy > > file:/C:/development/JBoss-2.2.2_Tomcat-3.2.2/jboss/tmp/deploy/Def > > ault/CN_BS > > C3-0.0.1.ear, > > Cause:org.jboss.ejb.DeploymentException: > > File "http://www.jboss.org/j2ee/dtd/jboss.dtd"; not found., > > Cause:org.xml.sax.SAXParseException: > > File "http://www.jboss.org/j2ee/dtd/jboss.dtd"; not found. > > > > in jboss.xml: > > > "http://www.jboss.org/j2ee/dtd/jboss.dtd";> > > > > this was generated by ejbdoclet. is there a way to suppress the > > generation of this line? perhaps this is just another newbie > > error with ejbdoclet though, but a download from the above address > > fails - and i never used the dtd on other projects anyway. > > > > any suggestions? > > > > jan > > > > -- > > Jan Heise / Tel: +49-170-4803237 / E-Mail: [EMAIL PROTECTED] > > > > > > ___ > > JBoss-user mailing list > > [EMAIL PROTECTED] > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > ___ > Ejbdoclet-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/ejbdoclet-user > > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Help with another one - ejbdoclet/jboss.dtd not found
Remove the DTD from jboss.xml. There is no validation anyway. Normally JBoss will find it in jboss.jar but I am not sure on 2.2. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Jan Heise > Envoyé : mercredi 4 juillet 2001 12:40 > À : ejbdoclet > Cc : jboss-user > Objet : [JBoss-user] Help with another one - ejbdoclet/jboss.dtd not > found > > > hi folks, > > regarding ejbdoclet - thanks for your help so far. > > my other question is: on deployment of my beans, jboss is > complaining about the jboss.dtd which can't be found: > > [Auto deploy] org.jboss.ejb.DeploymentException: > Could not deploy > file:/C:/development/JBoss-2.2.2_Tomcat-3.2.2/jboss/tmp/deploy/Def > ault/CN_BS > C3-0.0.1.ear, > Cause:org.jboss.ejb.DeploymentException: > File "http://www.jboss.org/j2ee/dtd/jboss.dtd"; not found., > Cause:org.xml.sax.SAXParseException: > File "http://www.jboss.org/j2ee/dtd/jboss.dtd"; not found. > > in jboss.xml: > "http://www.jboss.org/j2ee/dtd/jboss.dtd";> > > this was generated by ejbdoclet. is there a way to suppress the > generation of this line? perhaps this is just another newbie > error with ejbdoclet though, but a download from the above address > fails - and i never used the dtd on other projects anyway. > > any suggestions? > > jan > > -- > Jan Heise / Tel: +49-170-4803237 / E-Mail: [EMAIL PROTECTED] > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Entity bean with special objects attributes?
Your Vector may contain Serializable objects. Object is the definition not the content. A Vector full of Serializables IS Serializable. (I never test it though...) > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Peter Wone > Envoyé : mercredi 4 juillet 2001 11:14 > À : [EMAIL PROTECTED] > Objet : Re: [JBoss-user] Entity bean with special objects attributes? > > > It's just dawned on me; from the point of view of a Vector, each > element is > typed as Object. > > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: RE: [JBoss-user] Entity bean with special objects attributes?(Vincent Harcq)
It's independant of the DB. Parameter is in your ejb jar ? How did you make the mapping in jaws (if you did - its' not necessary) ? What is the exact message ? WHen does it happen (at deployment, at run time) ? Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Jm Seigneur > Envoyé : mercredi 4 juillet 2001 9:24 > À : [EMAIL PROTECTED] > Objet : RE: RE: [JBoss-user] Entity bean with special objects > attributes?(Vincent Harcq) > > > Hello, > > Until now Parameter has no internal object. > I use the Hypersonic database coming with JBoss. > Could it be the problem? > > Thanks, > > Jm > > >From: "Vincent Harcq" <[EMAIL PROTECTED]> > >To: <[EMAIL PROTECTED]> > >Subject: RE: [JBoss-user] Entity bean with special objects attributes? > >Date: Tue, 3 Jul 2001 23:54:37 +0200 > >Reply-To: [EMAIL PROTECTED] > > > >It should work. > >Vector is Serializable, Parameter is Serializable. > >What about internal object of Parameter ? > > > > -Message d'origine- > > De : [EMAIL PROTECTED] > > [mailto:[EMAIL PROTECTED]]De la part de Jm Seigneur > > Envoyé : mardi 3 juillet 2001 23:43 > > À : [EMAIL PROTECTED] > > Objet : [JBoss-user] Entity bean with special objects attributes? > > > > > > Hello, > > > > I'd like to have a bean which can store persistently a vector > of Parameter > > objects: > > import javax.ejb.EntityBean; > > public class BlackBoxBean implements EntityBean > > { String id; //primary key > > Vector parameters; //vector of Parameter objects > > > > public String getId{ ... > > > > To make the Parameter class serializable, I did that: > > import java.io.Serializable; > > public class Parameter implements Serializable > > {...} > > > > Nevertheless I get an exception saying Parameter isn't serializable. > > > > Is it possible to store that kind of objects in JBoss? > > > > Thanks, > > > > Jm > > > > > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Entity bean with special objects attributes?
It should work. Vector is Serializable, Parameter is Serializable. What about internal object of Parameter ? > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Jm Seigneur > Envoyé : mardi 3 juillet 2001 23:43 > À : [EMAIL PROTECTED] > Objet : [JBoss-user] Entity bean with special objects attributes? > > > Hello, > > I'd like to have a bean which can store persistently a vector of Parameter > objects: > import javax.ejb.EntityBean; > public class BlackBoxBean implements EntityBean > { String id; //primary key > Vector parameters; //vector of Parameter objects > > public String getId{ ... > > To make the Parameter class serializable, I did that: > import java.io.Serializable; > public class Parameter implements Serializable > {...} > > Nevertheless I get an exception saying Parameter isn't serializable. > > Is it possible to store that kind of objects in JBoss? > > Thanks, > > Jm > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Opta2000 for MS SQLServer2000 - com.inet.tds.XDataSource
Hi, Thank you for your response. I tried what you say (and other things) but I still get the error. For info, the problem happens on XA_CONNECTION_FREE just after creating the table. When My table exists, I do not have the problem. I could see if I can use my pool afterwards but I am now working with a demo version (only 2 connections). I will try again if I buy the license. I will go back to JBoss pool for now. Vincent. >I have noticed that, for Oracle, I get this XAER_NOTA exception as well. >It seems that oracle requires the Xid class to have a global id byte >array between 2-64 (Xid.MAXGTRIDSIZE) bytes, and a branch qualifier byte >array between 2-64 (Xid.MAXBQUALSIZE) bytes. In jboss, when a new Xid is >constructed, the branch qualifier is a 0 byte array, which gives me the >XAER_NOTA on endResource. > >After hacking up org.jboss.tm.XidImpl to always have at least 2 bytes >for the gid and bqual, it works. Perhaps the same with SQLServer2k? Try >having the gid and bqual byte arrays to always be MAXGTRIDSIZE (64) and >MAXBQUALSIZE (64) > >This is for jboss 2.2.2. > >jord. > > > > > Hi, > > I got an exception at deployment time of entity beans linked to a MS SQL > > Server 2000 database when I use the configuration from the doc; which > > isusing com.inet.tds.XDataSource instead of > > org.jboss.pool.jdbc.xa.wrapper.XADataSourceImpl. > > I found something for Oracle for the definition of XidClassName. Is there > > something similar for Opta2000? I have searched the Opta2000.jar without > > success. > > I use the demo version wich is limitted to 2 connections. Could > > it be that? > > > > TIA. > > Vincent. > > > > The Exception is : > > > > XAException: tx=3DXidImpl [FormatId=3D257, GlobalId=3Dharcq//0, BranchQual=3D] > > errorCode=3DXAER_NOTA > > javax.transaction.xa.XAException: The Xid is not valid.(XidImpl > > [FormatId=3D257, GlobalId=3Dharcq//0, BranchQual=3D1]) resource > > manager:com.inet.tds.k@64ab4d > > at com.inet.tds.k.if(Unknown Source) > > at com.inet.tds.k.for(Unknown Source) > > at com.inet.tds.k.end(Unknown Source) > > at org.jboss.tm.TxCapsule.endResource(TxCapsule.java:1129) > > at org.jboss.tm.TxCapsule.delistResource(TxCapsule.java:523) > > at > > org.jboss.tm.TransactionImpl.delistResource(TransactionImpl.java:99) > > at > > org.jboss.pool.jdbc.xa.XAConnectionFactory$2.closeConnection(XACon > > nectionFac > > tory.java:97) > > at > > org.jboss.pool.jdbc.xa.XAConnectionFactory$2.connectionClosed(XACo > > nnectionFa > > ctory.java:82) > > at com.inet.pool.c.a(Unknown Source) > > at com.inet.tds.k.a(Unknown Source) > > at com.inet.pool.a.close(Unknown Source) > > at > > org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand.jdbcExecute(JDBCComman > > d.java:190 > > ) > > at > > org.jboss.ejb.plugins.jaws.jdbc.JDBCInitCommand.execute(JDBCInitCo > > mmand.java > > :132) > > _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Opta2000 for MS SQLServer2000 - com.inet.tds.XDataSource
No sorry my conf file was incorrect during my tests. I did not solve anything. > Hi, > Is there a chance that this might clear the issue with the oracle > XADatasource??? > Hoping... > Burkhard ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Opta2000 for MS SQLServer2000 - com.inet.tds.XDataSource
I jump into the sources...cross post the mail... TxCapsule line 523 try { =>doBeforeCompletion();<= endResource(idx, flag); return true; } catch(XAException e) { doBeforeCompletion() was missing. The solution could it be so simple ? Vincent. PS: I have also see I am not the first in the archive...should have looked that before... Nintendo: If I am out of the problem, we should change the doco ! > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Vincent > Harcq > Envoyé : lundi 2 juillet 2001 0:40 > À : User JBoss > Objet : [JBoss-user] Opta2000 for MS SQLServer2000 - > com.inet.tds.XDataSource > > > Hi, > I got an exception at deployment time of entity beans linked to a MS SQL > Server 2000 database when I use the configuration from the doc; which > isusing com.inet.tds.XDataSource instead of > org.jboss.pool.jdbc.xa.wrapper.XADataSourceImpl. > I found something for Oracle for the definition of XidClassName. Is there > something similar for Opta2000? I have searched the Opta2000.jar without > success. > I use the demo version wich is limitted to 2 connections. Could > it be that? > > TIA. > Vincent. > > The Exception is : > > XAException: tx=XidImpl [FormatId=257, GlobalId=harcq//0, BranchQual=] > errorCode=XAER_NOTA > javax.transaction.xa.XAException: The Xid is not valid.(XidImpl > [FormatId=257, GlobalId=harcq//0, BranchQual=1]) resource > manager:com.inet.tds.k@64ab4d > at com.inet.tds.k.if(Unknown Source) > at com.inet.tds.k.for(Unknown Source) > at com.inet.tds.k.end(Unknown Source) > at org.jboss.tm.TxCapsule.endResource(TxCapsule.java:1129) > at org.jboss.tm.TxCapsule.delistResource(TxCapsule.java:523) > at > org.jboss.tm.TransactionImpl.delistResource(TransactionImpl.java:99) > at > org.jboss.pool.jdbc.xa.XAConnectionFactory$2.closeConnection(XACon > nectionFac > tory.java:97) > at > org.jboss.pool.jdbc.xa.XAConnectionFactory$2.connectionClosed(XACo > nnectionFa > ctory.java:82) > at com.inet.pool.c.a(Unknown Source) > at com.inet.tds.k.a(Unknown Source) > at com.inet.pool.a.close(Unknown Source) > at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand.jdbcExecute(JDBCComman > d.java:190 > ) > at > org.jboss.ejb.plugins.jaws.jdbc.JDBCInitCommand.execute(JDBCInitCo > mmand.java > :132) > > > _ > Do You Yahoo!? > Get your free @yahoo.com address at http://mail.yahoo.com > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] Opta2000 for MS SQLServer2000 - com.inet.tds.XDataSource
Hi, I got an exception at deployment time of entity beans linked to a MS SQL Server 2000 database when I use the configuration from the doc; which isusing com.inet.tds.XDataSource instead of org.jboss.pool.jdbc.xa.wrapper.XADataSourceImpl. I found something for Oracle for the definition of XidClassName. Is there something similar for Opta2000? I have searched the Opta2000.jar without success. I use the demo version wich is limitted to 2 connections. Could it be that? TIA. Vincent. The Exception is : XAException: tx=XidImpl [FormatId=257, GlobalId=harcq//0, BranchQual=] errorCode=XAER_NOTA javax.transaction.xa.XAException: The Xid is not valid.(XidImpl [FormatId=257, GlobalId=harcq//0, BranchQual=1]) resource manager:com.inet.tds.k@64ab4d at com.inet.tds.k.if(Unknown Source) at com.inet.tds.k.for(Unknown Source) at com.inet.tds.k.end(Unknown Source) at org.jboss.tm.TxCapsule.endResource(TxCapsule.java:1129) at org.jboss.tm.TxCapsule.delistResource(TxCapsule.java:523) at org.jboss.tm.TransactionImpl.delistResource(TransactionImpl.java:99) at org.jboss.pool.jdbc.xa.XAConnectionFactory$2.closeConnection(XAConnectionFac tory.java:97) at org.jboss.pool.jdbc.xa.XAConnectionFactory$2.connectionClosed(XAConnectionFa ctory.java:82) at com.inet.pool.c.a(Unknown Source) at com.inet.tds.k.a(Unknown Source) at com.inet.pool.a.close(Unknown Source) at org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand.jdbcExecute(JDBCCommand.java:190 ) at org.jboss.ejb.plugins.jaws.jdbc.JDBCInitCommand.execute(JDBCInitCommand.java :132) _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Tools
Have a look at EJBDoclet : https://sourceforge.net/projects/ejbdoclet/ It is more efficient that any GUI tools during developement. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Devraj > Mukherjee > Envoye : dimanche 1 juillet 2001 10:49 > A : JBoss List Serve > Objet : [JBoss-user] Tools > > > Can anyone, tell me what tools are included in JBoss for helping with app > deployment and generation of the XML descriptors?/ > > Devraj > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [JBoss/Tomcat] Flat web application and classloaders
Hi, I am trying JBoss/Tomcat with several ejbs deployed as .jar and a web application not deployed as a war but instead in tomcat/webapps/ROOT (it is more easy for developement). I have an entity PK class that is both in one ejb.jar and in tomcat/ I change it and redeploy my ejb. I do NOT recompile the Tomcat version. I attack my ejb with a client that have the new version of the PK class. I receive a ClassCastException. The ejb.jar is using the tomcat version. Indeed, if I recompile the tomcat version the problem disappear. Is this not a Classloader problem ? the ejb.jar should only seen ITS pk class. Does I HAVE to use WAR to avoid that ? Second Problem (but thisone is Tomcat I guess) The "reloadable" attribute of Context in tomcat/conf/server.xml does not seems to be taken into account. TIA. Vincent. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] How to use two Datasources with CMP ?
Not possible for the moment but somebody is working on it... Please do not use HTML when sending mail. Vincent. -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de Francesco Marchioni Envoyé : jeudi 28 juin 2001 9:32 À : [EMAIL PROTECTED] Objet : [JBoss-user] How to use two Datasources with CMP ? Hi jBossUsers, I have 2 tables on two different DB (MySql - PostgreSql). How can I use CMP with 2 Datasources ? jaws.xml and standardjaws.xml don't let me specify more then 1 datasource inside With BMP I can get a connection from the pools without problems but how can I achieve it with CMP ? If this is not possible I must think that distributed transactions are only possible with BMP otherwise how can I have two "create()" on different DB on the same transaction ? Thanks Francesco _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Is there BMP sample?
Hi, Can you send it to me, I wanted to add a small chapter on BMP to the docs basically to explain how to use datasource. I'll put your name and you will become famous :) Thanks. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de > Allen fogleson > Envoye : jeudi 28 juin 2001 9:11 > A : [EMAIL PROTECTED] > Objet : Re: [JBoss-user] Is there BMP sample? > > > you would still use a datasource... well unless you just want around the > whole transaction, connection pooling of the container... I cant imagine > why. I can whip together a quick simple example if you havent > found what you > need yet... email me direct > > Al > > - Original Message - > From: Boris Garbuzov <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Wednesday, June 27, 2001 3:50 PM > Subject: [JBoss-user] Is there BMP sample? > > > > Is there any documentation article with BMP example? Any BMP is database > specific > > so I do not use JAWS or datasources, but write write a SQL with specific > data > > types? I would like to use MySQL. > > > > > > > > ___ > > JBoss-user mailing list > > [EMAIL PROTECTED] > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] JBoss + Catalina JNDI Probs
Hi, >In effect, it is like your 2nd case, since Strings are also Serialized objects (The object >graph of my SerialObjectA contains Strings which in turn must be serialized and de- >serialized). You mean your parameter is a String ? >i.e., I return an Object like this: >public class SerialObjectA implements Serializable { > private String testString; > public String getTestString() { return testString; } > public void setTestString(String testString) { this.testString = testString; } >} I am not sure to follow you: the problem I have is not in the type of the return object. The problem is in the type of the parameter. If the parameter is java.lang.String , int, java.lang.anything that is Serializable : NO PROB. If the parameter is com.mycompany.anything that is Serializable : PROBLEM. The parameter. Noit the returned object. >Does your serialized object hold remote references? I don't think that those will serialize >at all. I guess it depends on what that 2nd method is trying to do with the parameter passed >in. No, in fact I am even not receiving anything I pass an Object (Serializable) with 2 String in it. >-jason It really drives me crazy, it is not very important but these rmi, jndi, classloading are less and less clear in my head... Vincent. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] JBoss + Catalina JNDI Probs
Thanks for responding. I was not clear Are you calling a method like that SerialObject getSomething() ? Or Like that SerialObject getSomething(SerialObjectB param) ? The problem I have only happens in the second case. Vincent. -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de [EMAIL PROTECTED] Envoye : mardi 26 juin 2001 15:28 A : [EMAIL PROTECTED] Objet : RE: [JBoss-user] JBoss + Catalina JNDI Probs Hmm...well, I hope that's not the case. So far, everything has been working great with Catalina 4.0b5, since I received help from this list on how to get it working. I am calling a remote method which returns a Serializable Value Object -- seems to come back with no problem. (It in turn contains both primitives and Objects) -jason Vincent Harcq <[EMAIL PROTECTED]> Sent by: [EMAIL PROTECTED] 06/26/2001 05:14 AM Please respond to jboss-user To:[EMAIL PROTECTED] cc: Subject:RE: [JBoss-user] JBoss + Catalina JNDI Probs Hi, AFAIK, you will still get the error when you pass a non-primitive parameter between Catalina and JBoss. I do not think there is a solution for that. The last trick that Simone post was to marshal the parameters in a java.rmi.MarshalledObject, which is a "primitive" (triple double quotes) for Catalina. I come back to tomcat-dev for that one yesterday. No answers... Vincent. -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de [EMAIL PROTECTED] Envoye : mardi 26 juin 2001 4:31 A : [EMAIL PROTECTED] Objet : RE: [JBoss-user] JBoss + Catalina JNDI Probs Thanks so much! Removing the jndi.jar was what did the trick! -Jason John Menke <[EMAIL PROTECTED]> Sent by: [EMAIL PROTECTED] 06/25/2001 09:05 PM Please respond to jboss-user To:[EMAIL PROTECTED] cc: Subject:RE: [JBoss-user] JBoss + Catalina JNDI Probs Check out the TDK+JBoss Howto on the Turbine Site. http://jakarta.apache.org/turbine/howto/jboss-howto.html -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of [EMAIL PROTECTED] Sent: Monday, June 25, 2001 6:40 PM To: [EMAIL PROTECTED] Subject: [JBoss-user] JBoss + Catalina JNDI Probs I checked out the list archives and noticed a bit of discussion earlier this month on problems getting Servlets within Catalina to connect to JBoss. Has any of this been resolved? (I didn't see an answer anywhere). I have tried the nonaming option as many have suggested, but to no avail. I'm getting the "java.net.MalformedURLException: unknown protocol: jndi" error others have reported. I've pasted the sample code I'm trying to execute below. Thanks, Jason Here's the simple client code that my servlet tries to execute: // Sanity checkuses values copied from jndi.properties // just changed the hostname in the url to match the actual JBoss server name System.err.println("Using these values:"); for (Enumeration e = EJB_ENV.keys(); e.hasMoreElements();) { String key = (String)e.nextElement(); System.err.println(key + "=" + EJB_ENV.get(key)); } if (ejbCtx == null) { try { ejbCtx = new InitialContext(EJB_ENV); } catch (Exception e) { log("Error getting EJB context!"); e.printStackTrace(); return null; } } try { //Retrieve a handle to the Home object System.err.println("About to lookup up: " + userJNDIName); Object o = ejbCtx.lookup(userJNDIName); // <- Breaks here UserHome uh = (UserHome)PortableRemoteObject.narrow(o, UserHome.class); return uh.create(); } catch (Exception e) { log("Error getting an User object!"); e.printStackTrace(); return null; } ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] JBoss + Catalina JNDI Probs
Hi, AFAIK, you will still get the error when you pass a non-primitive parameter between Catalina and JBoss. I do not think there is a solution for that. The last trick that Simone post was to marshal the parameters in a java.rmi.MarshalledObject, which is a "primitive" (triple double quotes) for Catalina. I come back to tomcat-dev for that one yesterday. No answers... Vincent. -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de [EMAIL PROTECTED] Envoye : mardi 26 juin 2001 4:31 A : [EMAIL PROTECTED] Objet : RE: [JBoss-user] JBoss + Catalina JNDI Probs Thanks so much! Removing the jndi.jar was what did the trick! -Jason John Menke <[EMAIL PROTECTED]> Sent by: [EMAIL PROTECTED] 06/25/2001 09:05 PM Please respond to jboss-user To:[EMAIL PROTECTED] cc: Subject:RE: [JBoss-user] JBoss + Catalina JNDI Probs Check out the TDK+JBoss Howto on the Turbine Site. http://jakarta.apache.org/turbine/howto/jboss-howto.html -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of [EMAIL PROTECTED] Sent: Monday, June 25, 2001 6:40 PM To: [EMAIL PROTECTED] Subject: [JBoss-user] JBoss + Catalina JNDI Probs I checked out the list archives and noticed a bit of discussion earlier this month on problems getting Servlets within Catalina to connect to JBoss. Has any of this been resolved? (I didn't see an answer anywhere). I have tried the nonaming option as many have suggested, but to no avail. I'm getting the "java.net.MalformedURLException: unknown protocol: jndi" error others have reported. I've pasted the sample code I'm trying to execute below. Thanks, Jason Here's the simple client code that my servlet tries to execute: // Sanity checkuses values copied from jndi.properties // just changed the hostname in the url to match the actual JBoss server name System.err.println("Using these values:"); for (Enumeration e = EJB_ENV.keys(); e.hasMoreElements();) { String key = (String)e.nextElement(); System.err.println(key + "=" + EJB_ENV.get(key)); } if (ejbCtx == null) { try { ejbCtx = new InitialContext(EJB_ENV); } catch (Exception e) { log("Error getting EJB context!"); e.printStackTrace(); return null; } } try { //Retrieve a handle to the Home object System.err.println("About to lookup up: " + userJNDIName); Object o = ejbCtx.lookup(userJNDIName); // <- Breaks here UserHome uh = (UserHome)PortableRemoteObject.narrow(o, UserHome.class); return uh.create(); } catch (Exception e) { log("Error getting an User object!"); e.printStackTrace(); return null; } ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Problems Compiling Message Driven Bean
Title: Re: [JBoss-user] Problems Compiling Message Driven Bean You need the ejb.jar from ejb 2.0 -Message d'origine-De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de Hunter HillegasEnvoyé : samedi 23 juin 2001 21:50À : JBoss 2Objet : Re: [JBoss-user] Problems Compiling Message Driven BeanNope. I just checked. Anyone know which jar does have it? I can’t find it!The docs don’t specify (at least I couldn’t find the info there).Hunter From: "Vinay Menon" <[EMAIL PROTECTED]>Reply-To: [EMAIL PROTECTED]Date: Sat, 23 Jun 2001 20:39:15 +0100To: <[EMAIL PROTECTED]>Subject: Re: [JBoss-user] Problems Compiling Message Driven BeanSanity check! Does the ejb.jar actually have the class MessageDrivenBean in it?
RE: [JBoss-user] EJBDoclet examples?
Hi, The examples are part of 1.1 zip file. An example of build script can be found under CVS: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/~checkout~/ejbdoclet/ejbdocle t/src/build/build_test.xml?rev=1.7&content-type=text/plain and http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/ejbdoclet/ejbdoclet/src/build /build_test.bat?rev=1.1&content-type=text/vnd.viewcvs-markup Vincent > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Pelle > Poluha > Envoyé : lundi 18 juin 2001 8:14 > À : [EMAIL PROTECTED] > Objet : [JBoss-user] EJBDoclet examples? > > > Hello! > > I'm trying to learn how to use EJBDoclet but didn't find > any complete examples on EJBDoclet's site. > > Anybody using it? Any good? How would a build.xml file look > like? And how is the code commented? > > Any help would be appreciated. > > Regards, > Pelle > Poluha > > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] Trivial but critical
It is possible : http://www.jboss.org/documentation/HTML/ch05s07.html Vincent. --- Keerthi Panneer <[EMAIL PROTECTED]> wrote: > Hi all, > Is it possible to instruct JAWS, the SQL order clause (ascending or > descending) for the finder queries of CMP beans, in JAWS.xml > > I know this could be done easily if we use BMP. Would be a great > stuff, if > this can be done declaratively for CMP entity beans !!! > > If this can't be done... could anyone suggest me the workaround ? > > thanks in advance. > > Keerthi > _ > Get Your Private, Free E-mail from MSN Hotmail at > http://www.hotmail.com. > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user __ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail - only $35 a year! http://personal.mail.yahoo.com/ ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] JBoss and ANT
> What is EJBDoclet? could you provide some more information or a link. It is there : https://sourceforge.net/projects/ejbdoclet/ Take the CVS version. > > Regarding having ANT write the beans, I dont think that is such a strecth > ... imagine just defining your properties and methods (including > code) in an > xml format and then having ant or some other tool generate all required > files... this shouldnt even be that hard to implement as an ant > add on task. > > What do you all think about this? > > Ivan > > > ...and if you add EJBDoclet as an ANT task, then you are > > really going!!! ANT then does all you stuff... > > > > Then you basically write a singe java file describing you > > bean and an ANT task builds you pk classes, home and remote > > interfaces and value objects if needed, builds and verifies > > your ear file and finally deploys it, can it get any better? > > (Next step for ANT is to write the bean itself... :-) > > > > ^torsten > > > > > > > > Mike, > > > There really is nothing special that needs to be added > > > to ANT to generate JBOSS deployment jars. WLS uses > > > ejbc (EJB compiler) to generate skeletons and stubs > > > used to marshal data during invocation. Since JBOSS > > > uses dynamic proxies to accomplish this (read, > > > stub-less/skeleton-less) there is no special post > > > compilation required, hence no need for ANT > > > particulars. > > > > > > I've got an article coming out in the September Java > > > Report with an ANT/JBOSS example. Look for it! > > > > > > cheers, > > > peter > > > > > > > > > --- "Michael P. McCutcheon" <[EMAIL PROTECTED]> > > > wrote: > > > > They are taking feature requests at the Jakarta > > > > project...wouldn't it be cool if ANT could build EJB > > > > jars that would work in JBoss? > > > > > > > > Has anyone submitted a request to the ANT developers > > > > about this? Currently I believe that the EJB jar > > > > generating feature in ANT only supports BEA. > > > > > > > > Oh, by the way...seen JBuilder 5? It has been > > > > announced on Borland.com > > > > > > > > Cool! > > > > > > > > Mike > > > > > > > > _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Unable to locate elogj.jar
This module is now integrated into version 2.3 - current CVS. If you want to take this to JBoss 2.2.1, then you have to build the module, it will create this jar. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Manu > Srivastava > Envoye : vendredi 18 mai 2001 6:07 > A : [EMAIL PROTECTED] > Objet : [JBoss-user] Unable to locate elogj.jar > > > Hi All, > > http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/jboss/contrib/log4j/readme > gives the following instructions to use loj4j to > enable logging. > > "Download the latest version of log4j.jar from > http://jakarta.apache.org/log4j. > > Copy log4j.jar and elogj.jar under lib/ext." > > Where do I find elogj.jar?? It is not there in the > log4j download from Apache. > > Thanks in Advance, > Regards > Manu > > __ > Do You Yahoo!? > Yahoo! Auctions - buy the things you want at great prices > http://auctions.yahoo.com/ > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] java.lang.Illegal.Argument Exception : object is not instance of the class
> I have only 1 session bean and many entity bean in different > jar.(session bean facade model). > > I did not why . I can remove entity bean without any error before. > I have tried it in jboss2.2.1 and jboss2.1 and hit the same error > message. > > I did not know why. My guess is that something to do with ClassLoader. > It is mine also. I think My problem is a bit different, as I have an ejb jar A contains the session bean and ejb jar B contains the entity that will be removed through the session bean. I have verified that the EntityEnterpriseContext of ejbjar B have an object in it that has a Classloader of ejbjar A. I am still looking how it can happen since my understanding of EntityInstanceInterceptor is that access to EntityEntrepriseContext "object" can only be done through the EntityCache which is attached to the entity so to the ejbjar B classloader. I have also verified that access to EntityEnterpriseContext may be done without going to EntityInstanceInterceptor. Before removing your entity, can you try to run any getter method on the remote interface. just before calling remove(), it should solve your problem. >Thanks wt. > Vincent. _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] java.lang.Illegal.Argument Exception : object is not instance of the class
I am pretty sure there is a problem in the instances pool somewhere, I also receive something similar to that. The trick is tio call any dummy remote method before calling remove. Please help me figure out what happen : Do you play with 2 session beans in 2 different ejb jar here ? Thanks. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Russell > Envoye : mercredi 16 mai 2001 7:02 > A : [EMAIL PROTECTED] > Objet : Re: [JBoss-user] java.lang.Illegal.Argument Exception : object > is not instance of the class > > > Hi Toby , Thanks > > The complete exception is below : > > java.rmi.ServerException: RemoteException occurred in server thread; > nested exception is: > javax.transaction.TransactionRolledbackException: Load > failed; nested > exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class; nested exception is: > java.rmi.ServerException: Load failed; nested exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class; nested exception is: > javax.transaction.TransactionRolledbackException: Load > failed; nested > exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class; nested exception is: > java.rmi.ServerException: Load failed; nested exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class > javax.transaction.TransactionRolledbackException: Load failed; nested > exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class; nested exception is: > java.rmi.ServerException: Load failed; nested exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class; nested exception is: > javax.transaction.TransactionRolledbackException: Load > failed; nested > exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class; nested exception is: > java.rmi.ServerException: Load failed; nested exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class > javax.transaction.TransactionRolledbackException: Load failed; nested > exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class; nested exception is: > java.rmi.ServerException: Load failed; nested exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class > java.rmi.ServerException: Load failed; nested exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class > java.lang.IllegalArgumentException: object is not an instance of > declaring class > at > sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(Str > eamRemoteCall.java:245) > at > sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:220) > at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:122) > at > org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker_Stub.invoke(Unknown > Source) > at > org.jboss.ejb.plugins.jrmp.interfaces.StatelessSessionProxy.invoke > (StatelessSessionProxy.java:188) > at $Proxy1.adminDeleteCompany(Unknown Source) > at > com.cesma.ecommerce.pmg.pmgprocess.Untitled1.main(Untitled1.java:38) > > > > > Toby Allsopp wrote: > > > > On Wed, May 16, 2001 at 11:21:57AM +0800, Russell wrote: > > > > > > Hi all , > > > > > >I am using jBoss2.1 , jdk1.3 and Tomcat3.2.1. > > > > > >When i tried to remove entity , i have the error below : > > > > > > java.lang.Illegal.Argument Exception : object is not > instance of the > > > class... > > > > Please, when reporting exceptions, use copy and paste and include THE > > ENTIRE STACKTRACE. Sorry for shouting, but this really gets on ones > > nerves after a while. > > > > >And the code is : > > > > > > Remote r = home.findByPrimaryKey(new HomePK(3)); > > > r.remove() --> error here. > > > > That looks reasonable to me. The complete stacktrace might shed some > > more light on the matter. > > > > Toby. > > > > > Anybody have any idea why like that ?? Is this a bug in jboss ?? > > > > ___ > > JBoss-user mailing list > > [EMAIL PROTECTED] > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Controlling whats in server.log
Then I guess (I found back an "old" JBoss on my PC - I collection them you know :) ) > Maybe you have Debug in it ? > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Jim Archer > Envoye : lundi 14 mai 2001 1:46 > A : [EMAIL PROTECTED] > Objet : RE: [JBoss-user] Controlling whats in server.log > > > Thanks for the reply, Vincent, and my apologies for not mentioning that I > am using 2.2.1. For production purposes (and I'm getting close to > deployment) I prefer to use tagged, released versions. > > If this can't be done in the current release, I think I'll wait for the > next release, unless some other compelling reason arises to > upgrade before > a new release. > > Thanks! > > Jim > > --On Sunday, May 13, 2001 10:51 AM +0200 Vincent Harcq > <[EMAIL PROTECTED]> wrote: > > > Jim, > > You work with latest cvs version do you ? > > Then replace > > log4j.rootCategory=DEBUG, Default, Console > > by > > log4j.rootCategory=INFO, Default, Console > > > > IMHO, this should be the default in cvs. > > > > Vincent. > > > >> -Message d'origine- > >> De : [EMAIL PROTECTED] > >> [mailto:[EMAIL PROTECTED]]De la part de Jim Archer > >> Envoye : dimanche 13 mai 2001 6:00 > >> A : [EMAIL PROTECTED] > >> Objet : [JBoss-user] Controlling whats in server.log > >> > >> > >> Hi All... > >> > >> I looked through the docs and achive, and also I looked at the > >> log4j.properties file, but no luck on this, so I would apprciate > >> some help > >> please... > >> > >> As jBoss runs, it frequently logs (from the container factory) bean > >> passivations and other routine server events. Is it possible to turn > >> logging of these events off, and leave on impotant stuff like runtime > >> exceptions? > >> > >> Thanks... > >> > >> Jim > >> > >> > >> I shall be telling this with a sigh > >> Somewhere ages and ages hence: > >> Two roads diverged in a wood, and I - > >> I took the one less traveled by, > >> And that has made all the difference. > >> > >> - Robert Frost, 1916 > >> > >> > >> ___ > >> JBoss-user mailing list > >> [EMAIL PROTECTED] > >> http://lists.sourceforge.net/lists/listinfo/jboss-user > > > > _ > > Do You Yahoo!? > > Get your free @yahoo.com address at http://mail.yahoo.com > > > > > > ___ > > JBoss-user mailing list > > [EMAIL PROTECTED] > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Controlling whats in server.log
Jim, You work with latest cvs version do you ? Then replace log4j.rootCategory=DEBUG, Default, Console by log4j.rootCategory=INFO, Default, Console IMHO, this should be the default in cvs. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Jim Archer > Envoye : dimanche 13 mai 2001 6:00 > A : [EMAIL PROTECTED] > Objet : [JBoss-user] Controlling whats in server.log > > > Hi All... > > I looked through the docs and achive, and also I looked at the > log4j.properties file, but no luck on this, so I would apprciate > some help > please... > > As jBoss runs, it frequently logs (from the container factory) bean > passivations and other routine server events. Is it possible to turn > logging of these events off, and leave on impotant stuff like runtime > exceptions? > > Thanks... > > Jim > > > I shall be telling this with a sigh > Somewhere ages and ages hence: > Two roads diverged in a wood, and I - > I took the one less traveled by, > And that has made all the difference. > > - Robert Frost, 1916 > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error
Hi! Please note that I am using a 2.3 beta version so maybe there was some changes in between. But here are the jars I have 1. In Tomcat E:\Projects\p1\tomcat4b1>dir /s *.jar Directory of E:\Projects\p1\tomcat4b1\bin 06/01/2001 05:18 24.776 bootstrap.jar 06/01/2001 05:18 98.496 jndi.jar 06/01/2001 05:18 23.514 naming.jar 06/01/2001 05:18 74.753 servlet.jar Directory of E:\Projects\p1\tomcat4b1\lib 06/01/2001 05:18 188.406 crimson.jar 06/01/2001 05:18 272.734 jasper.jar 06/01/2001 05:18 11.809 jaxp.jar 23/02/2001 10:47 85.237 jdom.jar 06/01/2001 05:183.724 namingfactory.jar Directory of E:\Projects\p1\tomcat4b1\server 06/01/2001 05:18 490.878 catalina.jar 06/01/2001 05:18 188.406 crimson.jar 06/01/2001 05:18 29.809 jakarta-regexp-1.2.jar 06/01/2001 05:18 11.809 jaxp.jar 06/01/2001 05:18 31.416 warp.jar 2. In WEB-INF\lib E:\Projects\VMI\main\UltraDev>dir /s *.jar Directory of E:\Projects\p1\main\web\WEB-INF\lib 18/02/2001 01:10 175.666 hsql.jar 07/05/2001 09:49 88.843 jboss-client.jar 03/05/2001 16:18 58.461 jboss-j2ee.jar 03/05/2001 16:18 133.040 jbossmq-client.jar 04/05/2001 09:51 22.976 jbosssx-client.jar 04/05/2001 09:51 15.110 jnp-client.jar 25/02/2001 00:14 128.006 log4j.jar Total Files Listed: 7 File(s)622.102 bytes 0 Dir(s) 5.701.087.232 bytes free > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Rettig > Christoph > Envoyé : vendredi 11 mai 2001 16:30 > À : [EMAIL PROTECTED] > Objet : Re: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error > > > Yes, no problem with -nonaming : catalina.bat run -nonaming. > server.xml : > > > And all JBoss client JAR files in E:\Projects\web\WEB-INF\lib > > Nothing else changed to catalina installation directory > > Oh yes, another one, > jndi.properties is not read (if I remember well) so I have to manually > System.setProperty "java.naming..." just before calling new > InitialContext() > > Hi! > > I'm using catalina in combination with the turbine framework > and jbossMQ. > I also > get exactly these communication errors when trying to get an initial > context. > Which jar files exactly do you put in your web-inf\lib?? I tried your > suggestions > (using jbossmq-client.jar) but the error stays the same > > regards > > Chris ... > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error
Yes, no problem with -nonaming : catalina.bat run -nonaming. server.xml : And all JBoss client JAR files in E:\Projects\web\WEB-INF\lib Nothing else changed to catalina installation directory Oh yes, another one, jndi.properties is not read (if I remember well) so I have to manually System.setProperty "java.naming..." just before calling new InitialContext() Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de John Menke > Envoyé : vendredi 11 mai 2001 15:10 > À : [EMAIL PROTECTED] > Objet : RE: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error > > > Vincent, you were able to get 4.0 beta 1 and JBoss 2.2.1 working? > > I am running > > Turbine TDK > Catalina 4.0 beta 1 - provided by Turbine TDK > JBoss2.2.1 > > Catalina and JBoss are running in seperate VM's > > > > > -Original Message----- > > From: [EMAIL PROTECTED] > > [mailto:[EMAIL PROTECTED]]On Behalf Of Vincent > > Harcq > > Sent: Friday, May 11, 2001 5:01 AM > > To: Dev JBoss; [EMAIL PROTECTED] > > Subject: RE: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error > > > > > > Nope. > > > > Scott, my gentle jndi guru, does it make sense to change NamingContext > > so that it can understand "jndi:", then use for java.naming.provider.url > > something like "jndi://localhost:1099" to avoid this problem with > > catalina ? > > Or is it Catalina the source of the problem ? > > > > > > > > > > javax.naming.CommunicationException[Root exeption is > > > > > > > > java.rmi.ServerException: RemoteException occured in server > > > > > > > > thread; nested > > > > > > > > exception is java.rmi.UnmarshalException: error > unmarshalling > > > > > > > > arguments; > > > > > > > > nested exception is java.net.MalformedURL exception: unknown > > > > > > > > protocol: jndi > > > > Vincent > > > > > Hi! > > > You are the first one to get this :( > > > I also got this one on beta3 but it works fine for me on beta1 :) > > > beta4 is just out, I will try again... > > > Vincent. > > > > > > > > > > > Maybe the -nonaming is not getting executed then? (if it fixed your > > > > problem). I am using Catalina from within the Turbine TDK which > > > contains a > > > > schell script startup.sh which calls the catalina.sh script. I > > > have added > > > > the -nonaming to this line so it reads > > > > > > > > $BASEDIR/catalina.sh start -nonaming "$@" > > > > > > > > This should turn naming off, but I still get the errors when > > I start the > > > > program this way. > > > > > > > > > > > > > Hey John > > > > > > > > > > > Yes, I have tried that, and I still get the error. (It seems > > > > > > like it has no > > > > > > effect) Do you have this configuration working? > > > > > > > > > > Not exactly. I'm using Catalina with another server application > > > > > that has its > > > > > own Naming service, and at the beginning I got the same error > > > > on startup, > > > > > but it went away with the -nonaming option. > > > > > We then have other problems with this jndi: protocol, also > > > from previous > > > > > discussions it seems to me a Catalina bug: with us, every class > > > > > loaded from > > > > > web-inf/classes or web-inf/lib has a codebase like > > > > > "jndi:/WEB-INF/classes/" > > > > > or "jar:jndi:/WEB-INF/lib/xxx.jar!/", so that if objects of > > > > these classes > > > > > are passed as arguments to any rmi method invocation, on the > > > > > other side the > > > > > class annotation is taken from the stream, but of course the > > > classloader > > > > > cannot understand the Catalina-specific jndi: protocol. > > > > > The context class loader should take care of that probably, but > > > > I did not > > > > > figured it out yet why it doesn't. I miss Rickard ! > > > > > > > > > > Will live, will see. > > > > > > > > > > Cheers > > > > > > > > > > Simon > > >
RE: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error
Nope. Scott, my gentle jndi guru, does it make sense to change NamingContext so that it can understand "jndi:", then use for java.naming.provider.url something like "jndi://localhost:1099" to avoid this problem with catalina ? Or is it Catalina the source of the problem ? > > > > > > javax.naming.CommunicationException[Root exeption is > > > > > > java.rmi.ServerException: RemoteException occured in server > > > > > > thread; nested > > > > > > exception is java.rmi.UnmarshalException: error unmarshalling > > > > > > arguments; > > > > > > nested exception is java.net.MalformedURL exception: unknown > > > > > > protocol: jndi Vincent > Hi! > You are the first one to get this :( > I also got this one on beta3 but it works fine for me on beta1 :) > beta4 is just out, I will try again... > Vincent. > > > > > Maybe the -nonaming is not getting executed then? (if it fixed your > > problem). I am using Catalina from within the Turbine TDK which > contains a > > schell script startup.sh which calls the catalina.sh script. I > have added > > the -nonaming to this line so it reads > > > > $BASEDIR/catalina.sh start -nonaming "$@" > > > > This should turn naming off, but I still get the errors when I start the > > program this way. > > > > > > > Hey John > > > > > > > Yes, I have tried that, and I still get the error. (It seems > > > > like it has no > > > > effect) Do you have this configuration working? > > > > > > Not exactly. I'm using Catalina with another server application > > > that has its > > > own Naming service, and at the beginning I got the same error > > on startup, > > > but it went away with the -nonaming option. > > > We then have other problems with this jndi: protocol, also > from previous > > > discussions it seems to me a Catalina bug: with us, every class > > > loaded from > > > web-inf/classes or web-inf/lib has a codebase like > > > "jndi:/WEB-INF/classes/" > > > or "jar:jndi:/WEB-INF/lib/xxx.jar!/", so that if objects of > > these classes > > > are passed as arguments to any rmi method invocation, on the > > > other side the > > > class annotation is taken from the stream, but of course the > classloader > > > cannot understand the Catalina-specific jndi: protocol. > > > The context class loader should take care of that probably, but > > I did not > > > figured it out yet why it doesn't. I miss Rickard ! > > > > > > Will live, will see. > > > > > > Cheers > > > > > > Simon > > > > > > > > > > > > > Do you start Catalina with the -nonaming option, so that from it > > > > > you connect > > > > > to JBoss' Naming service ? > > > > > > > > > > Simon > > > > > > > > > > > -Messaggio originale- > > > > > > Da: John Menke [mailto:[EMAIL PROTECTED]] > > > > > > Inviato: mercoledì 9 maggio 2001 23:30 > > > > > > A: jboss > > > > > > Oggetto: [JBoss-user] Catalina and Jboss2.2.1 > InitialContext error > > > > > > > > > > > > > > > > > > This error is produced when I try to get an initial > JNDI context. > > > > > > > > > > > > The error is: > > > > > > > > > > > > javax.naming.CommunicationException[Root exeption is > > > > > > java.rmi.ServerException: RemoteException occured in server > > > > > > thread; nested > > > > > > exception is java.rmi.UnmarshalException: error unmarshalling > > > > > > arguments; > > > > > > nested exception is java.net.MalformedURL exception: unknown > > > > > > protocol: jndi > > > > > > > > > > > > > > > > > > I can get InitalContext in Tomcat 3.2, but Catalina produces > > > > > > the error. > > > > > > > > > > > > Is there a workaround? _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error
Hi! You are the first one to get this :( I also got this one on beta3 but it works fine for me on beta1 :) beta4 is just out, I will try again... Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de John Menke > Envoyé : vendredi 11 mai 2001 2:04 > À : [EMAIL PROTECTED] > Objet : RE: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error > > > Maybe the -nonaming is not getting executed then? (if it fixed your > problem). I am using Catalina from within the Turbine TDK which contains a > schell script startup.sh which calls the catalina.sh script. I have added > the -nonaming to this line so it reads > > $BASEDIR/catalina.sh start -nonaming "$@" > > This should turn naming off, but I still get the errors when I start the > program this way. > > > > -Original Message- > > From: [EMAIL PROTECTED] > > [mailto:[EMAIL PROTECTED]]On Behalf Of Bordet, > > Simone > > Sent: Thursday, May 10, 2001 6:42 PM > > To: '[EMAIL PROTECTED]' > > Subject: R: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error > > > > > > Hey John > > > > > Yes, I have tried that, and I still get the error. (It seems > > > like it has no > > > effect) Do you have this configuration working? > > > > Not exactly. I'm using Catalina with another server application > > that has its > > own Naming service, and at the beginning I got the same error > on startup, > > but it went away with the -nonaming option. > > We then have other problems with this jndi: protocol, also from previous > > discussions it seems to me a Catalina bug: with us, every class > > loaded from > > web-inf/classes or web-inf/lib has a codebase like > > "jndi:/WEB-INF/classes/" > > or "jar:jndi:/WEB-INF/lib/xxx.jar!/", so that if objects of > these classes > > are passed as arguments to any rmi method invocation, on the > > other side the > > class annotation is taken from the stream, but of course the classloader > > cannot understand the Catalina-specific jndi: protocol. > > The context class loader should take care of that probably, but > I did not > > figured it out yet why it doesn't. I miss Rickard ! > > > > Will live, will see. > > > > Cheers > > > > Simon > > > > > > -Original Message- > > > > From: [EMAIL PROTECTED] > > > > [mailto:[EMAIL PROTECTED]]On Behalf Of Bordet, > > > > Simone > > > > Sent: Thursday, May 10, 2001 6:15 PM > > > > To: '[EMAIL PROTECTED]' > > > > Subject: R: [JBoss-user] Catalina and Jboss2.2.1 > > > InitialContext error > > > > > > > > > > > > Do you start Catalina with the -nonaming option, so that from it > > > > you connect > > > > to JBoss' Naming service ? > > > > > > > > Simon > > > > > > > > > -Messaggio originale- > > > > > Da: John Menke [mailto:[EMAIL PROTECTED]] > > > > > Inviato: mercoledì 9 maggio 2001 23:30 > > > > > A: jboss > > > > > Oggetto: [JBoss-user] Catalina and Jboss2.2.1 InitialContext error > > > > > > > > > > > > > > > This error is produced when I try to get an initial JNDI context. > > > > > > > > > > The error is: > > > > > > > > > > javax.naming.CommunicationException[Root exeption is > > > > > java.rmi.ServerException: RemoteException occured in server > > > > > thread; nested > > > > > exception is java.rmi.UnmarshalException: error unmarshalling > > > > > arguments; > > > > > nested exception is java.net.MalformedURL exception: unknown > > > > > protocol: jndi > > > > > > > > > > > > > > > I can get InitalContext in Tomcat 3.2, but Catalina produces > > > > > the error. > > > > > > > > > > Is there a workaround? > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > ___ > > > > > JBoss-user mailing list > > > > > [EMAIL PROTECTED] > > > > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > > > > > > > > > > > ___ > > > > JBoss-user mailing list > > > > [EMAIL PROTECTED] > > > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > > > > > > > ___ > > > JBoss-user mailing list > > > [EMAIL PROTECTED] > > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > > > > > ___ > > JBoss-user mailing list > > [EMAIL PROTECTED] > > http://lists.sourceforge.net/lists/listinfo/jboss-user > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] EJB call other EJB
Just push your page down button for 2 sec when you read this mail and click the http link ;) > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de > Saint-Martin Cecile > Envoyé : jeudi 10 mai 2001 10:07 > À : [EMAIL PROTECTED] > Objet : Re: [JBoss-user] EJB call other EJB > > > > >Have you separated out your interfaces home and remote into a > separate jar > >and declared the class path as a dependency in the manifest for the jar > >files? > What do you mean by decalring classpath as a dependency? > > Someone suggest to create .ear fi:e, is it supporter by JBoss? > > > There is a section in the online documentation that covers this > > subject, and > > it pops up regularly on this mailing list. Search the archives > > just for the > > last week. > Ok, where is the archive? > > >> I have a problem : EJB A is calling EJB B, they are deployed > in different > >> jar files. > >> In ejb-jar.xml file of EJB A, i declared a reference to EJB B > and create > a > >> jboss.xml file to reference the jndi-name of EJB B. > >> When I call EJB A, it try to call EJB B and i have a class not found > >> exception. > >> Do I need to include EJB B files into EJB A .jar file ? > > > Cécile Saint-Martin > [EMAIL PROTECTED] > > > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] EJB 2.0 home methods for Entity EJBs
Yes it does > In some JBoss documentation I was reading about EJB 2.0 support, > but I couldn't find > any details (except of an EJB 2.0 CMP plugin), so I want to ask > my question here: > > Does JBoss support EJB 2.0 home methods for Entity EJBs? > > > Martin > Vincent ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Obscure issue (bug?) with CMP using column mapping
I'll try. This problem is the same as https://sourceforge.net/tracker/?func=detail&aid=417749&group_id=22866&atid= 376685 But with your explanation I see better where to look at. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Dan OConnor > Envoyé : mercredi 9 mai 2001 0:13 > À : [EMAIL PROTECTED] > Objet : RE: [JBoss-user] Obscure issue (bug?) with CMP using column > mapping > > > The spec requires that the state of the bean is loaded before > ejbRemove is called. The JBoss container is not doing this, in > violation of the spec. > > Because commit option A is the default, the state of the bean will > often already be loaded when ejbRemove is called, and the effects > of this bug will not be visible. > > If the state is not already loaded, calling a "get" method will load > the state, which will make it available in ejbRemove, assuming "A". > (If you want to break your workaround, switch to commit "C".) > > Any volunteers to fix this? > > -Dan > > On 8 May 01, at 17:39, David Esposito wrote: > > > Vincent, > > > > You are my hero .. :) ... it works now ... it's always nice when the > > workarounds are painless to integrate ... ;) > > > > Here's the snippet of code: > > > > joinRecords = repHome.findByRetailerID(params.memberCompanyID);} > > > > //Clear the table out for this company > > while(joinRecords != null && joinRecords.hasMoreElements()) > > { > > RepresentativeJoin joinRec = > > (RepresentativeJoin)joinRecords.nextElement(); > > > > log("Representative_ID = " + joinRec.getRepresentative()); > > > > log("Deleting rec..."); > > joinRec.remove(); > > log("Delete succeeded..."); > > } > > > > if the first log() line is missing, the thing bombs out on > remove() like I > > described below ... with one call to the remote interface, the remove() > > works smoothly ... > > > > Is this issue documented sufficiently for you to add it to the list of, > > ahem, "known issues" or do you need me to explore it further? > > > > Thank you very much ... > > > > -Dave > > > > > -Original Message- > > > From: [EMAIL PROTECTED] > > > [mailto:[EMAIL PROTECTED]]On Behalf Of Vincent > > > Harcq > > > Sent: Tuesday, May 08, 2001 4:38 PM > > > To: [EMAIL PROTECTED] > > > Subject: RE: [JBoss-user] Obscure issue (bug?) with CMP using column > > > mapping > > > > > > > > > Hi, > > > if you run remote= fBPK() then remote.remove(), can you try a > > > remote.getanyfield() in between and let me know if it solve > the problem or > > > not. I also saw something similar to that. > > > Thanks. > > > Vincent. > > > > > > > -Message d'origine- > > > > De : [EMAIL PROTECTED] > > > > [mailto:[EMAIL PROTECTED]]De la part de David > > > > Esposito > > > > Envoyé : mardi 8 mai 2001 17:33 > > > > À : [EMAIL PROTECTED] > > > > Objet : [JBoss-user] Obscure issue (bug?) with CMP using > column mapping > > > > > > > > > > > > Hello all, > > > > > > > > I have a weird situation: > > > > JBOSS 2.2.1 > > > > Sun JDK 1.3 > > > > PostGreSQL 7.1 (although I have the same problem with Oracle 8.1.7) > > > > > > > > I have a CMP bean that is used to manipulate join tables > ... (you know, > > > > tables with only 2 columns used for a many-many > relationship) ... rather > > > > than create a half dozen beans, I have created only one and use the > > > > deployment descriptor to map it to the appropriate table. All > > > of my tables > > > > contain 2 integer fields which, when concatenated, form the > PK for the > > > > table. So my deployment descriptors look like the following: > > > > > > > > From ejb-jar.xml: > > > > > > > > > > > > Supplier_Representative > > > > > mypackage.ejb.representativejoin.RepresentativeJoinHome > > > > > mypackage.ejb.representativejoin.RepresentativeJoin > > > > > > > > mypackage.ejb.representativejoin.RepresentativeJoinBean > > > > > > > s> > > > > Container > > > > > > > > mypackage.ejb.representativejoin.RepresentativeJoi >
RE: [JBoss-user] Obscure issue (bug?) with CMP using column mapping
Hi, if you run remote= fBPK() then remote.remove(), can you try a remote.getanyfield() in between and let me know if it solve the problem or not. I also saw something similar to that. Thanks. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de David > Esposito > Envoyé : mardi 8 mai 2001 17:33 > À : [EMAIL PROTECTED] > Objet : [JBoss-user] Obscure issue (bug?) with CMP using column mapping > > > Hello all, > > I have a weird situation: > JBOSS 2.2.1 > Sun JDK 1.3 > PostGreSQL 7.1 (although I have the same problem with Oracle 8.1.7) > > I have a CMP bean that is used to manipulate join tables ... (you know, > tables with only 2 columns used for a many-many relationship) ... rather > than create a half dozen beans, I have created only one and use the > deployment descriptor to map it to the appropriate table. All of my tables > contain 2 integer fields which, when concatenated, form the PK for the > table. So my deployment descriptors look like the following: > > From ejb-jar.xml: > > > Supplier_Representative > mypackage.ejb.representativejoin.RepresentativeJoinHome > mypackage.ejb.representativejoin.RepresentativeJoin > > mypackage.ejb.representativejoin.RepresentativeJoinBean > s> > Container > > mypackage.ejb.representativejoin.RepresentativeJoi > nPK key-class> > False > > representative_id > reference_id > > > Data source > jdbc/MyDB > javax.sql.DataSource > Container > > > > From jaws.xml: > > > Supplier_Representative > > representative_id > representative_id > > > reference_id > supplier_id > > > findBySupplierID > supplier_id = {0} > > > > > So you see that i use the to map between the bean instance > variables and the DB columns (in this case, the reference_id variable maps > to the supplier_id field in the DB) ... my bean PK class looks like: > > public class RepresentativeJoinPK implements Serializable > { > public int representative_id; > public int reference_id; > > public RepresentativeJoinPK() { > this(0,0); > } > > public RepresentativeJoinPK(int representative_id, int reference_id) { > this.representative_id = representative_id; > this.reference_id = reference_id; > } > > public int hashCode(){ > return 0; > } > > public boolean equals(Object o) { > if(o != null && o.getClass().equals(getClass())) > return RepresentativeJoinPK)o).representative_id == > this.representative_id) && (((RepresentativeJoinPK)o).reference_id == > this.reference_id)); > else > return false; > } > > public String toString() { > return Integer.toString(this.representative_id) + "," + > Integer.toString(this.reference_id); > } > } > > Alright, so here's the problem ... If I create a few instances (a few > records), and use them actively, all is well ... For example, if > I create 4 > records during one client interation ... then a second or two > later, try to > read the beans ... then a few seconds later, try to remove() the > beans, all > is well ... > > However, if I either: > > a) let the beans passivate (by letting enough time pass) > b) restart JBOSS > > I am still able to READ the beans from the DB (display the contents of the > field, read the PK using getPrimaryKey() on the remote interface) > but when i > try to do a remove() (i've tried using the home interface's remove(Handle > h), remove(PrimaryKey pk) and the remote interface's remove() methods()) i > get the following exception: > > TRANSACTION ROLLBACK EXCEPTION:Load failed; nested exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class; nested exception is: > java.rmi.ServerException: Load failed; nested exception is: > java.lang.IllegalArgumentException: object is not an instance of > declaring class > java.rmi.ServerException: Load failed; nested exception is: >java.lang.IllegalArgumentException: object is not an instance of > declaring class > java.lang.IllegalArgumentException: object is not an instance of > declaring > class >at java.lang.reflect.Field.get(Native Method) >at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand.getPkFieldValue(JDBCCo > mmand.java > :658) >at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand.setPrimaryKeyParameter > s(JDBCComm > and.java:364) >at > org.jboss.ejb.plugins.jaws.jdbc.JDBCLoadEntityCommand.setParameter > s(JDBCLoad > EntityCommand.java:97) >at > org.jboss.ejb.plugins.jaws.jdbc.JDBCCommand.jdbcExecute(JDBCComman > d.java:159 > ) >at > org.jboss.ejb.plugins.jaws.jdbc.JDBCLoadEntityCommand.execute(JDBC > LoadEntity > Command.java:82) >at > org.jboss.ejb.plugins.jaws.JAWSPersistenceManager.loadEntity(JAWSP > ersistence > Manager.java:150) >at > org.jboss.ejb.plugins.CMPPersistenceManager.l
RE: [JBoss-user] EJB call other EJB
Hi > Hi, > > I have a problem : EJB A is calling EJB B, they are deployed in different > jar files. > In ejb-jar.xml file of EJB A, i declared a reference to EJB B and create a > jboss.xml file to reference the jndi-name of EJB B. > When I call EJB A, it try to call EJB B and i have a class not found > exception. > Do I need to include EJB B files into EJB A .jar file ? Yes, the Home and Remote interfaces of EJB B, you got the "data" from JNDI but you still need the class that the "data" will fill. An expert will explain this with more difficult words, but that's the idea :) > > > Cécile Saint-Martin > [EMAIL PROTECTED] > > Vincent. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] [JBoss-user]expected one name tag ; Someone familar with this er ror?
That is what I mean yes. Take a look at http://www.jboss.org/documentation/HTML/ch05s07.html Regards. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Roman > Brückner > Envoyé : jeudi 3 mai 2001 18:37 > À : '[EMAIL PROTECTED]' > Objet : Re: [JBoss-user] [JBoss-user]expected one name tag ; Someone > familar with this er ror? > > > Is it possible that this has something do to with the , that there > is a name tag required? > > -Ursprüngliche Nachricht- > Von: Roman Brückner [mailto:[EMAIL PROTECTED]] > Gesendet: Donnerstag, 3. Mai 2001 17:29 > An: '[EMAIL PROTECTED]' > Betreff: [JBoss-user] [JBoss-user]expected one name tag ; Someone > familar with this er ror? > > > Hi, > I am trying to deploy a jar file which contains a few EJBs, however I am > getting th efollowing error message: > > [Container factory] Deploying TariffSession > [Container factory] org.jboss.ejb.DeploymentException: Error in > jaws.xml for Ent > ity Discount: expected one name tag > > Well this is my jaws.xml for the discount bean: > > java:/DefaultDS > Oracle8 > > > Discount > Discount > > discountID > discount_id > > > findAll() > > True > > > > Well I don't have a clue how to resolve this, maybe someone can help me, > please. > Roman > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] [JBoss-user]expected one name tag ; Someone familar with this er ror?
Hi, you do not need to define findAll method in jaws.xml, it is magic. Anyway, your definition of finder method is not correct at all. Review the doc Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Roman > Brückner > Envoyé : jeudi 3 mai 2001 17:29 > À : '[EMAIL PROTECTED]' > Objet : [JBoss-user] [JBoss-user]expected one name tag ; Someone familar > with this er ror? > > > Hi, > I am trying to deploy a jar file which contains a few EJBs, however I am > getting th efollowing error message: > > [Container factory] Deploying TariffSession > [Container factory] org.jboss.ejb.DeploymentException: Error in > jaws.xml for Ent > ity Discount: expected one name tag > > Well this is my jaws.xml for the discount bean: > > java:/DefaultDS > Oracle8 > > > Discount > Discount > > discountID > discount_id > > > findAll() > > True > > > > Well I don't have a clue how to resolve this, maybe someone can help me, > please. > Roman > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Nested Properties, dependant value objects, ...
Jim, My comments below. > > Hi, > > I have made added some feature to the way "dependant value objects" are > > mapped to table fields. > > This is for example when I have a UserBean cmp entity bean that have a > > cmp-field address of non primitive type Address, and I want to > store each > > fields of Address into the database using a specific Jaws feature. > > IMHO, with dependant objects being dropped of EJB 2.0, I think this > > feature is important because the standard way to that with ejb 2.0 would > > be to define a cmp bean for my value object which is really > going too far. > > This is a great feature, but the removal of dependents from the EJB 2.0 > spec probably has not too much bearing on it. This, as were > dependents, are > essentially an implementation issue used to reduce complexity and improve > performance by avoiding a remote interface call. > > In EJB 2.0 PFD2, we now have a "local interface" which does not > use RMI as > the remote interface does. This should provide the same reduction in > complexite and overhead dependents would have, but does not > introduce into > the spec a non-design feature that may be confuseing. > > With EJB 2.0 PFD2, you can concentrate on the design of your > system from an > object modeling standpoint without thought of performance due to > coupeling. > Once you have that, you can decide what are local vs remote interfaces. > > So you have added a great feature, but I don't agree it is an improvement > because of the removal of dependents from 2.0. Using the 2.0 local > interface between EBs is a portable solution that should not have > performance issues. I agree...partially... with your comment, when I will write docs on that, I have to be clear it is JBoss specific. Partially because for a value object such as Quantity (a double and a String) or Amount, ... the EJB 2.0 entity bean relationship is not a solution. It is for Address, and these kind of objects. With dependant object it would have been possible (even if I do not like the idea) to have a Quantity d.o., make a client view of it and solve the OO design. Without I need to serialize my Quantity or decompose it in two primitive type fields, both solutions being unacceptable for me (it is a strong word, but cmp are very far from OO design for now) These kinds of objects (we can them as java primitive types extensions in the business object world) were the main reason for my change. Thanks for opening the discussion. > > Jim > > Vincent. _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] Nested Properties, dependant value objects, ...
Hi, I have made added some feature to the way "dependant value objects" are mapped to table fields. This is for example when I have a UserBean cmp entity bean that have a cmp-field address of non primitive type Address, and I want to store each fields of Address into the database using a specific Jaws feature. IMHO, with dependant objects being dropped of EJB 2.0, I think this feature is important because the standard way to that with ejb 2.0 would be to define a cmp bean for my value object which is really going too far. Up to now, this was possible with the fields of Address being public. This is still possible and needed in the special case the dependant value object is a PrimaryKey class of another enity bean. (IMHO, this is a nice feature to make relationships between ejb without having do use a remote interface field because it permits direct sql between tables, and keep an OO relationship that you loose if you map the pk fields as primtive type. >From now it is also possible when the fields of Address are private, have corresponding get/set methods, if Address have a no argument constructor, and if Address is serializable. As it is my first commit to jboss, I would like that somebody validate my work. Let me know of problems and I'll fix them directly. I also read that somebody have begin to document this feature, I would like to add this in his document and commit the all to jboss-docs. Keep me inform please. The preferred way to do it is this: 1. Define address in the cmp bean : public Address address; 2. Define the dependant value Object that must have a no argument constructor. public class Address implements Serializable { private String line1; private String zipCode; // etc... public Address() {} public String getLine1() { return line1; } public void setLine1(String line1) { this.line1 = line1; } // etc... } 3. in ejb-jar, define address as a field address 4. in jaws, define how to compose/decompose this dependant value object to database fields, for example : address.line1 addr_line1 address.zipCode addr_zip Be carefull here that the fields that are not mapped will not be taken into account. I had to choose between this and an automatic mapping feature. IMHO, an automatic mapping feature is not necessary and could cause problem/confusion. To finish, you have to know that it is recursive, you can so have for example address.zipCode.code with a Zip object. That's all folks. Future possible improvements : 1. Multiple tables definition for one bean (Borland permit that, does JBoss want that ?) 2. Collection type support for dependant value objects (one bean to multiple rows/multiple tables) (become quickly a nightmare if you have a cmp bean that have a COllection of dependant value objects that each have a Collection of dvo, etc... or if you want to be able to do lazy loading/dirty checking on the collection, ... ; and with ejb-relationship of ejb 2.0 is it "really" needed ?) Vincent. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Invalid protocol jndi exception thrown by tomcat 4 Beta 3
Hi, I have got the same problem on beta 3 while it was working fine on Beta 1. I am using -nonaming option. I am 99.99% sure (setup done in parallel, install from scratch, ...) it is linked to Beta 3. Beta 1 is working OK. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Bordet, > Simone > Envoyé : mercredi 25 avril 2001 15:28 > À : '[EMAIL PROTECTED]' > Objet : R: [JBoss-user] Invalid protocol jndi exception thrown by tomcat > 4 Beta 3 > > > Hey, > > > No, I don't use that option, I will try it out latter today. > > What does that > > option do? (disable naming, can you elabrate) > > Catalina comes with its own naming implementation, that is by default > active. > So if you have code under web-inf/lib or web-inf/classes that does new > InitialContext(), even if a jndi.properties is in the web application > classpath (pointing to a different naming service than the Catalina one), > Catalina get confused and barfs unknown protocol: jndi > > Since JBoss has its own naming service, you should probably start Catalina > with the -nonaming option. > > I didn't try Catalina with JBoss, but with another application I > wrote (that > has its own naming service), the -nonaming option did the job. > Probably will > do also for JBoss, but I'm not 100% sure of this. > > Let us know. > > HTH, > > Simon > > > > > Thanks, > > > > Mayank > > > > -Original Message- > > From: Bordet, Simone [mailto:[EMAIL PROTECTED]] > > Sent: Wednesday, April 25, 2001 8:51 AM > > To: '[EMAIL PROTECTED]' > > Subject: R: [JBoss-user] Invalid protocol jndi exception thrown by > > tomcat 4 Beta 3 > > > > > > Hey, > > > > how do you start Catalina ? Do you use the -nonaming option ? > > I launch it with (W2K): > > catalina run -nonaming from the Tomcat bin directory. > > > > HTH, > > > > Simon > > > > > -Messaggio originale- > > > Da: Shah, Mayank [mailto:[EMAIL PROTECTED]] > > > Inviato: mercoledì 25 aprile 2001 14:35 > > > A: '[EMAIL PROTECTED]' > > > Oggetto: [JBoss-user] Invalid protocol jndi exception thrown > > > by tomcat 4 > > > Beta 3 > > > > > > > > > I am using Jboss as my ejb server and tomcat 4 Beta 3. Both > > > are running on > > > the > > > same machine, but different processes (2 jvms). I have > > > tested the ejb on > > > it's > > > own from the command line and works fine for the error I am > > > getting in a > > > servlet and jsp. Here is what i have: > > >EJB1 returns primaryKeyEJB2 > > >on EJB2 I execute a method which returns a string. > > > > > > EJB1 works fine, but when I execute a method on EJB2 I get > > > the following > > > exception. In my jar file I have all the required classes, I > > > tried copying > > > the > > > jndi in various lib folders, but no go. I even tried a copy > > > of jndi that i > > > downloaded from sun, but still no go. Can someone look into > > > this and help > > > suggest some possible sollutions. Thanks, > > > > > > > > > > > > > > > java.lang.reflect.UndeclaredThrowableException > > > java.lang.reflect.UndeclaredThrowableException: > > > java.net.MalformedURLException: > > > java.lang.NullPointerException: invalid url: jndi:/WEB- > > > INF/lib/myservlet_with_ejb_client_classes.jar!/ > > > (java. > > > net.MalformedURLException: unknown protocol: jndi) > > > at > > > > > sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(Stream > > > RemoteCall.java:245) > > > at > > > > > sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java: > > > 220) > > > at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:122) > > > at > > > > > org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker_Stub.invoke(Un > > > known Source) > > > at > > > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Question : RollbackException, BMP entity bean, ejbStore,...
Hi, Say you would have calls setName() instead of getName(). Then ejbStore call would be normal for you right ? ejbStore is called to be sure the database is synchronized when the ejb change, and the ejb could potentially change by doing any remote invocations, be it a get or a set. So that's normal behaviour and is not linked to anything in particular inside JBoss, it is standard spec. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Cokorda > Raka Angga Jananuraga > Envoye : dimanche 22 avril 2001 11:51 > A : [EMAIL PROTECTED] > Objet : [JBoss-user] Question : RollbackException, BMP entity bean, > ejbStore,... > > > Hi guys, > > I've just started out to program EJB. Now I've just > reached the end of chapter BMP entity bean. > > From my humble experiment with BMP, I'm faced with a > question,... which I don't know the answer :) > > On the client : from invocation of create(...) method, > the client get a reference to ejb object. I can > confirm that the create(...) method was executed > succesfully by seeing the content of database (a new > row was inserted). > > After that, the client called one of business method > of that ejb object, getName() : > > public String getName() > { > return name; > } > > But an execption, RollbackException, was thrown to the > client as a result of that getName() invocation. > > I wondered, what can go wrong with such a simple > business method ? > > After several hours of tracing, I found out that the > ejbStore() method was incorrect (I mispelled the the > SQL query. The SQLException was wrapped as > EJBException). > > So I fixed the SQL query, and everything's allright. > > The question is : Why ejbStore() ? What does it has to > do with getName() ? At first I didn't suspect the root > of the problem was ejbStore(), but instead ejbLoad(). > My suspicion to ejbStore() came the last,...and this > time it was right, but I still don't know the reason. > > Would somebody help me, by explaining that (perhaps > it's related to entity bean life cycle, and the way > jboss implement...I forgot um... lazy "something" > ???). > > Thanks a lot in advance, > Raka > (http://members.nbci.com/don_raka) > > __ > Do You Yahoo!? > Yahoo! Auctions - buy the things you want at great prices > http://auctions.yahoo.com/ > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Setting up the naming provider
Your remark is for when accessing JNDI server outside JBoss. For the simple case : one jboss server being the JNDI server itself, if I remember, from within one JBoss VM, it is better to specify nothing at all and if nothing is found, the JNDI client will know the JNDI server is itself and avoid Network call. And that would be the WARNING that JBoss gives when he found a jndi.properties in its classpath at startup : "Hey you do not need to do that! I know what I am doing! You will make network round trip for nothing!" To be honest I am not sure about the explanation but the fact is I do not need jndi.properties from inside JBoss to make JNDI lookup. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Lennart > Petersson > Envoyé : jeudi 12 avril 2001 12:48 > À : [EMAIL PROTECTED] > Objet : SV: [JBoss-user] Setting up the naming provider > > > Also useable with core jboss (no tomcat). Just make sure you have > your jndi.properties in your classpath. > /Lennart > > - Original Message - > From: Vincent Harcq <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Thursday, April 12, 2001 8:29 AM > Subject: RE: [JBoss-user] Setting up the naming provider > > > > Hi, > > If you use Tomcat 3.2.1, you can put jndi.properties in the > Tomcat CLASSPATH > > and you do not need any System.setProperty(). That's how JNDI > client has to > > find its property. And that's the more proper usage of it > since you do not > > need to put JNP stuffs somewhere else. > > > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Setting up the naming provider
Hi, If you use Tomcat 3.2.1, you can put jndi.properties in the Tomcat CLASSPATH and you do not need any System.setProperty(). That's how JNDI client has to find its property. And that's the more proper usage of it since you do not need to put JNP stuffs somewhere else. But it really depends if your JNDI client does not mess with these System properties. If the client overwrite them somewhere, jndi.properties will be no help. When I tested Catalina, I faced the problem that they come with a JNDI implementation that harcode factory.initial and provider.url somewhere, so you have to overwrite them in the code. The good solution to that is to use -nonaming on Catalina so that Catalina does not overwrite these System properties. I do not know with Embedded Tomcat, I do not use that. So you have to look at what your JNDI client do and verify, when you create a InitialContext, what the values are inside System.properties to be sure a bad boy did not change them somewhere. Vincent. > -Message d'origine- > De : [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]De la part de Michael > Hustler > Envoyé : mercredi 11 avril 2001 19:46 > À : Jboss (E-mail) > Objet : [JBoss-user] Setting up the naming provider > > > In a real system, how are people setting up the naming provider? > Is anyone using jndi.properies? > > I have some code in my client to explicitly set the system properties: > System.setProperty("java.naming.factory.initial", > "org.jnp.interfaces.NamingContextFactory"); > System.setProperty("java.naming.provider.url", > "localhost:1099"); > > I have seen others who have defined a for each of these > parameters in a .xml file (ejb-jar.xml or jboss.xml?). The env > is then read > in and set. > > Is this the normal way of doing this or is there a way to get > jndi.properties to be read automatically? > > thanks! > mike. > > ___ > JBoss-user mailing list > [EMAIL PROTECTED] > http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Gosh, this is slow !
> whole RMI remote invocation loop over and over. Actually, ten seconds is > not bad considering that you are bringing the data into Swing. Have somebody tried that with WebLogic. It is not 10 seconds but 10 minutes ;) It is not "not bad", it is EXCELENT ! (A free compliment is not a free contribution, but may this makes you all developers feel happy) Vincent. _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Forking threads in JBoss
Hi > > Dear all, > I try to implement the following scenario within JBoss: > Session bean S creates entity bean E. > S.eventHandler() calls E.executeRequest(). > E is supposed to do some stuff which might take some time and > then callback > S when it's finished. In the meantime S should continue processing other > requests. > Here is my problem: > Whatever I do, S always waits for E to complete executeRequest(). That's normal if you do not use Thread, no ? > I tried a > thread subclass within E and called run() in executeRequest() but > that does > not help (and the EJB spec says I am not supposed to deal with threads). > How can I achieve concurrent processing for E.executeRequest() and > S.eventHandler()? As you said the spec does not allow using Threads inside an EJB. But it is permitted inside a client class. Maybe the answer to your problem is using a client class ? Or JMS ? > Kind regards, > Michael > > Vincent _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Can I find a Deployment tool?
Oh yes, everything but not the deployment. But copy a file to another directory is not too difficult, is it? ;) -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de Vincent Harcq Envoyé : mardi 3 avril 2001 20:19 À : [EMAIL PROTECTED] Objet : RE: [JBoss-user] Can I find a Deployment tool? Hi, EJX is the GUI tool To start it simply double click ejx.jar under bin/ (Windows) or run a script java -jar ejx.jar (Unix) Vincent -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de Rajeev Bacchu Envoyé : mardi 3 avril 2001 12:51 À : jboss Objet : [JBoss-user] Can I find a Deployment tool? Hi, Is'nt there a GUI deployment tool for JBoss that can take inputs, compose deployment descriptors, bundle all the classes, resources into a jar and deploy it, Like what comes with Sun's J2EE Reference implementation? having to write all the deployment descriptors in xml then putting them all in a jar through command lines and deploying the apps seem to be cumbersome. Is there an easy way out? -RawLife. _ Care a click for Nature? http://rainforest.care2.com/i?p=691557508 ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] Can I find a Deployment tool?
Hi, EJX is the GUI tool To start it simply double click ejx.jar under bin/ (Windows) or run a script java -jar ejx.jar (Unix) Vincent -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de Rajeev Bacchu Envoyé : mardi 3 avril 2001 12:51 À : jboss Objet : [JBoss-user] Can I find a Deployment tool? Hi, Is'nt there a GUI deployment tool for JBoss that can take inputs, compose deployment descriptors, bundle all the classes, resources into a jar and deploy it, Like what comes with Sun's J2EE Reference implementation? having to write all the deployment descriptors in xml then putting them all in a jar through command lines and deploying the apps seem to be cumbersome. Is there an easy way out? -RawLife. _ Care a click for Nature? http://rainforest.care2.com/i?p=691557508 ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] exception handling
Hi! Do not use RemoteException but your a new one you create. throw MyException("blablabla"); RemoteException is considered System is catch by the server and rethrown. A custom Exception is also catched but rethrown the same. Vincent. -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]De la part de fractals Envoyé : mardi 6 mars 2001 16:11 À : [EMAIL PROTECTED] Objet : [JBoss-user] exception handling Let's consider the following remote method implementation (this is the implementation of a method defined in a remote interface of an EJB): public UserSession getSession ( String sessionId, String requestId, String requestIdentifier ) throws RemoteException, CreateException, FinderException { UserSessionHome home = ( UserSessionHome ) getHome ("gatekeeper/UserSession", UserSessionHome.class); UserSession session = home.findByLastRequest ( sessionId, requestId, requestIdentifier ); if ( session.timedOut () ) { System.out.println ( "session timed out" ); throw new RemoteException ( "Session Timed Out" ); } session.setNew ( false ); session.setRequestId ( forgeId ( 30 ) ); session.setLastAccessedDate ( new java.sql.Timestamp System.currentTimeMillis () ) ); return session; } Now, this is a code that's executed by a client try { session = gatekeeper.getSession ( session.getSessionId (), session.getRequestId (), "get session again test" ); textarea.append ( "sessionId: " + session.getSessionId () + "\n" ); textarea.append ( "requestId: " + session.getRequestId () + "\n" ); textarea.append ( "isNew: " + session.getNew () + "\n" ); } catch ( java.rmi.RemoteException e ) { textarea.append ( "Remote Exception: " + e.getMessage () ); } catch ( Exception e ) { textarea.append ( "couldn't get the same session\n" ); stackTrace ( e ); } I *would* like to catch a RemoteException with my message (ie "Session Timed Out" ) but instead I get my exception nested in another RemoteException: Remote Exception: RemoteException occurred in server thread; nested exception is: java.rmi.RemoteException: Session Timed Out That is, Ideally, I would create a custom exception, TimedOutException, which I'd like to catch appropriately, but that's apparently impossible, and for the very moment, it is quite annoying for me. Does someone know how to solve this problem ? Thanks in advance, candide kemmler ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user