[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Define DB2 schema in data-source.xml ?

2005-12-19 Thread stscit04
Hi,

is there a way to set the db2 schema to use in the
datasource definition? something like

 
 myds
 url
com.ibm.db2.jcc.DB2Driver


myschema


user
pass
  

Thanks in advance,

Stefan


View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3913372#3913372

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3913372


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - JBoss 3.2.6 + DB2 8.1 TIMESTAMP finder

2005-11-16 Thread stscit04
Hi,

I have the following finder

@ejb.finder signature="java.util.Collection
 * findByOpenAndOlderThan(java.util.Date d)" query="SELECT
 * OBJECT(tx) FROM Transaction AS tx WHERE  
tx.merchantTimestamp < ?1
 * AND tx.sc=0 AND tx.bankTimestamp IS NULL"
 *
The field in DB2 are of type TIMESTAMP. The finder fails with

 Find failed: COM.ibm.db2.jdbc.DB2Exception: [IBM][CLI Driver][DB2/LINUX] 
SQL0401N  The data types of the operands for the operation "<" are not 
compatible.  SQLSTATE=42818

If I use the db2 prompt to select from the db, it works. Unfortunatly,
I cannot how the String that jboss gives in the SQL looks like,
because the log only shows an ? in the generated SQL instead of the
actual value.

Thanks for any advice,

Stefan

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3907381#3907381

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3907381


---
This SF.Net email is sponsored by the JBoss Inc.  Get Certified Today
Register for a JBoss Training Course.  Free Certification Exam
for All Training Attendees Through End of 2005. For more info visit:
http://ads.osdn.com/?ad_id=7628&alloc_id=16845&op=click
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: Can any one help me in writing CMP2.0 application

2004-12-29 Thread stscit04
Check out Xdoclet for generation of jboss-specific deployment descriptors.

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3860099#3860099

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3860099


---
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - CMR bean.addRelation(relatedBean) failes

2004-12-22 Thread stscit04
Hi,

I am using Jboss 3.2.6 with the SLQ92 Compiler and have the following
problem:

I have 3 CMP entity beans (A1,A2 and B) both A beans hava a 
1-1 relationship to B (A1 1---1 B 1 --- 1 A2). I can create a new 
instance of A1 and call b.set(a1), however the exact same call
failes if I create a new instance of A2 and try b.setA2(a2)
(Note that the instances of B are not the same)

(B is PartnerPaymentRootContract, A2 is GenericContractualPartner)

The call to b.setA2(a2) results in the following exception:

  | javax.ejb.NoSuchObjectLocalException: Entity not found: primaryKey=
  | 
  | at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:158)
  | 
  | at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:341)
  | 
  | at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:148)
  | 
  | at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:111)
  | 
  | at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
  | 
  | at 
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
  | 
  | at 
org.jboss.ejb.EntityContainer.internalInvoke(EntityContainer.java:484)
  | 
  | at org.jboss.ejb.Container.invoke(Container.java:709)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.invokeRemoveRelation(JDBCCMRFieldBridge.java:1211)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.createRelationLinks(JDBCCMRFieldBridge.java:979)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.createRelationLinks(JDBCCMRFieldBridge.java:961)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.setInstanceValue(JDBCCMRFieldBridge.java:897)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.setValue(JDBCCMRFieldBridge.java:708)
  | 
  | at 
org.jboss.ejb.plugins.cmp.bridge.EntityBridgeInvocationHandler$FieldSetInvoker.invoke(EntityBridgeInvocationHandler.java:156)
  | 
  | at 
org.jboss.ejb.plugins.cmp.bridge.EntityBridgeInvocationHandler.invoke(EntityBridgeInvocationHandler.java:91)
  | 
  | at org.jboss.proxy.compiler.Runtime.invoke(Runtime.java:62)
  | 
  | at 
de.fiducia.giropay.billingEntity.PartnerPaymentRootContractCMP$Proxy.setGenericContractualPartner()
  | 
  | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  | 
  | at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
  | 
  | at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  | 
  | at java.lang.reflect.Method.invoke(Method.java:324)
  | 
  | at 
org.jboss.ejb.EntityContainer$ContainerInterceptor.invoke(EntityContainer.java:1123)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.JDBCRelationInterceptor.invoke(JDBCRelationInterceptor.java:72)
  | 
  | at 
org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invoke(EntitySynchronizationInterceptor.java:289)
  | 
  | at 
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)
  | 
  | at 
org.jboss.ejb.plugins.EntityReentranceInterceptor.invoke(EntityReentranceInterceptor.java:116)
  | 
  | at 
org.jboss.ejb.plugins.EntityInstanceInterceptor.invoke(EntityInstanceInterceptor.java:175)
  | 
  | at 
org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:89)
  | 
  | at 
org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreationInterceptor.java:54)
  | 
  | at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:84)
  | 
  | at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:315)
  | 
  | at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:148)
  | 
  | at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:111)
  | 
  | at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
  | 
  | at 
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
  | 
  | at 
org.jboss.ejb.EntityContainer.internalInvoke(EntityContainer.java:484)
  | 
  | at org.jboss.ejb.Container.invoke(Container.java:709)
  | 
  | at 
org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invoke(BaseLocalProxyFactory.java:419)
  | 
  | at org.jboss.ejb.plugins.local.EntityProxy.invoke(EntityProxy.java:44)
  | 
  | at $Proxy272.setGenericContractualPartner(Unknown Source)
  | 
  | at 
