Hi !

I still can't get the client program to run. When I start the server
(with all debug levels on) this is what I see :

JOnAS - Version 1.5
main : 11:1:30:314     Working with a colocated Transaction Manager
main : 11:1:30:353 Create and register TM factory
main : 11:1:30:423 TransactionFactory constructor
main : 11:1:30:619 Current.Current(TransactionFactory tmfact)
main : 11:1:30:628 Batch constructor
main : 11:1:30:632 Clock constructor
main : 11:1:30:634 Register UserTransactionFactory
main : 11:1:30:707 Current.getReference()
main : 11:1:30:853 Container.Container()
main : 11:1:30:855 String Env.getDataSources()
main : 11:1:30:857     datasources=[Cloudscape]
main : 11:1:30:921 ConnectionManager.ConnectionManager()
main : 11:1:30:929 XADataSourceImpl.XADataSourceImpl()
main : 11:1:30:930 ConnectionManager.setDataSourceName: jdbc_2
main : 11:1:30:932 XADataSourceImpl.setDataSourceName(jdbc_2)
main : 11:1:30:933 ConnectionManager.setUrl(String
jdbc:cloudscape:/home/dls/ejb/cloudscape/data/ContagemLigacoes)
main : 11:1:30:936 ConnectionManager.setClassName(String
COM.cloudscape.core.JDBCDriver)
main : 11:1:30:937 Load JDBC driver COM.cloudscape.core.JDBCDriver
main : 11:1:32:518 ConnectionManager.setUserName(String none)
main : 11:1:32:520 ConnectionManager.setPassword(String none)
main : 11:1:32:521 JDBC DataSource jdbc_2 is mapped on
Cloudscape.properties
main : 11:1:32:522 Current.addConnectionManager(ConnectionManager ds)
main : 11:1:32:574 String Env.getDescBeans()
main : 11:1:32:576     descriptors=[/home/dls/tools/jonas_jdk1.1/DD.ser]

main : 11:1:32:578 Container.addBeans(Vector
[/home/dls/tools/jonas_jdk1.1/DD.ser])
main : 11:1:33:108  Entity Deployment descriptor is read
main : 11:1:33:109 Remote interface=solsuni.contadorLigacoes.Contador
main : 11:1:33:162
solsuni.contadorLigacoes.JOnASContadorBeanContadorHome loaded
main : 11:1:33:224 JBeanHome constructor for ContadorBean
main : 11:1:33:226 JBeanHome.methodDescriptorsInit()
main : 11:1:33:227 methodDescriptorsInit: ControlDescriptor[] size = 2
main : 11:1:33:229 JBeanHome.register() contadorLigacoes.ContadorHome
main : 11:1:33:283 JEntityHome constructor for ContadorBean
main : 11:1:33:291
JBeanMetaData.JBeanMetaData(ejbHome,solsuni.contadorLigacoes.ContadorHome,
solsuni.contadorLigacoes.Contador, solsuni.contadorLigacoes.ContadorPK,
false, false)
main : 11:1:33:294 JBeanHome.setEJBMetaData()
main : 11:1:33:295 JOnASContadorBeanContadorHome(ContadorBean)
main : 11:1:33:297
EJBHome:solsuni.contadorLigacoes.JOnASContadorBeanContadorHome for
ContadorBean available
main : 11:1:33:298 Server.main() : Container() call successfull

main : 11:1:33:319 Adm.Adm()
main : 11:1:33:320 String Env.getJonasName() -> solsuni
main : 11:1:33:437 rebind done solsuni_Adm

When I call the client in another shell (with the same environment that
I used to run the server, set up on a script),
it throws two exceptions. The first in the call to a finder method. On
the client side this is what happens :

java.rmi.ServerError: Server Error; nested exception is:
        java.lang.NoClassDefFoundError:
org/objectweb/jonas/container/EntityContextImpl

If the row didn't exist this wouldn't surprise me, but it does and it
contains a sole row with a primary key 1. Meanwhile on the server side :

TCP Accept-8 : 11:16:23:818 inRequest --->
TCP Accept-8 : 11:16:23:820 Current.setPropagationContext(null) ->
detach
TCP Accept-8 : 11:16:23:821 JEntityHome.getEJBObject()1
TCP Accept-8 : 11:16:23:822 There is no EJBObject for this primary key 1

TCP Accept-8 : 11:16:23:824
solsuni.contadorLigacoes.JOnASContadorBeanContador[RemoteStub [ref:
[endpoint:[192.168.10.121:34516](local),objID:[9]]]].JBean()
TCP Accept-8 : 11:16:23:826 JOnASContadorBeanContador()
TCP Accept-8 : 11:16:23:827 Current.getTransaction()
TCP Accept-8 : 11:16:23:828 JBeanEntity.createContext(Transaction tx)
TCP Accept-8 : 11:16:23:830
EntitySynchroImpl.EntitySynchroImpl(solsuni.contadorLigacoes.ContadorBean@1dc63c7b
containerManaged= true)
TCP Accept-8 : 11:16:23:832 Current.getTransaction()

Here, apparently there is no row in the database with a primary key 1.
But there is and I know so, because I inspected the database contents
using a tool from the database vendor. It seems that, or the fields
aren't correctly mapped (I doubt't it, there are only two of them) , or
my where clause isn't correct. Below is my Cloudscape.properties file :

datasource.name             jdbc_2
datasource.url
jdbc:cloudscape:/home/dls/ejb/cloudscape/data/ContagemLigacoes
datasource.classname    COM.cloudscape.core.JDBCDriver
datasource.username     none
datasource.password      none

Below is my properties file that goes with the deployment descriptor :

datasource.name             jdbc_2
db.TableName                 NUMEROLIGACOES
db.Field.id                         ID
db.Field.numLigacoes    CONTAGEM
db.Finder.findById          where ID = ?

The second exception occurs in a call to a create method that is made if
the finder method returns an exception :

java.rmi.ServerError: Server Error; nested exception is:
        java.lang.NoClassDefFoundError:
org/objectweb/jonas/container/EntityContextImpl

On the server side :

TCP Accept-9 : 11:16:24:23 inRequest --->
TCP Accept-9 : 11:16:24:24 Current.setPropagationContext(null) -> detach

TCP Accept-9 : 11:16:24:25 JOnASContadorBeanContadorHome.create(int)
TCP Accept-9 : 11:16:24:28
solsuni.contadorLigacoes.JOnASContadorBeanContador[RemoteStub [ref:
[endpoint:[192.168.10.121:34516](local),objID:[10]]]].JBean()
TCP Accept-9 : 11:16:24:29 JOnASContadorBeanContador()
TCP Accept-9 : 11:16:24:30 Current.getTransaction()
TCP Accept-9 : 11:16:24:31 JBeanEntity.createContext(Transaction tx)
TCP Accept-9 : 11:16:24:33
EntitySynchroImpl.EntitySynchroImpl(solsuni.contadorLigacoes.ContadorBean@1dc63dc8
containerManaged= true)
TCP Accept-9 : 11:16:24:35 Current.getTransaction()

Any hints ? Anyone wanting to help please ask for more information if
needed.

Thanks in advance

Daniel

Reply via email to