[EJB/JBoss] - Setting up an EJB Client
by stscit04
Hi,
How do I setup an EJB Client? As ar as I understood it,
I need to have on the classpath of a standalone client:
- jar containing the EJB3 business interfaces (the ones
annotated with @remote)
- jar with ejb-annotations because the business interfaces depend on them
- ???
Is there a list of jars available that I need in order to
connect to jboss?
Another question is regadring entitybeans (EJB 3). With EJB 2.1 and
XDoclet, there was an xdoclet task that generated POJOs and
methods in the entity beans that filled/read the pojos. Back then,
I wrote Session beans as POJO/EntityBean converters. Is there a
more convinient way of doing this in EJB 3?
Thanks for any pointers to appropriate documentation or
other help.
Best regards,
Stefan
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4102888#4102888
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4102888
18 years, 7 months
[JBossWS] - Is it valid?
by pdepaepe
Hello,
I'm very noob on WS, so, excuse me in advance.
I wish to submit several Users in one soap request.
Let's say that a user is :
@Entity
| @Name("user")
| public class User implements Serializable
| {
|
| private int id;
| private String uid;
|
| public User(){}
|
| @Id
| public int getId()
| {
| return id;
| }
|
| public void setId(int id)
| {
| this.id = id;
| }
|
| public String getUid()
| {
| return uid;
| }
|
| public void setUid(String uid)
| {
| this.uid = uid;
| }
|
| }
Is such web method allowed?
@Stateless
| @WebService(name = "UserService", serviceName = "UserService")
| public class UserService implements UserServiceRemote
| {
|
| @Logger
| private static Log log;
|
| @WebMethod
| @WebResult(name="count")
| public int countUsers (
| @WebParam(name="users") User[] users){
| return users.length;
| }
|
| }
In soapUi, i'm abble to build easily a soap envelope wich return the exact count of users, but in PHP (nusoap or php5lib), the parser never build the correct enveloppe. So i have some doubts on the validity of my service.
(i have to try a java client too).
Thank you.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4102886#4102886
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4102886
18 years, 7 months
[JBoss Seam] - How to configure quartz with Seam 2.0 GA, Postgres & jdbc.jo
by Stateless Bean
Hi,
I try to configure quartz to load jbos from db, using seam 2.0.GA JBoss 4.2, and postgres
Here is my configuration
| #========================================================================== ==
| # Configure Main Scheduler Properties
| #========================================================================== ==
|
| org.quartz.scheduler.instanceName = DefaultQuartzScheduler
| org.quartz.scheduler.rmi.export = false
| org.quartz.scheduler.rmi.proxy = false
| org.quartz.scheduler.wrapJobExecutionInUserTransaction = false
| org.quartz.scheduler.useClassLoaderOfInitializer = true
|
| #====================================================================== ======
| # Configure ThreadPool
| #========================================================================== ==
|
| org.quartz.threadPool.class = org.quartz.simpl.SimpleThreadPool
| org.quartz.threadPool.threadCount = 10
| org.quartz.threadPool.threadPriority = 5
| org.quartz.threadPool.threadsInheritContextClassLoaderOfInitializingThread = true
|
| org.quartz.jobStore.misfireThreshold = 10000
|
| #====================================================================== ======
| # Configure JobStore
| #========================================================================== ==
|
| org.quartz.jobStore.misfireThreshold 60000
|
| #org.quartz.jobStore.class = org.quartz.simpl.RAMJobStore
|
| org.quartz.jobStore.class = org.quartz.impl.jdbcjobstore.JobStoreTX
| org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.PostgreSQLDelegate
| #org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.StdJDBCDelegate
| #org.quartz.jobStore.dataSource = myDS
| org.quartz.jobStore.dataSource = MLMDatasource
| org.quartz.jobStore.tablePrefix = QRTZ_
|
| #====================================================================== ======
| # Configure Datasources
| #========================================================================== ==
|
| org.quartz.dataSource.MLMDatasource.driver = org.postgresql.Driver
| org.quartz.dataSource.MLMDatasource.URL = jdbc:postgresql://localhost:5432/mlm
| org.quartz.dataSource.MLMDatasource.user = postgres
| org.quartz.dataSource.MLMDatasource.password = root
| org.quartz.dataSource.MLMDatasource.maxConnections = 5
|
MLMDataSource is same as DS from app:
| <datasources>
| <local-tx-datasource>
| <jndi-name>MLMDatasource</jndi-name>
| <connection-url>jdbc:postgresql://localhost:5432/mlm</connection-url&g t;
| <driver-class>org.postgresql.Driver</driver-class>
| <user-name>postgres</user-name>
| <password>root</password>
| <blocking-timeout-millis>50000</blocking-timeout-millis>
| </local-tx-datasource>
| </datasources>
|
I configured all like in seam "quartz" example, also got quartz.jar in ear file, but still get errors when jboss start up.
| 13:32:51,531 ERROR [[/mlm]] Exception sending context initialized event to listener instance of class org.jboss.seam.servlet.SeamListener
| java.lang.RuntimeException: exception invoking: initScheduler
| at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:135)
| at org.jboss.seam.Component.callComponentMethod(Component.java:2074)
| at org.jboss.seam.Component.callCreateMethod(Component.java:1997)
|
| ....
|
| Caused by: java.lang.ClassNotFoundException: No ClassLoaders found for: org.apache.commons.dbcp.BasicDataSource
| at org.jboss.mx.loading.LoadMgr3.beginLoadTask(LoadMgr3.java:306)
| at org.jboss.mx.loading.RepositoryClassLoader.loadClassImpl(RepositoryClassLoader. java:514)
| at org.jboss.mx.loading.RepositoryClassLoader.loadClass(RepositoryClassLoader.java :408)
| at java.lang.ClassLoader.loadClass(Unknown Source)
| at java.lang.ClassLoader.loadClassInternal(Unknown Source)
|
Any help? Can anyone show me example how to configure it?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4102876#4102876
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4102876
18 years, 7 months