de.fiducia.giropay.logic.UpdateManagerBean.updatePartnerPaymentRootContract(UpdateManagerBean.java:1419)
  | 
  | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  | 
  | at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
  | 
  | at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(Delegat

[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB QL: Selecting anything different than entity beans

2004-12-22 Thread stscit04
Arne,

you should really make yourself familiar with
the documentation of Jboss, it will help you understand
how ejb-selects are _different_ from ejb-finder methods.

They ARE used to retrieve only a single field of
an entity bean. You also should take the time
and read the chapter about load-sets and other
optimizations.

Regards,

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3859600#3859600

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3859600


---
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: Adding CMR fails

2004-12-21 Thread stscit04
I have a similar problem. I have 3 Beans A1,A2 and B.
both A1 and A2 have a 1-1 relationship to B. B
has a 1-1 Relationship to both A1 and A2.

If I create a instance of B and call b-setA1(A1), everything
works, whereas b.setA2(A2) doesnt work. The Relationships
are defined identical. I get the following Error


  | 2004-12-21 14:38:40,671 ERROR [org.jboss.ejb.plugins.LogInterceptor] 
TransactionRolledbackLocalException in method: null, causedBy:
  | 
  | javax.ejb.NoSuchObjectLocalException: Entity not found: primaryKey=
  | 
  | at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:158)
  | 
  | at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:341)
  | 
  | at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:148)
  | 
  | at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:111)
  | 
  | at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
  | 
  | at 
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
  | 
  | at 
org.jboss.ejb.EntityContainer.internalInvoke(EntityContainer.java:484)
  | 
  | at org.jboss.ejb.Container.invoke(Container.java:709)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.invokeRemoveRelation(JDBCCMRFieldBridge.java:1211)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.createRelationLinks(JDBCCMRFieldBridge.java:979)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.createRelationLinks(JDBCCMRFieldBridge.java:961)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.setInstanceValue(JDBCCMRFieldBridge.java:897)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCCMRFieldBridge.setValue(JDBCCMRFieldBridge.java:708)
  | 
  | at 
org.jboss.ejb.plugins.cmp.bridge.EntityBridgeInvocationHandler$FieldSetInvoker.invoke(EntityBridgeInvocationHandler.java:156)
  | 
  | at 
org.jboss.ejb.plugins.cmp.bridge.EntityBridgeInvocationHandler.invoke(EntityBridgeInvocationHandler.java:91)
  | 
  | at org.jboss.proxy.compiler.Runtime.invoke(Runtime.java:62)
  | 
  | at 
de.fiducia.giropay.billingEntity.PartnerPaymentRootContractCMP$Proxy.setGenericContractualPartner()
  | 
  | at 
de.fiducia.giropay.billingEntity.PartnerPaymentRootContractBean.setContractualPartner(PartnerPaymentRootContractBean.java:326)
  | 
  | at 
de.fiducia.giropay.billingEntity.PartnerPaymentRootContractBean.ejbPostCreate(PartnerPaymentRootContractBean.java:146)
  | 
  | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  | 
  | at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
  | 
  | at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  | 
  | at java.lang.reflect.Method.invoke(Method.java:324)
  | 
  | at 
org.jboss.ejb.plugins.CMPPersistenceManager.postCreateEntity(CMPPersistenceManager.java:233)
  | 
  | at 
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.postCreateEntity(CachedConnectionInterceptor.java:278)
  | 
  | at 
org.jboss.ejb.EntityContainer.postCreateLocalHome(EntityContainer.java:589)
  | 
  | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  | 
  | at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
  | 
  | at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  | 
  | at java.lang.reflect.Method.invoke(Method.java:324)
  | 
  | at 
org.jboss.ejb.EntityContainer$ContainerInterceptor.invoke(EntityContainer.java:)
  | 
  | at 
org.jboss.ejb.plugins.cmp.jdbc.JDBCRelationInterceptor.invoke(JDBCRelationInterceptor.java:72)
  | 
  | at 
org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invoke(EntitySynchronizationInterceptor.java:289)
  | 
  | at 
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)
  | 
  | at 
org.jboss.ejb.plugins.EntityReentranceInterceptor.invoke(EntityReentranceInterceptor.java:116)
  | 
  | at 
org.jboss.ejb.plugins.EntityInstanceInterceptor.invoke(EntityInstanceInterceptor.java:175)
  | 
  | at 
org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:89)
  | 
  | at 
org.jboss.ejb.plugins.EntityCreationInterceptor.invokeHome(EntityCreationInterceptor.java:44)
  | 
  | at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:88)
  | 
  | at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:315)
  | 
  | at 
org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:128)
  | 
  | at 
org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.java:85)
  | 
  | at 
org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogIn

[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB QL: Selecting anything different than entity beans

2004-12-21 Thread stscit04
Well, just forget the WHERE clause and you will get
the names of all customers. Anohter possibillity is to define
load-sets that correspond with the Xdoclet-defined value-objects.
(You can define more than one VO for an EB).

Regards,

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3859469#3859469

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3859469


---
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB QL: Selecting anything different than entity beans

2004-12-21 Thread stscit04
What you migth want are EJB-Selects, they allow
you to do something like

SELECT c.name FROM Customer AS c WHERE c.id=?1

EJB-Selects are descibed in the JBoss dokumentation
and are supported by special XDoclet-Tags.


Regards,

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3859451#3859451

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3859451


---
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB Select not working

2004-12-21 Thread stscit04
Hi,

thanks for your help, it works! 
Is the SQL92 Compiler scheduled to become the
default compiler for the JBoss 3.x series?

Regards

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3859436#3859436

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3859436


---
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB Select not working

2004-12-20 Thread stscit04
I tried 3.2.6 and the Exception disappeared. But the query still gives
incorrect results (or at least unexpected results, maybe I am thinking
in the wrong way)

The SQL executed under 3.2.6 is:

SELECT DISTINCT t0_m.id FROM Merchant t0_m, MerchantPartnerContract 
t1_m_merchantPartnerContract WHERE 
(t1_m_merchantPartnerContract.id IS NULL AND 
t0_m.id=t1_m_merchantPartnerContract.merchantId)

Which doesn't return anything because the id-field of the
merchantPartnerContract is the PK-field and therefore never
NULL.

The query should retun the merchant.id field for all
merchants that don't have a contract (and therefore dont
show up in the merchantParnterContract.merchantId column).

Please let me know how to formulate a EJB QL query that
returns the desired results. Or maybe this IS a bug?

Thanks in advance,

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3859271#3859271

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3859271


---
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB Select not working

2004-12-16 Thread stscit04
I set logging to debug and the generated SQL is

Executing SQL: SELECT DISTINCT t0_m.id FROM Merchant t0_m WHERE 
(t1_m_merchantPartnerContract.id IS NULL)

which doesn't look ok to me... 

Regards

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3858915#3858915

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3858915


---
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - EJB Select not working

2004-12-16 Thread stscit04
Hi,

I have 2 CMP Beans that have a 1-1 relationship
Merchant and MerchantPartnerContract. I need to find
all Merchants that dont have a contract, and to get their 
Ids. I trie to do this using the ejb-select

SELECT m.id FROM Merchant AS m WHERE m.merchantPartnerContract IS NULL

JBoss deploys it, but when I call the method, I get the following Exception

Find failed: java.sql.SQLException: General error message from server: "
Unknown table 't1_m_merchantPartnerContract' in where clause";

The table is indeed unknow because it doesnt exist on the database...

I am running Jboss 3.2.2, Mysql 4.0.14 and mysql connector 3.0.16

Thanks in advance for any suggestion,

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3858899#3858899

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3858899


---
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [EJB/JBoss] - Re: Unable to access remote entity bean. plz suggest

2004-07-09 Thread stscit04
If I understand your setup correctly, you are
using the enity-beans remote interface, this 
is usually not a good application design. Instead,
you should use a session bean in the same container as
a facade to the enity bean. 

This is just a general suggestion, witout any
cde I am not shure if I understand your setup
correctly. Please post the code I asked for in the 
previous posting.

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3841478#3841478

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3841478


---
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - 
digital self defense, top technical experts, no vendor pitches, 
unmatched networking opportunities. Visit www.blackhat.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [EJB/JBoss] - Re: Unable to access remote entity bean. plz suggest

2004-07-09 Thread stscit04
Please post the method of the session bean that 
retrieves the entity bean data and returns it to 
the client. 

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3841477#3841477

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3841477


---
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - 
digital self defense, top technical experts, no vendor pitches, 
unmatched networking opportunities. Visit www.blackhat.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [EJB/JBoss] - Package EJB interfaces in client-application/web-module ?

2004-07-09 Thread stscit04
Hi,

I have an EJB Module running in Jboss and 2
Client-Apps, one running stand-alone, one running as web-module
in an tomcat instance. Do I need to package the 
EJB interfaces (home/remote) into the client-apps or
do I need them only at compile-time ?

For now, I am packaging them into the client-app, but this
seems to cause problems when I deploy the 
web-app into the tomcat instance running within jboss.

Do I have to package 2 apps (one running within jboss, one 
running in a stand-alone tomcat) or is there a way to solve this ?
It would also be interesting if there are any best-practices for
situations like this (running client-apps in jboss for development 
and in stand-alone tomcat for production).


Thanks in advance,

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3841475#3841475

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3841475


---
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - 
digital self defense, top technical experts, no vendor pitches, 
unmatched networking opportunities. Visit www.blackhat.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: ejb-select traversing CMR collections

2004-06-21 Thread stscit04
Thanks for your reply.

Your code didnt work, but it tipped me off
into the right direction. The working
statement is:

select c.id from A a, in (a.bs) b, in (b.cs) c WHERE a.id = ?1

Regards,

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3839379#3839379

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3839379


---
This SF.Net email is sponsored by The 2004 JavaOne(SM) Conference
Learn from the experts at JavaOne(SM), Sun's Worldwide Java Developer
Conference, June 28 - July 1 at the Moscone Center in San Francisco, CA
REGISTER AND SAVE! http://java.sun.com/javaone/sf Priority Code NWMGYKND
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - ejb-select traversing CMR collections

2004-06-18 Thread stscit04
Hi,

in my App I have 3 CMP Beans with one to 
many relations.

A 1 --- * B 1 --- * C

(A has multiple B which has multiple C)

I need to get all ids of C for an instance of A. I tried
SELECT c.id FROM A , IN (a.bs.cs) AS c WHERE a.id = ?1)
but it wont work. Is there a way to do this in a single
query or do I have to get all ids of all Bs for one a and then
all ids of all Cs for B in 2 querys ?

Thanks in advance,

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3839218#3839218

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3839218


---
This SF.Net email is sponsored by The 2004 JavaOne(SM) Conference
Learn from the experts at JavaOne(SM), Sun's Worldwide Java Developer
Conference, June 28 - July 1 at the Moscone Center in San Francisco, CA
REGISTER AND SAVE! http://java.sun.com/javaone/sf Priority Code NWMGYKND
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Messaging, JMS & JBossMQ] - One more thing

2004-05-25 Thread stscit04
There is one more thing: 
Though I have set MyPoolSize to 100, it looks like
there is only one MDB Instance working at a time
(I did a log.debug(this,this,messageDrivenContext) and 
in the log I get the same pointers on every call for
about 10 calls, the another one for the next 10 calls and
so on

Maybe I am doing something very wrong, but I have
no clue what 

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3835744#3835744

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3835744



---
This SF.Net email is sponsored by: Oracle 10g
Get certified on the hottest thing ever to hit the market... Oracle 10g. 
Take an Oracle 10g class now, and we'll give you the exam FREE.
http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Messaging, JMS & JBossMQ] - poor MDB performance

2004-05-25 Thread stscit04
Hi,

I am using Jboss 3.2.3 with mysql as persistent store
for JMS messages. I have a large number of messages 
(about 20k) in the store. The performance is not very good,
my MDB gets a new message every 500ms or so. The processing
in the MDB itself takes about 100ms. 

Is there any way to find out where the bottleneck is ? I am 
using the predefinded Queue A. Can anybody tell me how to 
find out which IL is used and how to change it? I have bought 
the documentation but I still cant find out where to set the
IL for a specific Queue.

Thanks in advance,

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3835721#3835721

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3835721



---
This SF.Net email is sponsored by: Oracle 10g
Get certified on the hottest thing ever to hit the market... Oracle 10g. 
Take an Oracle 10g class now, and we'll give you the exam FREE.
http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: JBoss transaction deadlock

2004-05-07 Thread stscit04
Hi,

when does the lock ocour ? on 
ejbFind or on the first invokation of an beans getXX / setXXX method ?

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3834120#3834120

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3834120


---
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to 
deliver higher performing products faster, at low TCO.
http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: Updating entity bean fields using BeanUtils

2004-05-06 Thread stscit04
Hi,

if you are using XDoclet, take a look at 
the @ejb.value-object tag. The handling of 
VOs is described on: 

http://xdoclet.sourceforge.net/valueobjects.html

If you have any questions on this, dont hesitate to post in
this thread

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3833909#3833909

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3833909


---
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to 
deliver higher performing products faster, at low TCO.
http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Executed SQL on findAll()

2004-04-16 Thread stscit04
Hi,

I have an findAll() query in my entityBean. I select large numbers
of beans with this method (up to 30k). The bean has an compound
PK (id (String)  + date (Date)). The server.log shows the following
query:

 Executing SQL: SELECT blz, changeDate, flagDeletion, bankId FROM ShadowBLZ WHERE 
(blz=? AND changeDate=?) OR (blz=? AND changeDate=?) OR (blz=? AND changeDate=?) OR 
(blz=? AND changeDate=?) OR (blz=? AND changeDate=?) OR (blz=? AND changeDate=?) OR 
(blz=? AND changeDate=?) OR (blz=? AND changeDate=?) OR (blz=? AND changeDate=?) OR 
(blz=?  ...

And so on

Is there a way to improve this ? I am using Jboss 3.2.2 + MySQL 4

Thanks in advance

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3830940#3830940

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3830940


---
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - jbossQL in ejbSelect ?

2004-03-08 Thread stscit04
Hi,

is it possible to use JBossQL (we need the COUNT function)
in an ejbSelect method ? I found the jboss.query Xdoclet-tag,
but it seems only to work with ejbFindBy methods. 

Thanks in advance

Stefan

http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3824691#3824691";>View 
the original post

http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3824691>Reply 
to the post


---
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - Re: ejb finder

2004-03-05 Thread stscit04
You have to specify the FULL qualified Name of the 
Classes. use java.lang.String instead of String.

Regards

Stefan

http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3824449#3824449";>View 
the original post

http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3824449>Reply 
to the post


---
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence & CMP/JBoss] - ejbSelect locking behaviour

2004-03-05 Thread stscit04
hi,

What is the expected locking behaviour of ejbSelect methods ?
eg I have a bean called Merchant, if I use an ejbSelectAllMerchantIds
method via an ejbHomeGetAllMerchantIds, would this lock 
all merchant EntityBeans as findAll() would do ?

Thanks in advance,

Stefan

http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3824382#3824382";>View 
the original post

http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3824382>Reply 
to the post


---
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Installation & Configuration] - Stop application on shutdown

2004-02-25 Thread stscit04
Hi, 

in this thread: 

   http://jboss.org/index.html?module=bb&op=viewtopic&t=45890

someone asked about starting an application on startup.
The answer was to use a servlets init-method and 
load-on-startup 1 .

Is there a similar method that gets called on stopping/undeploying the
application ? Can such a method be used to unregister notification
listeners from JMX MBeanservers ?

Thanks in advance

Stefan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3822901#3822901

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3822901


---
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] JBoss MQ doesnt create tables on mySQL

2004-01-20 Thread stscit04
Hi,

I configured Jboss to use MySQL to persist JMS messages.
On startup, I get the following message:

---
12:39:29,515 ERROR [PersistenceManager] Starting failed
org.jboss.mq.SpyJMSException: Could not resolve uncommited transactions. 
Messag
e recovery may not be accurate; - nested throwable:
(java.sql.SQLException: Gene
ral error,  message from server: "Table 'test.jms_messages' doesn't exist")
at
org.jboss.mq.pm.jdbc2.PersistenceManager.resolveAllUncommitedTXs(Pers
istenceManager.java:336)
at
org.jboss.mq.pm.jdbc2.PersistenceManager.startService(PersistenceMana
ger.java:1356)
at
org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:1
92)
at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBea
nDispatcher.java:284)
at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:546)
at
org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceControl
ler.java:976)
at $Proxy14.start(Unknown Source)
at
org.jboss.system.ServiceController.start(ServiceController.java:394)
at
org.jboss.system.ServiceController.start(ServiceController.java:411)
at
org.jboss.system.ServiceController.start(ServiceController.java:411)
at sun.reflect.GeneratedMethodAccessor5.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBea
nDispatcher.java:284)
at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:546)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy4.start(Unknown Source)
at org.jboss.deployment.SARDeployer.start(SARDeployer.java:226)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:832)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:642)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:605)
at sun.reflect.GeneratedMethodAccessor22.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBea
nDispatcher.java:284)
at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:546)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy6.deploy(Unknown Source)
at
org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymen
tScanner.java:302)
at
org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentS
canner.java:476)
at
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.
doScan(AbstractDeploymentScanner.java:201)
at
org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(A
bstractDeploymentScanner.java:274)
at
org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:1
92)
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBea
nDispatcher.java:284)
at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:546)
at
org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceControl
ler.java:976)
at $Proxy0.start(Unknown Source)
at
org.jboss.system.ServiceController.start(ServiceController.java:394)
at sun.reflect.GeneratedMethodAccessor5.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBea
nDispatcher.java:284)
at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:546)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy4.start(Unknown Source)
at org.jboss.deployment.SARDeployer.start(SARDeployer.java:226)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:832)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:642)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:605)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:589)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
s

Re: [JBoss-user] JMS redelivery - how many times ?

2004-01-13 Thread stscit04
Adrian,

again, you saved me a lot of time by sending a single line
of text :-) Thank you so much ! It is really people like you who
make Jboss a better choice than other app-servers (among other things).

Regards,

Stefan

> http://sourceforge.net/tracker/index.php?func=detail&aid=744455&group_id=22866&atid=381174
>
> Regards,
> Adrian
>
> On Tue, 2004-01-13 at 15:13, [EMAIL PROTECTED] wrote:
>> Hi,
>>
>> is there a possibility to tell Jboss to redeliver
>> a message N times to a MDB ? Something like:
>> message.setProperty(JBOSS_JMS_REDELIVERY_COUNT,) ?
>>
>> Thanks in advance
>>
>> Stefan
>>
>>
>> ---
>> This SF.net email is sponsored by: Perforce Software.
>> Perforce is the Fast Software Configuration Management System offering
>> advanced branching capabilities and atomic changes on 50+ platforms.
>> Free Eval! http://www.perforce.com/perforce/loadprog.html
>> ___
>> JBoss-user mailing list
>> [EMAIL PROTECTED]
>> https://lists.sourceforge.net/lists/listinfo/jboss-user
> --
> 
> Adrian Brock
> Director of Support
> Back Office
> JBoss Group, LLC
> 
>
>
>
> ---
> This SF.net email is sponsored by: Perforce Software.
> Perforce is the Fast Software Configuration Management System offering
> advanced branching capabilities and atomic changes on 50+ platforms.
> Free Eval! http://www.perforce.com/perforce/loadprog.html
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>



---
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] JMS redelivery - how many times ?

2004-01-13 Thread stscit04
Hi,

is there a possibility to tell Jboss to redeliver
a message N times to a MDB ? Something like:
message.setProperty(JBOSS_JMS_REDELIVERY_COUNT,) ?

Thanks in advance

Stefan


---
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] session bean lookup and create - where ?

2004-01-12 Thread stscit04
Hi,

I am currently working on a application which
consists of several sessionBeans (stateless).

The session beans are using each other through their
local-interfaces. Bean A is using bean B.

I am using he xdoclet generated util-classes to
lokkup the local-interfaces. The util-classes
cache the home-interface. Is it ok to call the
create() method of the home-interface everytime I
need the bean B in bean A, or should I
keep the local-interface of B in a variable
in bean A and initialise it in the ejbCreate() method
of A ?

Maybe there is a even better way to do this ?

Thanks in advance,

Stefan


---
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] MDB JMS redelivery

2004-01-09 Thread stscit04
Thank you very much,
problem solved !!

Thanks again,

Stefan

> Well your MDB does not run in a transaction context. Here is an example of
> Xdoclet tags that enable JTA transactions in an MDB:
>
> /**
>  * ... other xdoclet stuff here
>  *
>  * @jboss.destination-jndi-name name="queue/parcelInstruction"
>  *
>  * @ejb.transaction type="Required"
>  *
>  * @author Stephane Nicoll
>  * @version$Revision: 1.12.2.1 $
>  */
>
> (MDB accepts only Required and NotSupported, see the spec)
>
> Once it is done, the setRollbackOnly will not do what you want anyway. If
> you
> call it, your message will be rolledback as well as everything which has
> been
> done inside that transaction (namely the creation of your entity bean).
> The
> only solution I see so far for you is to call another session bean with
> RequiresNew as JTA parameter. It will suspend current transaction (the one
> started by your mdb) and create a new one. You can commit the new one (and
> so
> the entity bean)  and still rollback the first one.
>
> Regards,
>
> Stephane
>
>
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: Friday, January 09, 2004 11:37 AM
> To: [EMAIL PROTECTED]
> Subject: RE: [JBoss-user] MDB JMS redelivery
>
>
>> Aaaarggg
> Sorry ;-)
>>
>>>As I understand it, the only way to force re-delivery of the JMS message
>>>is to throw an EJBException to force JBoss to rollback
>>>the transaction.
>>
>> No. You cannot throw an EJBException from onMessage, see the spec. If
>> you
>> want to rollback the message, use
>> messageDriventContext.setRollbackOnly();
>
> I tried this, but then I get the following Exception:
>
> java.lang.IllegalStateException: setRollbackOnly must only be called in
> the context of a transaction (EJB 2.0 - 15.5.1)
> at org.jboss.ejb.MessageDrivenEnterpriseContext$MessageDrivenContextImpl
> .setRollbackOnly(MessageDrivenEnterpriseContext.java:214)
> at de.fag.grobi.logic.NotificationManagerBean.onMessage(NotificationMana
> gerBean.java:190)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> sorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:324)
> at org.jboss.ejb.MessageDrivenContainer$ContainerInterceptor.invoke(Mess
> ...
> 
> ..
>
> I am using XDoclet but it ignores any @ejb.transaction tag
> on the onMessage method of the MDB. Where can I set the transaction
> correctly (probably a xdoclet question)?
>
>>
>> For the mix between JMS and CMP, I have no idea
> When I get the ctx.setRollbackOnly to work, I hope to
> resolve this problem by setting the transaction type
> correctly.
>
> Regards,
>
> Stefan
>
>
> ---
> This SF.net email is sponsored by: Perforce Software.
> Perforce is the Fast Software Configuration Management System offering
> advanced branching capabilities and atomic changes on 50+ platforms.
> Free Eval! http://www.perforce.com/perforce/loadprog.html
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>
>
> ---
> This SF.net email is sponsored by: Perforce Software.
> Perforce is the Fast Software Configuration Management System offering
> advanced branching capabilities and atomic changes on 50+ platforms.
> Free Eval! http://www.perforce.com/perforce/loadprog.html
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>



---
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] MDB JMS redelivery

2004-01-09 Thread stscit04
> Aaaarggg
Sorry ;-)
>
>>As I understand it, the only way to force re-delivery of the JMS message
>>is to throw an EJBException to force JBoss to rollback
>>the transaction.
>
> No. You cannot throw an EJBException from onMessage, see the spec. If you
> want to rollback the message, use messageDriventContext.setRollbackOnly();

I tried this, but then I get the following Exception:

java.lang.IllegalStateException: setRollbackOnly must only be called in
the context of a transaction (EJB 2.0 - 15.5.1)
at org.jboss.ejb.MessageDrivenEnterpriseContext$MessageDrivenContextImpl
.setRollbackOnly(MessageDrivenEnterpriseContext.java:214)
at de.fag.grobi.logic.NotificationManagerBean.onMessage(NotificationMana
gerBean.java:190)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.ejb.MessageDrivenContainer$ContainerInterceptor.invoke(Mess
...

..

I am using XDoclet but it ignores any @ejb.transaction tag
on the onMessage method of the MDB. Where can I set the transaction
correctly (probably a xdoclet question)?

>
> For the mix between JMS and CMP, I have no idea
When I get the ctx.setRollbackOnly to work, I hope to
resolve this problem by setting the transaction type
correctly.

Regards,

Stefan


---
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] MDB JMS redelivery

2004-01-09 Thread stscit04
Hi,

I have a MDB which takes messages from a Queue.
In the onMessage() method, I am working with
CMP beans. If something goes wrong, I want the JMS
message to be redelivered, but the changes on the CMP
beans should not be rolled back.

As I understand it, the only way to force re-delivery of the JMS message
is to throw an EJBException to force JBoss to rollback
the transaction. But this also rolles back the changes on the
CMP beans...

Is there an obvious solution I am not seeing ?

Thanks in advance,

Stefan


---
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Tell Jboss to create INNODB tables (was: Session/Entity Bean Transaction Rollback)

2003-12-23 Thread stscit04
Adrian,

thanks for the link, this was exactly what I needed.
Sometimes you dont need many words to explain something :-)

One more question: Where can I tell Jboss to
create tables with TYPE=INNODB ?

btw: I bought the JBoss dokumentation, but this
mailing list is far more helpfull for Jboss users.
Here comes a big "thank you" to all people here helping out
others !

Regards,

Stefan

>> http://www.mysql.com/doc/en/InnoDB.html
>>
>> Regards,
>> Adrian
>>
>> On Mon, 2003-12-22 at 15:22, [EMAIL PROTECTED] wrote:
>> > Hi,
>> >
>> > I forgot something,
>> > I am not shure if this is important: Im am using mySQL
>> > as RDBMS. The Datasource is configured as follows:
>> >
>> >
>> > 
>> >  
>> > mySQL_partnerMgmt
>> > jdbc:mysql://localhost/partnerMgmt
>> > org.gjt.mm.mysql.Driver
>> > root
>> > 
>> >   
>> > 
>> >
>> >
>> > > Hi,
>> > >
>> > > I have a sessionbean (stateless), that provides a
>> > > method to create some entitys. If the creation of one
>> > > Entity fails, I want do rollback all creations, there
>> > > should be one or all entitys in the DB. I tried to
>> > > set transaction type="required" on the method and I
>> > > throw EJB Exceptions if something goes wrong, but after
>> > > the method fails, there are still some entitys left.
>> > >
>> > > Is there a way to tell JBoss to delete all entitys
>> > > created in the method if the creation of one fails ?
>> > >
>> > > The method looks like this (not actual code :-)
>> > >
>> > > createXXX(){
>> > >  entityHome.create(1);
>> > >  entityHome.create(2);
>> > >  entityHome.create(3);
>> > >  return;
>> > > }
>> > >
>> > > If create(3) failes, I dont want to have 1 and 2 in my database.
>> > >
>> > > Thanks a lot in advance,
>> > >
>> > > Stefan
>> > >
>> > >
>> > > ---
>> > > This SF.net email is sponsored by: IBM Linux Tutorials.
>> > > Become an expert in LINUX or just sharpen your skills.  Sign up for
>> IBM's
>> > > Free Linux Tutorials.  Learn everything from the bash shell to sys
>> admin.
>> > > Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
>> > > ___
>> > > JBoss-user mailing list
>> > > [EMAIL PROTECTED]
>> > > https://lists.sourceforge.net/lists/listinfo/jboss-user
>> > >
>> >
>> >
>> >
>> > ---
>> > This SF.net email is sponsored by: IBM Linux Tutorials.
>> > Become an expert in LINUX or just sharpen your skills.  Sign up for
>> IBM's
>> > Free Linux Tutorials.  Learn everything from the bash shell to sys
>> admin.
>> > Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
>> > ___
>> > JBoss-user mailing list
>> > [EMAIL PROTECTED]
>> > https://lists.sourceforge.net/lists/listinfo/jboss-user
> --
> 
> Adrian Brock
> Director of Support
> Back Office
> JBoss Group, LLC
> 
>
>
>
> ---
> This SF.net email is sponsored by: IBM Linux Tutorials.
> Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
> Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
> Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Session/Entity Bean Transaction Rollback

2003-12-22 Thread stscit04
Thank you very much, but this didnt solve my problem.
I am looking arround at the net, and it seems like a lot of peoploe
have the same problem - no answers

I guess it has to do somthing with my mySQL db. Does
anybody know how to configure a mysql as XA Datasource in JBoss ?

Thanks again, any help appreciated

Stefan

> At 14:42 22.12.2003, [EMAIL PROTECTED] wrote:
>>Hi,
>>
>>I have a sessionbean (stateless), that provides a
>>method to create some entitys. If the creation of one
>>Entity fails, I want do rollback all creations, there
>>should be one or all entitys in the DB. I tried to
>>set transaction type="required" on the method and I
>>throw EJB Exceptions if something goes wrong, but after
>>the method fails, there are still some entitys left.
>>
>>Is there a way to tell JBoss to delete all entitys
>>created in the method if the creation of one fails ?
>>
>>The method looks like this (not actual code :-)
>>
>>createXXX(){
>
> try this:
>
> try {
>
>>  entityHome.create(1);
>>  entityHome.create(2);
>>  entityHome.create(3);
>>  return;
>
> catch (CreateException ce) {
>logger.fatal("createXXX() failed", ce);
>sessionContext.setRollbackOnly();
>throw ce;
> }
>
> Rafal
>
>>}
>>
>>If create(3) failes, I dont want to have 1 and 2 in my database.
>>
>>Thanks a lot in advance,
>>
>>Stefan
>>
>>
>>---
>>This SF.net email is sponsored by: IBM Linux Tutorials.
>>Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
>>Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
>>Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
>>___
>>JBoss-user mailing list
>>[EMAIL PROTECTED]
>>https://lists.sourceforge.net/lists/listinfo/jboss-user
>
>
>
> ---
> This SF.net email is sponsored by: IBM Linux Tutorials.
> Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
> Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
> Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Session/Entity Bean Transaction Rollback

2003-12-22 Thread stscit04
Hi,

I forgot something,
I am not shure if this is important: Im am using mySQL
as RDBMS. The Datasource is configured as follows:



 
mySQL_partnerMgmt
jdbc:mysql://localhost/partnerMgmt
org.gjt.mm.mysql.Driver
root

  



> Hi,
>
> I have a sessionbean (stateless), that provides a
> method to create some entitys. If the creation of one
> Entity fails, I want do rollback all creations, there
> should be one or all entitys in the DB. I tried to
> set transaction type="required" on the method and I
> throw EJB Exceptions if something goes wrong, but after
> the method fails, there are still some entitys left.
>
> Is there a way to tell JBoss to delete all entitys
> created in the method if the creation of one fails ?
>
> The method looks like this (not actual code :-)
>
> createXXX(){
>  entityHome.create(1);
>  entityHome.create(2);
>  entityHome.create(3);
>  return;
> }
>
> If create(3) failes, I dont want to have 1 and 2 in my database.
>
> Thanks a lot in advance,
>
> Stefan
>
>
> ---
> This SF.net email is sponsored by: IBM Linux Tutorials.
> Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
> Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
> Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Session/Entity Bean Transaction Rollback

2003-12-22 Thread stscit04
Hi,

I have a sessionbean (stateless), that provides a
method to create some entitys. If the creation of one
Entity fails, I want do rollback all creations, there
should be one or all entitys in the DB. I tried to
set transaction type="required" on the method and I
throw EJB Exceptions if something goes wrong, but after
the method fails, there are still some entitys left.

Is there a way to tell JBoss to delete all entitys
created in the method if the creation of one fails ?

The method looks like this (not actual code :-)

createXXX(){
 entityHome.create(1);
 entityHome.create(2);
 entityHome.create(3);
 return;
}

If create(3) failes, I dont want to have 1 and 2 in my database.

Thanks a lot in advance,

Stefan


---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] automatic primary key generation for CMP entityBeans?

2003-12-12 Thread stscit04
>> I have seen the UUIDKeyGeneratorFactory, where can I find information
>> about how to write my own factory ?
>
> You need to implement two interfaces:
> org.jboss.ejb.plugins.keygenerator.KeyGeneratorFactory and
> org.jboss.ejb.plugins.keygenerator.KeyGenerator.
> Check the org.jboss.ejb.plugins.keygenerator.uuid for an example.
> This is in the server module. Count on my guidance. We are interested in
> contributions.

The generator I have in mind will increment the values.
In the interfaces, I cant see some init(startValue) method or something
similar. This method should be there and should be called on initializing
the generator.

The UUIDGeneratorFactory returns a new instance of
the generator every time. This is no problem with random keys,
but for incrementing, I have to synchronize the multiple instances
of the keygenerator in some way.

Does somebody have any comments on that or can point me in the
right direction ? Thanks in advance

Stefan


---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] automatic primary key generation for CMP entityBeans?

2003-12-12 Thread stscit04

>> I have seen the UUIDKeyGeneratorFactory, where can I find information
>> about how to write my own factory ?
>
> You need to implement two interfaces:
> org.jboss.ejb.plugins.keygenerator.KeyGeneratorFactory and
> org.jboss.ejb.plugins.keygenerator.KeyGenerator.
> Check the org.jboss.ejb.plugins.keygenerator.uuid for an example.
> This is in the server module. Count on my guidance. We are interested in
> contributions.

Thank you very much! I will take alook at this, I have to check
with my boss, maybe we can contribute the generator.

>> I also need to know how to
>> use entity-commands/how to use the default keygenerator.
>
> A field that should use a generator is marked with  in
> jbosscmp-jdbc.xml. And the entity that has an auto-incremented field
> should have an entity-command element that says what generation is used
> for that field. For example, the command that uses a key-generator is
>
> 
>  name="key-generator"
> class="org.jboss.ejb.plugins.cmp.jdbc.keygen.JDBCKeyGeneratorCreateCommand">
> name="key-generator-factory">UUIDKeyGeneratorFactory
> 
>
> The UUIDKeyGeneratorFactory is the JNDI name under which the key
> generator factory is bound.
>
> The UUID key generator is an MBean that is bound into the JNDI on the
> start. It produces String values.
>



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] automatic primary key generation for CMP entityBeans?

2003-12-12 Thread stscit04
I have seen the UUIDKeyGeneratorFactory, where can I find information
about how to write my own factory ? I also need to know how to
use entity-commands/how to use the default keygenerator.

Thanks in advance,

Stefan

> select max() is not safe. Look at standardjbosscmp-jdbc.xml file for
> entity-commands for avaliable key generations.
>
> [EMAIL PROTECTED] wrote:
>
>> Hello, everyone
>>
>> I have a Entity Bean with a String as PK.
>> The String consists of the characters [0-9]and[A-Z].
>>
>> My approach is to get the latest key from the DB
>> with an ejbSelect method(select MAX()). Is this
>> safe, or is it possible that I assign accidentially the same PK
>> to 2 entitys because the PK of the first one doenst show up
>> in the DB while generating the second key ?
>>
>> Does JBoss have any sort of PK generator which I can
>> configure ? Or can I use the auto-increment function of the
>> Database (I want Jboss to create the tables).
>>
>> Thanks for any suggestion,
>>
>> Stefan
>>
>>
>> ---
>> This SF.net email is sponsored by: IBM Linux Tutorials.
>> Become an expert in LINUX or just sharpen your skills.  Sign up for
>> IBM's
>> Free Linux Tutorials.  Learn everything from the bash shell to sys
>> admin.
>> Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
>> ___
>> JBoss-user mailing list
>> [EMAIL PROTECTED]
>> https://lists.sourceforge.net/lists/listinfo/jboss-user
>>
>>
>
>
>
> ---
> This SF.net email is sponsored by: IBM Linux Tutorials.
> Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
> Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
> Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] automatic primary key generation for CMP entityBeans ?

2003-12-11 Thread stscit04
Hello, everyone

I have a Entity Bean with a String as PK.
The String consists of the characters [0-9]and[A-Z].

My approach is to get the latest key from the DB
with an ejbSelect method(select MAX()). Is this
safe, or is it possible that I assign accidentially the same PK
to 2 entitys because the PK of the first one doenst show up
in the DB while generating the second key ?

Does JBoss have any sort of PK generator which I can
configure ? Or can I use the auto-increment function of the
Database (I want Jboss to create the tables).

Thanks for any suggestion,

Stefan


---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] performing tasks on application startup

2003-12-08 Thread stscit04
You are right, I just doesn't look elegant to me :-)
I was hoping for another more elegant solution, but
I will probably go for the suggested one.

Thanks,

Stefan

>> Unfourtunately, my app doesn't have
>> an web-component, so I have to find some way to do this with
>
> Why don't you just add a simple web app that only does
> the init()?
>
>   Heiko
>
> P.S.: www.jugs.org
>
>
> ---
> This SF.net email is sponsored by: IBM Linux Tutorials.
> Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
> Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
> Click now! http://ads.osdn.com/?ad_id78&alloc_id371&op¿ick
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Timer MBean cant handle notification dates in the past

2003-12-08 Thread stscit04
Hi,

I am trying to use the Timer MBean to notify
parts of my application. Sun tells me about the expected
behaviour:

 If the timer notification to be inserted has a date that is before the
current date, the method behaves as if the specified date were the
current date. The first notification is delivered immediately and the
subsequent ones are spaced as specified by the period parameter.

source:
http://java.sun.com/j2ee/1.4/docs/api/javax/management/timer/TimerMBean.html

If I call addNotification as follows

mbServer.invoke(timerService.getObjectName(),
"addNotification",
new Object[] {
"grobiChangeNotification",
"I call you once",
null,
new Date(new Date().getTime() - 1) },

new String[] {
"".getClass().getName(),
"".getClass().getName(),
"java.lang.Object",
Date.class.getName()});

I get the following exception:

RuntimeException in MBean operation
'addNotification(java.lang.String,java.lang.String,
java.lang.Object,java.util.Date)


Please tell me I am doing something wrong, because
this feature is very important to me, and I would
hate to work-arround it.

Thanks,

Stefan


---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] performing tasks on application startup

2003-12-08 Thread stscit04
First of all: Thank you !

Unfourtunately, my app doesn't have
an web-component, so I have to find some way to do this with
ejbs. I thought of doing this in the ejbCreate method, but
this method doesn't get call until the first client
connects

> If your app has a web component to it you can use a listener that will
> notify you when the servlet context gets created. For example:
>
> public class MyListener implements ServletContextListener {
> private static Logger log = Logger.getLogger( MyListener .class);
>
> /** Constructs a new SimpleListener. */
> public MyListener() {
> }
>
> public void contextDestroyed(ServletContextEvent sce) {
> log.info("notification that the web app is stopping");
> }
>
> public void contextInitialized(ServletContextEvent sce) {
> log.info("notification that the web app is started");
> }
> }
>
> you could register your objects for notifications in the
> contextInitialized
> method. Don't know if there is a way to do this for ejbs though.
> hope this helps
> Brian
>
>
>
>
>>From: [EMAIL PROTECTED]
>>Reply-To: [EMAIL PROTECTED]
>>To: [EMAIL PROTECTED]
>>Subject: [JBoss-user] performing tasks on application startup
>>Date: Mon, 8 Dec 2003 14:40:14 +0100 (CET)
>>
>>Hi,
>>
>>Is there a elegant way to perform tasks
>>in an application after the application is
>>deployed an started. I think of tasks
>>such as registering objects for timer
>>notifications
>>
>>Thanks in advance
>>
>>Stefan
>>
>>
>>---
>>This SF.net email is sponsored by: IBM Linux Tutorials.
>>Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
>>Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
>>Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
>>___
>>JBoss-user mailing list
>>[EMAIL PROTECTED]
>>https://lists.sourceforge.net/lists/listinfo/jboss-user
>
> _
> Add photos to your e-mail with MSN 8. Get 2 months FREE*.
> http://join.msn.com/?page=features/featuredemail
>
>
>
> ---
> This SF.net email is sponsored by: IBM Linux Tutorials.
> Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
> Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
> Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] performing tasks on application startup

2003-12-08 Thread stscit04
Hi,

Is there a elegant way to perform tasks
in an application after the application is
deployed an started. I think of tasks
such as registering objects for timer
notifications

Thanks in advance

Stefan


---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] JMS scheduled redelivery

2003-12-04 Thread stscit04
Hi,

I am using Jboss 3.2.2 and a MDB as
JMS destination. The MDB should take a message
from the queue, process it and sometimes (if
processing fails) put it back into the queue.

Is it possible to tell JMS that I want to
receive the message from the queue again
after a period of time?

Otherwise I would have to wait in the
MDB for the specified time before re-processing
the message which doesn' seem to be good design.

Thanks in advance

Stefan


---
This SF.net email is sponsored by OSDN's Audience Survey.
Help shape OSDN's sites and tell us what you think. Take this
five minute survey and you could win a $250 Gift Certificate.
http://www.wrgsurveys.com/2003/osdntech03.php?site=8
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user