Re: [JBoss-user] Commit Option A and ejbCreate [auf Viren geprüft]

2004-01-22 Thread Jonathan . O'Connor
Neal,
What are the transaction types for the ejbCreate(), the 
ejb.setRelatedItem(item) and the calling method? You must be creating 
multiple transactions, and with commit-option A, its caching the value. 
Still doesn't make sense though. Also, why can't you move setting the CMRs 
into ejbPostCreate?
Ciao,
Jonathan O'Connor
XCOM Dublin



Neal Sanche [EMAIL PROTECTED] 
Sent by: [EMAIL PROTECTED]
21.01.2004 22:55
Please respond to
[EMAIL PROTECTED]


To
jboss-user [EMAIL PROTECTED]
cc

Subject
[JBoss-user] Commit Option A and ejbCreate [auf Viren geprüft]






Hi All,

I have recently been experimenting with Commit Option A and have 
noticed on rare occasions that creation of an EJB and subsequent 
setting of some of its CMRs will fail with an EJB spec violation in 
JBoss 3.2.4RC1. The exception mentions that the CMR should only be 
set in the ejbPostCreate. However, I am not actually setting any CMRs 
in the ejbCreate, I am doing so in subsequent lines of the code. For 
example:

  MYEJBLocal ejb = myhome.create();
  ejb.setRelatedItem(item);

The exception will occur on the call to setRelatedItem() which is a 
CMR method, which is in this case a one to one relation. I am also 
using the unknown-pk functionality with mysql to have 
auto-incrementing primary keys, if that makes a difference.

So far, this doesn't ever happen when the commit option is B, which is 
the default in the Entity container.

Any ideas?

-Neal



---
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Commit-option A: When is it safe to use?

2004-01-15 Thread Jonathan . O'Connor
Hi,
I've been playing around with the commit options, and I just want to 
confirm my understanding.
The scenario is: I am running a JBoss app with an Entity Bean, Widget, 
marked as Commit Option A (caching in server, assumes no one updates it).
I have another process, outside of JBoss server, that goes direct to the 
database.
1. Is CommitOption A ok, if the other process does INSERTs on the WIDGET 
table. I'm betting yes, because finders always go to the DB to get the 
primary keys, and then the cache kicks in to prevent reloading.
2. The other process can't do updates or deletes on the WIDGET table, 
because the server won't know about them.

Have I missed any other aggressive optimisations?
Ciao,
Jonathan O'Connor
XCOM Dublin


---
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Disallowing Local interface access from servlet tier [auf Viren geprüft]

2004-01-13 Thread Jonathan . O'Connor
Craig,
You should take a look at Marc Fleury's paper Why I love EJBs (should be 
easy to find on jboss.org). Between the egocentric pub stories (they are 
interesting too), there is a recommendation to keep the web server in the 
same JVM as the EJB server. His thesis is: serialisation is the real 
bottleneck in distributed systems, so avoid it wherever possible. You need 
it between the DB and the server, and between the server and the client, 
but why split the server into front-end and back-end. He also mentions the 
possibility of caching to gain mega performance improvements too.
Ciao,
Jonathan O'Connor
XCOM Dublin



Craig Berry [EMAIL PROTECTED] 
Sent by: [EMAIL PROTECTED]
12.01.2004 19:16
Please respond to
[EMAIL PROTECTED]


To
[EMAIL PROTECTED]
cc

Subject
[JBoss-user] Disallowing Local interface access from servlet tier [auf 
Viren geprüft]






I have noticed that in the default JBoss 3.22 + Tomcat deployment 
configuration, it is possible to obtain Local interfaces for EJBs from the 
Servlet tier.  In the interest of maintaining maximum portability (e.g., 
to enable us to later move to separate boxes for the two tiers), I would 
like to disallow Local access from the servlet tier.  Obviously, our 
design avoids using it, but I'm concerned that leakage might occur 
without our noticing it (e.g., an EJB returns an object to the servlet 
tier which, when accessed, does a Local lookup back to another EJB 
component).
 
Is there any way to make Local lookups from the servlet to the EJB 
container impossible at the configuration level?  Or would I have to run 
the two in separate JVMs to accomplish this?
 
-- 
Craig Berry
Principal Architect and Technical Manager
PortBlue
(310) 566-7546
 



---
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] Defining Load groups with xdoclet [auf Viren geprüft]

2004-01-13 Thread Jonathan . O'Connor

Alex,
That works wonderfully! Thanks. However,
this is not documented on the XDoclet site with their new 1.2 documentation.
Its also not documented in the JBoss doc set. And there has been almost
no mention of load-groups in this mailing list either. So, is there a definitive
list of @jboss tags anywhere? I guess I can look in the xdt file, but I'd
prefer not to.
Ciao,
Jonathan O'Connor
XCOM Dublin





Alexey Loubyansky
[EMAIL PROTECTED] 
Sent by: [EMAIL PROTECTED]
12.01.2004 22:18



Please respond to
[EMAIL PROTECTED]





To
[EMAIL PROTECTED]


cc



Subject
RE: [JBoss-user] Defining
Load groups with xdoclet [auf Viren geprüft]








There is
 * @jboss.load-group name=basic 

On the class level it declares the load group. On the field level you
actually specify which fields comprise the group.

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf Of 
 Jonathan.O'[EMAIL PROTECTED]
 Sent: Monday, January 12, 2004 7:41 PM
 To: [EMAIL PROTECTED]
 Subject: [JBoss-user] Defining Load groups with xdoclet
 
 Just wondering if there is any tag to setup load groups using XDoclet.
 From my own search, I think the answer is no. So, how do I 
 set up a merge point to do this.
 I have added a mergeDir=myMergeDir in the ejbDoclet ant
task.
 I have also added a file jbosscmp-jdbc-Settlement.xml into 
 the mergeDir. 
 This file just contains:
 load-groups
 load-group
 load-group-namesortKeys/load-group-name
 field-namemerchantName/field-name
 field-nameamount/field-name
 field-nametxnDateDbFormat/field-name
 /load-group
 /load-groups
 
 However, I don't see any load-groups in my Settlement entity 
 within the generated jbosscmp-jdbc.xml.
 
 Any help is greatly appreciated.
 Ciao,
 Jonathan O'Connor
 XCOM Dublin
 
 
 ---
 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] Getting load groups to work?

2004-01-13 Thread Jonathan . O'Connor
Alex (Oracle of the CMP engine!),
I'm trying to get these load groups working in JBoss 3.2.2. I've 
successfully set up two load groups on a CMP entity bean, sortKeys and 
most. sortKeys has 3 fields, and most has most, but not all, of the 
other CMP fields. I have set read-ahead on my query (@jboss.declared-sql 
page-size=40 eager-load-group=sortKeys strategy=on-find. This 
correctly does a SELECT PK, SORT_KEY1, SORT_KEY2, SORT_KEY3 FROM T.
I then do the following:
Object[] sortingArray = collection.toArray();
Arrays.sort(sortingArray, comparator);

However, now, I see that during the sort() call, JBoss goes and fetches 
all the columns for each object that was found.
Why should it want to load all these objects?

Ciao,
Jonathan O'Connor
XCOM Dublin


---
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] Getting load groups to work? Solved

2004-01-13 Thread Jonathan . O'Connor
Forget this problem. I am nearly certain that it was caused by crossing 
transaction boundaries. That is: the finder executed in one transaction, 
and the sort occurred in another transaction. When I moved the sort into 
the session bean doing the finding, it worked much better.
Ciao,
Jonathan O'Connor
XCOM Dublin



Jonathan.O'[EMAIL PROTECTED] 
Sent by: [EMAIL PROTECTED]
13.01.2004 14:25
Please respond to
[EMAIL PROTECTED]


To
[EMAIL PROTECTED]
cc

Subject
[JBoss-user] Getting load groups to work? [auf Viren geprüft]






Alex (Oracle of the CMP engine!),
I'm trying to get these load groups working in JBoss 3.2.2. I've 
successfully set up two load groups on a CMP entity bean, sortKeys and 
most. sortKeys has 3 fields, and most has most, but not all, of the 
other CMP fields. I have set read-ahead on my query (@jboss.declared-sql 
page-size=40 eager-load-group=sortKeys strategy=on-find. This 
correctly does a SELECT PK, SORT_KEY1, SORT_KEY2, SORT_KEY3 FROM T.
I then do the following:
Object[] sortingArray = collection.toArray();
Arrays.sort(sortingArray, comparator);

However, now, I see that during the sort() call, JBoss goes and fetches 
all the columns for each object that was found.
Why should it want to load all these objects?

Ciao,
Jonathan O'Connor
XCOM Dublin


---
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] Defining Load groups with xdoclet

2004-01-12 Thread Jonathan . O'Connor
Just wondering if there is any tag to setup load groups using XDoclet.
From my own search, I think the answer is no. So, how do I set up a merge 
point to do this.
I have added a mergeDir=myMergeDir in the ejbDoclet ant task.
I have also added a file jbosscmp-jdbc-Settlement.xml into the mergeDir. 
This file just contains:
load-groups
load-group
load-group-namesortKeys/load-group-name
field-namemerchantName/field-name
field-nameamount/field-name
field-nametxnDateDbFormat/field-name
/load-group
/load-groups

However, I don't see any load-groups in my Settlement entity within the 
generated jbosscmp-jdbc.xml.

Any help is greatly appreciated.
Ciao,
Jonathan O'Connor
XCOM Dublin


---
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] JBoss 3.2.3 + Jetty fails startup in run -c all

2004-01-09 Thread Jonathan . O'Connor
 to move war to: 
H:\server\all\tmp\deploy\tmp6335web-console.war.tmp
; - nested throwable: (org.jboss.deployment.DeploymentException: Was 
unable to move war to: H:\server\all\tmp\deploy\tmp
6335web-console.war.tmp)
at 
org.jboss.web.AbstractWebContainer.init(AbstractWebContainer.java:350)
at org.jboss.deployment.MainDeployer.init(MainDeployer.java:696)

Ciao,
Jonathan O'Connor
XCOM Dublin


---
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] Where to put an Interceptor class?

2004-01-07 Thread Jonathan . O'Connor
Hi,
We're just about to write our first interceptor (to retry deadlocked 
methods), and we can't find the docs where to have the class loaded.
The best would be to have it in a jar in our EAR. Is that possible? Also, 
can we keep delare our own interceptor stack for our beans in this EAR 
too?
Thanks,
Jonathan O'Connor
XCOM Dublin


---
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] Where to put an Interceptor class?

2004-01-07 Thread Jonathan . O'Connor
Wow,
Answers from Bill and Adrian in less than 15 minutes!! I guess Interceptor 
is the magic word :-)
I'll look at the current behaviour of TxInterceptorCMT, but I suspect we 
want to control this ourselves. I'll let you guys know any good ideas I 
get (if any).

Lastly, Giovanni, I'm using JBoss 3.2.2 and not the 4.0 AOP stuff. Thanks 
anyway.
Ciao,
Jonathan O'Connor
XCOM Dublin



Adrian Brock [EMAIL PROTECTED] 
Sent by: [EMAIL PROTECTED]
07.01.2004 16:27
Please respond to
[EMAIL PROTECTED]


To
[EMAIL PROTECTED]
cc

Subject
Re: [JBoss-user] Where to put an Interceptor class?






On Wed, 2004-01-07 at 16:18, Jonathan.O'[EMAIL PROTECTED] wrote:
 Hi,
 We're just about to write our first interceptor (to retry deadlocked 
 methods), and we can't find the docs where to have the class loaded.
 The best would be to have it in a jar in our EAR. Is that possible? 
Also, 
 can we keep delare our own interceptor stack for our beans in this EAR 
 too?

Yes you can put the interceptor in your ear and yes
you can configure your own interceptor stack, 
either on the server or the client.
You provide your own configurations in jboss.xml

It only makes sense to retry a deadlock after you have allowed
the transaction to rollback, i.e. outside the transaction 
demarcation boundary.
You will already find this behaviour already in
org.jboss.ejb.plugins.TxInterceptorCMT

Regards,
Adrian

 Thanks,
 Jonathan O'Connor
 XCOM Dublin
 
 
 ---
 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] a jar with castor.properties file breaks JBoss 3.2.2

2003-12-17 Thread Jonathan . O'Connor
(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 
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.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:546)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy5.deploy(Unknown Source)
at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:384)
at org.jboss.system.server.ServerImpl.start(ServerImpl.java:291)
at org.jboss.Main.boot(Main.java:150)
at org.jboss.Main$1.run(Main.java:395)
at java.lang.Thread.run(Thread.java:534)
Ciao,
Jonathan O'Connor
XCOM Dublin


---
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=1278alloc_id=3371op=click
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] a jar with castor.properties file breaks JBoss 3.2.2

2003-12-17 Thread Jonathan . O'Connor
Some further information.
Create a jar file with only one file in it, castor.properties. The 
contents of castor.properties should be:
org.exolab.castor.parser=org.apache.xerces.parsers.SAXParser
org.exolab.castor.xml.naming=mixed
org.exolab.castor.serializer=org.apache.xml.serialize.XMLSerializer
org.exolab.castor.indent=true
org.exolab.castor.validation=true
org.exolab.castor.features=
org.exolab.castor.debug=true
org.exolab.castor.mapping.collections=\
  org.exolab.castor.mapping.loader.J1CollectionHandlers,\
  org.exolab.castor.mapping.loader.J2CollectionHandlers
org.exolab.castor.jdo.engines=\
  org.exolab.castor.jdo.drivers.OracleFactory,\
  org.exolab.castor.jdo.drivers.PostgreSQLFactory,\
  org.exolab.castor.jdo.drivers.SybaseFactory,\
  org.exolab.castor.jdo.drivers.SQLServerFactory,\
  org.exolab.castor.jdo.drivers.DB2Factory,\
  org.exolab.castor.jdo.drivers.GenericFactory
org.exolab.castor.jdo.keyGeneratorFactories=\
  org.exolab.castor.jdo.drivers.MaxKeyGeneratorFactory,\
  org.exolab.castor.jdo.drivers.HighLowKeyGeneratorFactory,\
  org.exolab.castor.jdo.drivers.IdentityKeyGeneratorFactory,\
  org.exolab.castor.jdo.drivers.SequenceKeyGeneratorFactory
org.exolab.castor.builder.type.j2=\
  org.exolab.castor.builder.FieldInfoFactoryJ2
org.exolab.castor.builder.type.j1=\
  org.exolab.castor.builder.FieldInfoFactory
org.exolab.castor.builder.type.odmg=\
  org.exolab.castor.builder.FieldInfoFactoryODMG30

Then this fails with the same exception as below.
Ciao,
Jonathan O'Connor
XCOM Dublin



Jonathan.O'[EMAIL PROTECTED] 
Sent by: [EMAIL PROTECTED]
17.12.2003 17:54
Please respond to
[EMAIL PROTECTED]


To
[EMAIL PROTECTED]
cc

Subject
[JBoss-user] a jar with castor.properties file breaks JBoss 3.2.2






I have a jar with a castor.properties file in it. If I copy this to the 
/server/default/lib and start JBoss, I get the following stack trace:
From reading this news group, I've seen that castor is no longer used in 
JBoss. This is not quite right. the build.xml and a JDOImpl file in varia 
make references to it. However, I think that is a red herring.
The work around is to remove castor.properties file from my jar, but then 
my own software breaks. Any ideas what's going on? Classloader problems??

17:36:46,550 ERROR [SnmpAgentService] Starting failed
java.lang.NullPointerException
at gnu.regexp.RE.initialize(RE.java)
at gnu.regexp.RE.init(RE.java)
at gnu.regexp.RE.init(RE.java)
at 
org.jboss.jmx.adaptor.snmp.agent.TrapFactorySupport.start(TrapFactorySupport.java:194)
at 
org.jboss.jmx.adaptor.snmp.agent.TrapEmitter.start(TrapEmitter.java:119)
at 
org.jboss.jmx.adaptor.snmp.agent.SnmpAgentService.startService(SnmpAgentService.java:254)
at 
org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:192)
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.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:546)
at 
org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.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 sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at 
org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.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.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.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:546

Re: [JBoss-user] Oracle error

2003-12-03 Thread Jonathan . O'Connor
Guys,
This looks exactly like a problem we had with Sybase recently. In Sybase 
you cant have more than 250 sub-expressions in a where clause.
JBoss produces SQL like select field1, field2, field3 from TABLE where 
(key = 1 or key = 2 or key =3 or ...) when it is loading a load of 
objects.
The solution is to alter the standardjbosscmp-jdbc.xml file to use a page 
size of 250 records at a time:
  read-ahead
  strategyon-load/strategy
  page-size250/page-size
  eager-load-group*/eager-load-group
  /read-ahead

HTH,
Jonathan O'Connor
XCOM Dublin



Alexey Loubyansky [EMAIL PROTECTED] 
Sent by: [EMAIL PROTECTED]
03.12.2003 11:33
Please respond to
[EMAIL PROTECTED]


To
[EMAIL PROTECTED]
cc

Subject
Re: [JBoss-user] Oracle error






AFAICT, it is either a driver problem or there is a bind variable in the 
statement which is a reserved word.
Could you try with another driver?

[EMAIL PROTECTED] wrote:

 Hi all,
I have a CMP entity bean that access to oracle 9i 
database. When I
 do the lookup it has no problem, but when I try to get some attribute 
(eg
 getName()) it gives the following error:
 
 org.jboss.tm.JBossTransactionRolledbackException: Load failed;
 CausedByException is:
 ORA-01745: invalid host/bind variable name
 ; CausedByException is:
 Load failed; CausedByException is:
 ORA-01745: invalid host/bind variable name
 ; nested exception is: 
 javax.ejb.EJBException: Load failed; CausedByException is:
 ORA-01745: invalid host/bind variable name
 ; - nested throwable: (javax.ejb.EJBException: Load failed;
 CausedByException is:
 ORA-01745: invalid host/bind variable name
 )
 
 I have found a solution to this error an it is to have less than 255
 records in the table. When the returned collection has more than 255 CMP
 object it breaks.
 
 Does anyone know where should I change this configuration or what is 
wrong? 
 I have looked in the conf dir but I did not found where...
 
 Regards,
 Hernán.
 
 
 ---
 This SF.net email is sponsored by: SF.net Giveback Program.
 Does SourceForge.net help you be more productive?  Does it
 help you create better code?  SHARE THE LOVE, and help us help
 YOU!  Click Here: http://sourceforge.net/donate/
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user
 
 



---
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




---
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


[JBoss-user] JBoss 3.2.2 Deployment Bug: web-service.xml in EJB module prevents deployment

2003-11-21 Thread Jonathan . O'Connor
Folks,
I finally figured out my problem. My EAR structure was the following:
EAR
backend.jar
METAINF
ejb-jar.xml
jboss.xml
jboscmp-jdbc.xml
web-service.xml  THIS PREVENTS ALL SESSION AND 
ENTITY BEANS FROM DEPLOYING!!!
tips-with-soap.wsr
tips.sar
tips.war
METAINF

The presence of web-service.xml in backend.jar/METAINF prevented the 
backend.jar deploying. Then when tips.war was deployed, it ran the 
listener to initialise the WAR. Of course, this tried to use some of the 
session beans that should have been deployed in backend.jar. As these 
didn't exist, it blew up. And of course, it looked as if the order of 
deployment was reversed, but in fact the ordering was correct.

The solution was simple: Just remove the web-service.xml from the ejb 
module. But guys, can you generate an error message when this happens?
Thanks,
Jonathan O'Connor
XCOM Dublin




Jonathan.O'[EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
23.10.2003 11:14
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Specifying deployment order in 
EAR - JBoss 3.2.2


Scott,
As Sherlock Holmes said (?), when all the probable causes have been 
eliminated, then we must look at the improbable causes!
The problem is the listener in the WAR is failing because the session 
beans do not exist.
And as the ejb jar was deployed first, then its deployment must have 
failed. I'll look into that and get back to you if I find anything.
Thanks,
Jonathan O'Connor
XCOM Dublin




Scott M Stark [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
20.10.2003 17:06
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Specifying deployment order in 
EAR - JBoss 3.2.2


ejb jars are deployed before wars so show the startup ordering. A test.ear
with ejbs and a war shows the ejbs started before the war:

09:14:48,246 INFO  [MainDeployer] Starting deployment of package: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/
09:14:48,247 INFO  [EARDeployer] Init J2EE application: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/
09:14:49,956 INFO  [EjbModule] Deploying BMPBean
09:14:50,216 INFO  [EjbModule] Deploying BMPCallbackBean
09:14:50,232 INFO  [EjbModule] Deploying CMPBean
09:14:50,272 INFO  [EjbModule] Deploying CMPBean2
...
09:14:53,536 INFO  [EJBDeployer] Deployed: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/cts.jar
09:14:53,794 INFO  [EmbeddedTomcatService] deploy, ctxPath=/traxbahn, 
warUrl=file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/traxbahn.war/
09:14:54,312 INFO  [Engine] ContextConfig[/traxbahn]: Added certificates 
- 
request attribute Valve
...
09:14:54,347 INFO  [Engine] StandardWrapper[/traxbahn:invoker]: Loading 
container servlet invoker
09:14:54,758 INFO  [EARDeployer] Started J2EE application: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/
09:14:54,758 INFO  [MainDeployer] Deployed package: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/

-- 

Scott Stark
Chief Technology Officer
JBoss Group, LLC


Jonathan.O'[EMAIL PROTECTED] wrote:

 Hi, I'm trying to migrate our code from JBoss 3.0.6 to 3.2.2 and I've 
got 
 a problem due to deployment order.
 My ear file has a backend.jar containing entity beans and session beans, 

a 
 frontend.war. In 3.0.6, the backend.jar was always deployed first before 


 the WAR. This meant that a listener in the WAR ran happily accessing 
 session beans in the backend.
 
 But in 3.2.2 (and in RC4 too) I get an exception trying to run the 
 listener code in contextInitialized(). It seems that the session beans 
in 
 the backend.jar have not been loaded yet. Is there a way of setting a 
 dependency on the order of loading in 3.2.2? jboss-service.xml has a 
 depends clause, but that won't work for ejb or web stuff.
 
 Any help would be greatly appreciated
 Ciao,
 Jonathan O'Connor
 XCOM Dublin



---
This SF.net email is sponsored by OSDN developer relations
Here's your chance to show off your extensive product knowledge
We want to know what you know. Tell us and you have a chance to win $100
http://www.zoomerang.com/survey.zgi?HRPT1X3RYQNC5V4MLNSV3E54
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
This SF.net email is sponsored by OSDN developer relations
Here's your chance to show off your extensive product knowledge
We want to know what you know. Tell us and you have a chance to win $100
http://www.zoomerang.com/survey.zgi?HRPT1X3RYQNC5V4MLNSV3E54
___
JBoss-user mailing list
[EMAIL PROTECTED]
https

[JBoss-user] Axis/JBoss-net problem: Deserializing a POJO

2003-11-19 Thread Jonathan . O'Connor
As there were no answers for my previous query, I thought I better get a 
bit more specific.

In a session bean, I have a method:
/**
* @ejb.interface-method view-type=remote
* @jboss-net.web-method
*/
public BsAddressBean getDeliveryAddress( String id);

BsAddressBean is marked as a serializable class for JBoss-net:
/**
 * @jboss-net.xml-schema urn = tips:BsAddressBean
 */
public class BsAddressBean implements Serializable {
// getters and setters for name and country
}

The session bean is returning the following data:
?xml version=1.0 encoding=UTF-8?
 SOAP-ENV:Envelope 
xmlns:SOAP-ENV=http://schemas.xmlsoap.org/soap/envelope/; 
xmlns:xsd=http://www.w3.org/2001/XMLSchema; 
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
  SOAP-ENV:Body
 
   getDeliveryAddressResponse 
SOAP-ENV:encodingStyle=http://schemas.xmlsoap.org/soap/encoding/;
   getDeliveryAddressResult href=#id0/
   /getDeliveryAddressResponse
 
   multiRef id=id0 SOAP-ENC:root=0 xsi:type=ns1:BsAddressBean 
xmlns:SOAP-ENC=http://schemas.xmlsoap.org/soap/encoding/; 
xmlns:ns1=http://localhost:8080/tips;
name xsi:type=xsd:stringJonathan Oapos;Connor/name
country xsi:type=xsd:stringIreland/country
   /multiRef
  /SOAP-ENV:Body
 /SOAP-ENV:Envelope

My build script uses the following parameters in the jboss-net command:
jbossnet webDeploymentName=tips
prefix=tips
destdir=${src-gen}/META-INF
targetNameSpace=http://localhost:8080/tips; /

Finally, the server exception is telling me I've no deserializer for 
http://localhost:8080/tips:BsAddressBean
So what's my problem? Have I got the right urn specified in the 
BsAddressBean?

10:30:06,465 ERROR [Call] Exception:
org.xml.sax.SAXException: Deserializing parameter 
'getDeliveryAddressResult':  could not find deserializer for type 
http://localhost:8080/tips:BsAddressBean
at 
org.apache.axis.message.RPCHandler.onStartChild(RPCHandler.java:190)
at 
org.apache.axis.encoding.DeserializationContextImpl.startElement(DeserializationContextImpl.java:821)
at 
org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:197)
at 
org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:578)
at 
org.apache.axis.message.RPCElement.deserialize(RPCElement.java:207)
at 
org.apache.axis.message.RPCElement.getParams(RPCElement.java:231)
at org.apache.axis.client.Call.invoke(Call.java:1605)
at org.apache.axis.client.Call.invoke(Call.java:1513)
at org.apache.axis.client.Call.invoke(Call.java:1093)
at 
xcom.traxbahn.externinterface.banksystem.XcomBankSystem.getDeliveryAddress(XcomBankSystem.java:137)Ciao,

BTW, I'm using JBoss 3.0.8
Thanks,
Jonathan O'Connor
XCOM Dublin



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] How to tell Axis which serializer to use for a POJO class?

2003-11-17 Thread Jonathan . O'Connor
Folks,
JBoss 3.0.8 Axis problem.
I'm sure this is easy to solve, but how do I tell SOAP which serializer to 
use for my POJO class, BsAddressBean? This is labelled in the class 
comments with:
 * @jboss-net.xml-schema urn = XCOM-BS:BsAddressBean

In the client, I am calling setReturnClass:
call.setReturnClass(BsAddressBean.class);

However, I get an exception in my client code:
Caused by: java.io.IOException: No serializer found for class 
de.xcom.tips.xcombs.ejb.BsAddressBean in registry 
[EMAIL PROTECTED]
at 
org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:135)
at 
org.apache.axis.encoding.DeserializationContextImpl.endElement(DeserializationContextImpl.java:865)
at 
org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1675)
at org.apache.crimson.parser.Parser2.content(Parser2.java:1926)
at 
org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1654)
at org.apache.crimson.parser.Parser2.content(Parser2.java:1926)
at 
org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1654)
at 
org.apache.crimson.parser.Parser2.parseInternal(Parser2.java:634)
at org.apache.crimson.parser.Parser2.parse(Parser2.java:333)
at 
org.apache.crimson.parser.XMLReaderImpl.parse(XMLReaderImpl.java:448)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:345)
at 
org.apache.axis.encoding.DeserializationContextImpl.parse(DeserializationContextImpl.java:201)
at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:428)
at org.apache.axis.client.Call.invoke(Call.java:1793)
at org.apache.axis.client.Call.invoke(Call.java:1594)
at org.apache.axis.client.Call.invoke(Call.java:1513)
at org.apache.axis.client.Call.invoke(Call.java:1093)
at 
xcom.traxbahn.externinterface.banksystem.XcomBankSystem.getDeliveryAddress(XcomBankSystem.java:135)
Ciao,
Jonathan O'Connor
XCOM Dublin


---
This SF. Net email is sponsored by: GoToMyPC
GoToMyPC is the fast, easy and secure way to access your computer from
any Web browser or wireless device. Click here to Try it Free!
https://www.gotomypc.com/tr/OSDN/AW/Q4_2003/t/g22lp?Target=mm/g22lp.tmpl
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] JBoss-net does not like calling EJB method with transaction type = never

2003-11-14 Thread Jonathan . O'Connor
I'm working on JBoss 3.0.8.
I am trying to call an EJB Session Bean method via SOAP/Axis. The bean 
method is marked @ejb.transaction-type = never because it calls 3 other 
session beans that handle their own transactions.

According to the stack trace, the Axis RPCProvider.invokeMethod is 
eventually trying to run with Transactions. Should it not obey the 
transaction type info from ejb-jar.xml?
Any help is appreciated.

I get the following stack trace:
javax.ejb.EJBException: Transaction not allowed
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:330)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:98)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
at 
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:208)
at 
org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.java:313)
at org.jboss.ejb.Container.invoke(Container.java:738)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
at 
org.jboss.invocation.local.LocalInvoker.invoke(LocalInvoker.java:99)
at 
org.jboss.invocation.InvokerInterceptor.invoke(InvokerInterceptor.java:102)
at 
org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:77)
at 
org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:80)
at 
org.jboss.proxy.ejb.StatelessSessionInterceptor.invoke(StatelessSessionInterceptor.java:111)
at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:76)
at $Proxy185.issueCard(Unknown Source)
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.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:347)
at 
org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:225)
at 
org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:263)
at 
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:71)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:154)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:121)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:288)
at 
org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:543)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at 
org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:360)
at 
org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:294)
at 
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:558)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1714)
at 
org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:507)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1664)
at org.mortbay.http.HttpServer.service(HttpServer.java:863)
at org.jboss.jetty.Jetty.service(Jetty.java:460)
at 
org.mortbay.http.HttpConnection.service(HttpConnection.java:775)
Ciao,
Jonathan O'Connor
XCOM Dublin


---
This SF.Net email sponsored by: ApacheCon 2003,
16-19 November in Las Vegas. Learn firsthand the latest
developments in Apache, PHP, Perl, XML, Java, MySQL,
WebDAV, and more! http://www.apachecon.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] JBoss-net does not like calling EJB method with transaction type = never

2003-11-14 Thread Jonathan . O'Connor
Danny,
Thanks NotSupported fixed it alright. But I still think that Web 
Services should not wrap everything in a transaction.
I presume that new transactions are created whenever it calls beans marked 
as required. At least my tests all run smoothly.
Ciao,
Jonathan O'Connor
XCOM Dublin




Yates, Danny [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
14.11.2003 14:06
Please respond to jboss-user
 
To: '[EMAIL PROTECTED]' 
[EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] JBoss-net does not like calling 
EJB method with transaction type = never


I would guess that what is happening is:

1) Axis starts a transaction to call your Web Services class
2) Your Web Services class (now in a transaction) tries to call the bean
3) Because the bean is marked never, the call fails

Perhaps you should consider NotSupported which will suspend the Axis
transaction whilst inside your bean. Not sure what happens if you bean
then tries to call other beans which are marked Required.

-- 
Danny Yates


-Original Message-
From: Jonathan.O'[EMAIL PROTECTED] [mailto:Jonathan.O'[EMAIL PROTECTED] 
Sent: 14 November 2003 12:51
To: [EMAIL PROTECTED]
Subject: [JBoss-user] JBoss-net does not like calling EJB method with
transaction type = never


I'm working on JBoss 3.0.8.
I am trying to call an EJB Session Bean method via SOAP/Axis. The bean 
method is marked @ejb.transaction-type = never because it calls 3 other 
session beans that handle their own transactions.

According to the stack trace, the Axis RPCProvider.invokeMethod is 
eventually trying to run with Transactions. Should it not obey the 
transaction type info from ejb-jar.xml?
Any help is appreciated.

I get the following stack trace:
javax.ejb.EJBException: Transaction not allowed
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.
java:330)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:98)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:13
0)
at 
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:208)
at 
org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.jav
a:313)
at org.jboss.ejb.Container.invoke(Container.java:738)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
at 
org.jboss.invocation.local.LocalInvoker.invoke(LocalInvoker.java:99)
at 
org.jboss.invocation.InvokerInterceptor.invoke(InvokerInterceptor.java:102)
at 
org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:77
)
at 
org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:80)
at 
org.jboss.proxy.ejb.StatelessSessionInterceptor.invoke(StatelessSessionInter
ceptor.java:111)
at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:76)
at $Proxy185.issueCard(Unknown Source)
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.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:347
)
at 
org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:2
25)
at 
org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:263)
at 
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:
71)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:154)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:121)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:288)
at 
org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:543)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at 
org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:360)
at 
org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandl
er.java:294)
at 
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:558)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1714)
at 
org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext
.java:507)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1664)
at org.mortbay.http.HttpServer.service(HttpServer.java:863)
at org.jboss.jetty.Jetty.service(Jetty.java:460)
at 
org.mortbay.http.HttpConnection.service(HttpConnection.java:775)
Ciao,
Jonathan O'Connor
XCOM Dublin


---
This SF.Net email sponsored by: ApacheCon 2003,
16-19 November in Las Vegas. Learn firsthand the latest

Re: [JBoss-user] ejb calls interceptor

2003-11-13 Thread Jonathan . O'Connor
Ionel,
Try JBoss 3.2.2
Open the GUI console and have a look at some of your beans. You should 
find all the statistics you want there. By default, statistics collecting 
is turned on, at least I didn't have to do anything special to get these 
numbers.
Ciao,
Jonathan O'Connor
XCOM Dublin




Ionel GARDAIS [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
13.11.2003 09:32
Please respond to jboss-user
 
To: jboss-user [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] ejb calls interceptor


Hi,

Is there a way to catch the calls that are made to an
EJB (fields getters/setters, finders, selectors).

My goal is to provide some statistical informations
(how many times a method have been called, which
methods should be optimized ...) through an MBean
StatService

thanks,

=
-- 
Regards,
Ionel

___
Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français !
Yahoo! Mail : http://fr.mail.yahoo.com


---
This SF.Net email sponsored by: ApacheCon 2003,
16-19 November in Las Vegas. Learn firsthand the latest
developments in Apache, PHP, Perl, XML, Java, MySQL,
WebDAV, and more! http://www.apachecon.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
This SF.Net email sponsored by: ApacheCon 2003,
16-19 November in Las Vegas. Learn firsthand the latest
developments in Apache, PHP, Perl, XML, Java, MySQL,
WebDAV, and more! http://www.apachecon.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Returning single field as Collection with EJB QL

2003-10-31 Thread Jonathan . O'Connor
Ulf,
You need an ejb.select instead. Finders are defined to return the Entity 
Bean interface (local or remote). Select() lets you find non entity bean 
stuff.
to be more specific, in an Entity Bean, FooBean, finders always return 
FooRemote or FooLocal objects. Use ejb.Select to return other stuff such 
as your last names.
Ciao,
Jonathan O'Connor
XCOM Dublin




Ulf Tidstrand [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
31.10.2003 07:47
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Returning single field as Collection 
with EJB QL


Hi everyone,
 
I have declared a simple EJB QL statement in xdoclet:
 
 * @ejb.finder
 *signature=java.util.Collection findAllLastNames()
 *query=SELECT DISTINCT u.lastName FROM user AS u
 
The lastName field is of type String, so I thought that this statement 
would return all uniqe last names in the table as a Collection of String. 
However it seems to return a Collection of local interfaces instead. 
That?s fine, but the problem is that the primary key fields are not set in 
those local interfaces so whenever I try to fetch the ?lastName? field 
with getLastName() from the local interface, Jboss throws a couple of 
exceptions telling me that the primary key is null.
 
If I invoke the toString() method of the local interfaces I get the JNDI 
name of the EJB followed by the content of the lastName field, so the 
information is obviously there, but I can?t get it out in a clean way. 
What am I doing wrong?
 
I?m using JBoss 3.2.2 (final production version).
 
Regards,
Ulf
 
Ulf Tidstrand
Software Engineer
IMI - Industrial Environmental Informatics
Chalmers University of Technology

Voice  +46 31 772 4914
Fax+46 31 772 4915
E-mail [EMAIL PROTECTED]
Webwww.imi.chalmers.se
 



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?   SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] Returning single field as Collection with EJB QL

2003-10-31 Thread Jonathan . O'Connor
Ulf,
Correct. But you may be able to attach this to the home interface where it 
makes more sense. Sorry, I'm not sure how to do this, although it should 
be easy.
Ciao,
Jonathan O'Connor




Ulf Tidstrand [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
31.10.2003 11:03
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] Returning single field as 
Collection with EJB QL


Thanks, that made it much clearer!

But then I have a follow-up question: As I've understood, the ejbSelect
methods are only available locally from within the EJB itself. So if I
would like to make a general getAllLastNames() method returning all
LastNames in a table (not associated to a special entity), I should do
the following:

1. Implement an abstract ejbSelectLastNames() method in the bean with a
corresponding EJB QL statement
2. Implement a getLastNames() as an interface method in the EJB which in
turn calls the ejbSelectLastNames() method
3. When I want to invoke the getLastNames() method from a client, I
first have to find an arbitrary entity bean and then invoke the method
from that bean.

Is that right?

Regards,
Ulf

-Original Message-
From: Jonathan.O'[EMAIL PROTECTED] [mailto:Jonathan.O'[EMAIL PROTECTED] 
Sent: den 31 oktober 2003 11:31
To: [EMAIL PROTECTED]
Subject: Re: [JBoss-user] Returning single field as Collection with EJB
QL

Ulf,
You need an ejb.select instead. Finders are defined to return the Entity

Bean interface (local or remote). Select() lets you find non entity bean

stuff.
to be more specific, in an Entity Bean, FooBean, finders always return 
FooRemote or FooLocal objects. Use ejb.Select to return other stuff such

as your last names.
Ciao,
Jonathan O'Connor
XCOM Dublin




Ulf Tidstrand [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
31.10.2003 07:47
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Returning single field as
Collection 
with EJB QL


Hi everyone,
 
I have declared a simple EJB QL statement in xdoclet:
 
 * @ejb.finder
 *signature=java.util.Collection findAllLastNames()
 *query=SELECT DISTINCT u.lastName FROM user AS u
 
The lastName field is of type String, so I thought that this statement 
would return all uniqe last names in the table as a Collection of
String. 
However it seems to return a Collection of local interfaces instead. 
That?s fine, but the problem is that the primary key fields are not set
in 
those local interfaces so whenever I try to fetch the ?lastName? field 
with getLastName() from the local interface, Jboss throws a couple of 
exceptions telling me that the primary key is null.
 
If I invoke the toString() method of the local interfaces I get the JNDI

name of the EJB followed by the content of the lastName field, so the 
information is obviously there, but I can?t get it out in a clean way. 
What am I doing wrong?
 
I?m using JBoss 3.2.2 (final production version).
 
Regards,
Ulf
 
Ulf Tidstrand
Software Engineer
IMI - Industrial Environmental Informatics
Chalmers University of Technology

Voice  +46 31 772 4914
Fax+46 31 772 4915
E-mail [EMAIL PROTECTED]
Webwww.imi.chalmers.se
 



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?   SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?   SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?   SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] PostgreSQL and NOT NULL integer fields

2003-10-25 Thread Jonathan . O'Connor
Ivens,
your int CMP fields should definitely be NOT NULL. Consider what happens 
if you have a NULL int column. What should happen when you read a NULL 
value from the DB?
int i = null; is not valid Java code.
int i = 0; is correct Java code, but then you are assuming that NULL and 0 
are equivalent for your field.

The solution should be that if you want nulls in your numeric data, then 
you use an java.lang.Integer, and then:
Integer i = null; is good code.

Hope this helps,
Jonathan O'Connor
XCOM Dublin




Ivens Porto [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
23.10.2003 21:48
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] PostgreSQL and NOT NULL integer 
fields


Hi,

I'm using JBoss 3.2.2 and PostgreSQL 7.3.4.

JBoss is doing something that I can't figure out why. 

In my CMP beans, JBoss always use the constraint NOT NULL for fields of
type integer, even thought I don't set the not-null/ property in
jbosscmp-jdbc.xml for the fields.

If the persistent field in the CMP bean is of type int or Integer, JBoss
creates the database table with the constraint NOT NULL for integer type
fields.

Does anyone knows why JBoss does this?
-- 
  _/_/_/   _/_/_/_/_/_/
Ivens Porto _/ _/_/_/
OSE - Open Systems Engineering _/ _/_/_/
http://www.ose.com.br _/ _/  _/_/_/  _/_/_/_/
Phone: (55) 34 - 3214-5995   _/ _/_/_/
Fax:   (55) 34 - 3214-5994  _/ _/_/_/
 _/_/_/_/_/_/   _/_/_/


---
This SF.net email is sponsored by: The SF.net Donation Program.
Do you like what SourceForge.net is doing for the Open
Source Community?  Make a contribution, and help us add new
features and functionality. Click here: http://sourceforge.net/donate/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
This SF.net email is sponsored by: The SF.net Donation Program.
Do you like what SourceForge.net is doing for the Open
Source Community?  Make a contribution, and help us add new
features and functionality. Click here: http://sourceforge.net/donate/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Specifying deployment order in EAR - JBoss 3.2.2

2003-10-23 Thread Jonathan . O'Connor
Scott,
As Sherlock Holmes said (?), when all the probable causes have been 
eliminated, then we must look at the improbable causes!
The problem is the listener in the WAR is failing because the session 
beans do not exist.
And as the ejb jar was deployed first, then its deployment must have 
failed. I'll look into that and get back to you if I find anything.
Thanks,
Jonathan O'Connor
XCOM Dublin




Scott M Stark [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
20.10.2003 17:06
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Specifying deployment order in 
EAR - JBoss 3.2.2


ejb jars are deployed before wars so show the startup ordering. A test.ear
with ejbs and a war shows the ejbs started before the war:

09:14:48,246 INFO  [MainDeployer] Starting deployment of package: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/
09:14:48,247 INFO  [EARDeployer] Init J2EE application: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/
09:14:49,956 INFO  [EjbModule] Deploying BMPBean
09:14:50,216 INFO  [EjbModule] Deploying BMPCallbackBean
09:14:50,232 INFO  [EjbModule] Deploying CMPBean
09:14:50,272 INFO  [EjbModule] Deploying CMPBean2
...
09:14:53,536 INFO  [EJBDeployer] Deployed: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/cts.jar
09:14:53,794 INFO  [EmbeddedTomcatService] deploy, ctxPath=/traxbahn, 
warUrl=file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/traxbahn.war/
09:14:54,312 INFO  [Engine] ContextConfig[/traxbahn]: Added certificates 
- 
request attribute Valve
...
09:14:54,347 INFO  [Engine] StandardWrapper[/traxbahn:invoker]: Loading 
container servlet invoker
09:14:54,758 INFO  [EARDeployer] Started J2EE application: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/
09:14:54,758 INFO  [MainDeployer] Deployed package: 
file:/tmp/jboss-3.2.2/server/default/deploy/test.ear/

-- 

Scott Stark
Chief Technology Officer
JBoss Group, LLC


Jonathan.O'[EMAIL PROTECTED] wrote:

 Hi, I'm trying to migrate our code from JBoss 3.0.6 to 3.2.2 and I've 
got 
 a problem due to deployment order.
 My ear file has a backend.jar containing entity beans and session beans, 
a 
 frontend.war. In 3.0.6, the backend.jar was always deployed first before 

 the WAR. This meant that a listener in the WAR ran happily accessing 
 session beans in the backend.
 
 But in 3.2.2 (and in RC4 too) I get an exception trying to run the 
 listener code in contextInitialized(). It seems that the session beans 
in 
 the backend.jar have not been loaded yet. Is there a way of setting a 
 dependency on the order of loading in 3.2.2? jboss-service.xml has a 
 depends clause, but that won't work for ejb or web stuff.
 
 Any help would be greatly appreciated
 Ciao,
 Jonathan O'Connor
 XCOM Dublin



---
This SF.net email is sponsored by OSDN developer relations
Here's your chance to show off your extensive product knowledge
We want to know what you know. Tell us and you have a chance to win $100
http://www.zoomerang.com/survey.zgi?HRPT1X3RYQNC5V4MLNSV3E54
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
This SF.net email is sponsored by OSDN developer relations
Here's your chance to show off your extensive product knowledge
We want to know what you know. Tell us and you have a chance to win $100
http://www.zoomerang.com/survey.zgi?HRPT1X3RYQNC5V4MLNSV3E54
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Specifying deployment order in EAR - JBoss 3.2.2

2003-10-20 Thread Jonathan . O'Connor
Hi, I'm trying to migrate our code from JBoss 3.0.6 to 3.2.2 and I've got 
a problem due to deployment order.
My ear file has a backend.jar containing entity beans and session beans, a 
frontend.war. In 3.0.6, the backend.jar was always deployed first before 
the WAR. This meant that a listener in the WAR ran happily accessing 
session beans in the backend.

But in 3.2.2 (and in RC4 too) I get an exception trying to run the 
listener code in contextInitialized(). It seems that the session beans in 
the backend.jar have not been loaded yet. Is there a way of setting a 
dependency on the order of loading in 3.2.2? jboss-service.xml has a 
depends clause, but that won't work for ejb or web stuff.

Any help would be greatly appreciated
Ciao,
Jonathan O'Connor
XCOM Dublin


---
This SF.net email sponsored by: Enterprise Linux Forum Conference  Expo
The Event For Linux Datacenter Solutions  Strategies in The Enterprise 
Linux in the Boardroom; in the Front Office;  in the Server Room 
http://www.enterpriselinuxforum.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] Specifying deployment order in EAR - JBoss 3.2.2

2003-10-20 Thread Jonathan . O'Connor
Rod,
It sure does. Here it is:
application
display-nameTraxbahnApp/display-name
descriptionAll Traxbahn Entity, Message Driven and Session Bean 
jars/description
 
module
ejbbackend.jar/ejb
/module
module
javaTIPS_bs_soap.wsr/java
/module
module
web
web-uritraxbahn.war/web-uri
context-roottraxbahn/context-root
/web
/module 
/application

And this works perfectly in JBoss 3.0.6 and 3.0.8

Ciao,
Jonathan O'Connor
XCOM Dublin




Rod Macpherson [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
20.10.2003 13:24
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] Specifying deployment order in 
EAR - JBoss 3.2.2


Does the EAR's application.xml include both the EJB and WEB module
elements? 

-Original Message-
From: Jonathan.O'[EMAIL PROTECTED] [mailto:Jonathan.O'[EMAIL PROTECTED] 
Sent: Monday, October 20, 2003 4:50 AM
To: [EMAIL PROTECTED]
Subject: [JBoss-user] Specifying deployment order in EAR - JBoss 3.2.2


Hi, I'm trying to migrate our code from JBoss 3.0.6 to 3.2.2 and I've
got 
a problem due to deployment order.
My ear file has a backend.jar containing entity beans and session beans,
a 
frontend.war. In 3.0.6, the backend.jar was always deployed first before

the WAR. This meant that a listener in the WAR ran happily accessing 
session beans in the backend.

But in 3.2.2 (and in RC4 too) I get an exception trying to run the 
listener code in contextInitialized(). It seems that the session beans
in 
the backend.jar have not been loaded yet. Is there a way of setting a 
dependency on the order of loading in 3.2.2? jboss-service.xml has a 
depends clause, but that won't work for ejb or web stuff.

Any help would be greatly appreciated
Ciao,
Jonathan O'Connor
XCOM Dublin


---
This SF.net email sponsored by: Enterprise Linux Forum Conference  Expo
The Event For Linux Datacenter Solutions  Strategies in The Enterprise 
Linux in the Boardroom; in the Front Office;  in the Server Room 
http://www.enterpriselinuxforum.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


---
This SF.net email sponsored by: Enterprise Linux Forum Conference  Expo
The Event For Linux Datacenter Solutions  Strategies in The Enterprise 
Linux in the Boardroom; in the Front Office;  in the Server Room 
http://www.enterpriselinuxforum.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
This SF.net email sponsored by: Enterprise Linux Forum Conference  Expo
The Event For Linux Datacenter Solutions  Strategies in The Enterprise 
Linux in the Boardroom; in the Front Office;  in the Server Room 
http://www.enterpriselinuxforum.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] Re: 3.2.2 Release Available

2003-10-20 Thread Jonathan . O'Connor
Brian,
A few months ago, due to plenty of politics (let sleeping dogs lie), JBoss 
switched from Jetty to Tomcat as the default web server. So JBoss-3.2.2 is 
the Tomcat bundle. JBoss-3.2.2_jetty-4.2.11 is the Jetty bundle. You'll 
have to check the documentation for the Tomcat version number, but its 
probably 4.1.24 or better.
Ciao,
Jonathan O'Connor
XCOM Dublin




Brian McSweeney [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
20.10.2003 11:11
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] Re: 3.2.2 Release Available


Also,
Could someone explain how the releases of JBoss-Tomcat work?
For example, at the moment it seems we are on 

jboss-3.2.2RC1_tomcat-4.1.24

so I presume JBoss-3.2.2 is the jetty bundle.

If this is the case, when do you expect 

jboss-3.2.2_tomcat-4.1.24

to be released?

Thanks,
Brian


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Eric Jain
Sent: 20 October 2003 08:38
To: jboss-user
Subject: [JBoss-user] Re: 3.2.2 Release Available

 The release notes are available here:

http://sourceforge.net/docman/display_doc.php?docid=19500group_id=22866

Thanks, great work!

Incidently, I believe it would be usefull if there was a list of major
changes and fixes in addition to the detailed change log, something like
http://download.eclipse.org/downloads/drops/S-3.0M4-200310101454/eclipse
-news-all-M4.html
or http://jetty.mortbay.org/jetty/versions.txt.

--
Eric Jain



---
This SF.net email sponsored by: Enterprise Linux Forum Conference  Expo
The Event For Linux Datacenter Solutions  Strategies in The Enterprise 
Linux in the Boardroom; in the Front Office;  in the Server Room 
http://www.enterpriselinuxforum.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



---
This SF.net email sponsored by: Enterprise Linux Forum Conference  Expo
The Event For Linux Datacenter Solutions  Strategies in The Enterprise 
Linux in the Boardroom; in the Front Office;  in the Server Room 
http://www.enterpriselinuxforum.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
This SF.net email is sponsored by OSDN developer relations
Here's your chance to show off your extensive product knowledge
We want to know what you know. Tell us and you have a chance to win $100
http://www.zoomerang.com/survey.zgi?HRPT1X3RYQNC5V4MLNSV3E54
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Unusual Deployer Exception - What does it mean?

2003-10-16 Thread Jonathan . O'Connor
Hi,
I just started using JBoss 3.2.2RC4, and I'm getting the following in my 
server log:
15:20:59,366 ERROR [URLDeploymentScanner] MBeanException: Exception in 
MBean operation 'checkIncompleteDeployments()'
Cause: Incomplete Deployment listing:
Packages waiting for a deployer:
[EMAIL PROTECTED] { 
url=file:/H:/server/traxbahn/tmp/deploy/tmp14307traxbahn.ear-contents/TIPS_bs_soap.wsr 
}
  deployer: null
  status: Starting
  state: START_SUBDEPLOYMENTS
  watch: 
file:/H:/server/traxbahn/tmp/deploy/tmp14307traxbahn.ear-contents/TIPS_bs_soap.wsr
  lastDeployed: 1066314023585
  lastModified: 1066314015994
  mbeans:
]Incompletely deployed packages:
  none
MBeans waiting for classes:
  none
MBeans waiting for other MBeans:
  none

I've copied jboss-net.sar from /server/all/deploy to 
/server/myconfig/deploy. So, I'd love to know why its still a problem.

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 9736


---
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Unusual Deployer Exception - What does it mean? - Please Ignore

2003-10-16 Thread Jonathan . O'Connor
Mea Culpa,
My deploy target had the bit that copied jboss-net.sar commented out. 
Please ignore
Ciao,
Jonathan O'Connor
XCOM Dublin




Jonathan.O'[EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
16.10.2003 15:41
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Unusual Deployer Exception - What 
does it mean?


Hi,
I just started using JBoss 3.2.2RC4, and I'm getting the following in my 
server log:
15:20:59,366 ERROR [URLDeploymentScanner] MBeanException: Exception in 
MBean operation 'checkIncompleteDeployments()'
Cause: Incomplete Deployment listing:
Packages waiting for a deployer:
[EMAIL PROTECTED] { 
url=file:/H:/server/traxbahn/tmp/deploy/tmp14307traxbahn.ear-contents/TIPS_bs_soap.wsr 

}
  deployer: null
  status: Starting
  state: START_SUBDEPLOYMENTS
  watch: 
file:/H:/server/traxbahn/tmp/deploy/tmp14307traxbahn.ear-contents/TIPS_bs_soap.wsr
  lastDeployed: 1066314023585
  lastModified: 1066314015994
  mbeans:
]Incompletely deployed packages:
  none
MBeans waiting for classes:
  none
MBeans waiting for other MBeans:
  none

I've copied jboss-net.sar from /server/all/deploy to 
/server/myconfig/deploy. So, I'd love to know why its still a problem.

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 9736


---
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] magic ejb server

2003-10-14 Thread Jonathan . O'Connor
Bruce,
We found this problem about a year ago (maybe more, I can't remember now). 
I did get an answer here to the effect that the client goes hunting on 
your LAN for another EJB server, although it tries the one specified in 
your jndi.properties first. No doubt, I'm not telling you anything you 
don't know already, but this is standard behavior.
Ciao,
Jonathan O'Connor
XCOM Dublin




Bruce Ashton [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
14.10.2003 10:42
Please respond to jboss-user
 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] magic ejb server


Hi all,
 I have discovered some unusual behaviour in that isn't 
actually
causing a problem atm, but does worry me slightly.

I have JBoss running on my own PC and on another box ( Solaris ) whihc is 
on
the same subnet as my PC.

I am using Ant and Junit to test my EJB's.

See the Junit code below:


public class CustomerTest extends TestCase {

private InitialContext ctx;
CustomerHome cHome;


/**
 * codesetUp/code is run once before each and every test method, 
and
 * discovers the codeCustomerHome/code object.
 */
protected void setUp() {
try {
ctx = new InitialContext();
Hashtable ctxHash = ctx.getEnvironment();
for (Enumeration e = ctxHash.keys(); e.hasMoreElements();) {
Object elmt = e.nextElement();
System.out.println(elmt.toString());
System.out.println(ctxHash.get(elmt).toString());
}
cHome = (CustomerHome)ctx.lookup(ejb/Customer);
} catch (NamingException ne) {
}
}


/**
 * codetestGetCompanyDTO/code gets a single Company DTO object 
with
a
 * hard-coded primary key. ( ACT for Activis ) It gets the company
name
 * from the DTO to assure that it is a valid CompanyDTO object.
 */
public void testGetCompanyDTO() {

CompanyDTO companyDTO = new CompanyDTO();

try {
Customer cSession = cHome.create();
companyDTO = cSession.getCompanyDTO(ACT); 
} catch (CreateException ce) {
} catch (RemoteException re) {
}
String companyName = companyDTO.getCompanyName();
Assert.assertEquals(Activis, companyName);
}
.snip



Running this give the following output:


Testsuite: test.activis.ejb.session.CustomerTest
Tests run: 2, Failures: 0, Errors: 0, Time elapsed: 12.118 sec
- Standard Output ---
java.naming.factory.initial
org.jnp.interfaces.NamingContextFactory
java.naming.provider.url
localhost:1099
java.naming.factory.url.pkgs
org.jboss.naming:org.jnp.interfaces
java.naming.factory.initial
org.jnp.interfaces.NamingContextFactory
java.naming.provider.url
localhost:1099
java.naming.factory.url.pkgs
org.jboss.naming:org.jnp.interfaces
-  ---

Testcase: testGetCompanyDTO took 6.209 sec


Now the interesting part.  My testcase will still succeed even when the
JBoss service on my local machine is OFF.  It will fail only when neither
JBoss server is running.
Any ideas what's going on?


Bruce Ashton
Senior Developer
Ext. 8272
http://www.activis.com/ 


Please note that:
 
1. This e-mail may constitute privileged information. If you are not the 
intended recipient, you have received this confidential email and any 
attachments transmitted with it in error and you must not disclose, copy, 
circulate or in any other way use or rely on this information.
2. E-mails to and from the company are monitored for operational reasons 
and in accordance with lawful business practices.
3. The contents of this email are those of the individual and do not 
necessarily represent the views of the company.
4. The company does not conclude contracts by email and all negotiations 
are subject to contract.
5. The company accepts no responsibility once an e-mail and any 
attachments is sent.

http://www.activis.com


This annotation was added by the e-scan service.
http://www.activis.com
--
This message has been checked for all known viruses by e:)scan.
For further information please contact [EMAIL PROTECTED]


---
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




---
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php

[JBoss-user] type-mapping does not alllow read-ahead in standardjbosscmp-jdbc.xml

2003-09-25 Thread Jonathan . O'Connor
Adrian,
Thanks, that's brilliant. I have patched the standardjbosscmp-jdbc.xml and 
made two changes to the sybase configuration:
I have added the following line to ensure only upto 250:
read-aheadpage-size250/page-size/read-ahead
Sadly this only works if I change the defaults and not the sybase 
type-mapping. I believe this is an error in the DTD. If you fix this, 
please add 250 page-size to the sybase type-mapping.

I have also changed the type-mapping for Sybase to use LONGVARBINARY for 
IMAGE data instead of JAVA_OBJECT(? I think):
type-mapping
nameSybase/name
!-- and so on --
 mapping
java-typejava.lang.Object/java-type
jdbc-typeLONGVARBINARY/jdbc-type
sql-typeIMAGE/sql-type
 /mapping
/type-mapping
Thanks,
Jonathan O'Connor
XCOM Dublin




Adrian Brock [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
24.09.2003 14:02
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Bad SQL generated for Sybase 12.0


You can limit the ORs generated using the page-size on the
read-ahead.

Regards,
Adrian

On Wed, 2003-09-24 at 11:01, Jonathan.O'[EMAIL PROTECTED] wrote:
 Running JBoss 3.0.6, running a finder on a entity bean, JBoss generates 
a 
 load query like:
 select field1, field2, field3 from MY_TABLE where ID = 1 or ID = 2 or ID 
= 
 3 ...
 Normally this code is fine, however, the finder happens to find more 
than 
 250 rows, and Sybase ASE12.0 does not like where clauses with more than 
 250 ANDs or ORs. I tried changing the select statement to Select 
field1, 
 field2, field3 from MY_TABLE where ID in (1, 2, 3...) but this produced 

 the same error message. It seems Sybase translates the IN clause to a 
 series of ORs.
 
 Is the only work around to upgrade to 3.2.2 and use LIMIT and OFFSET to 
 get around the problem? Yes, I know this is probably a better solution 
in 
 the long run, but...
 
 Any advice would be appreciated.
 Ciao,
 Jonathan O'Connor
 XCOM Dublin
 
 
 ---
 This sf.net email is sponsored by:ThinkGeek
 Welcome to geek heaven.
 http://thinkgeek.com/sf
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user
-- 
 
Adrian Brock
Director of Support
Back Office
JBoss Group, LLC 
 



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Bad SQL generated for Sybase 12.0

2003-09-24 Thread Jonathan . O'Connor
Running JBoss 3.0.6, running a finder on a entity bean, JBoss generates a 
load query like:
select field1, field2, field3 from MY_TABLE where ID = 1 or ID = 2 or ID = 
3 ...
Normally this code is fine, however, the finder happens to find more than 
250 rows, and Sybase ASE12.0 does not like where clauses with more than 
250 ANDs or ORs. I tried changing the select statement to Select field1, 
field2, field3 from MY_TABLE where ID in (1, 2, 3...) but this produced 
the same error message. It seems Sybase translates the IN clause to a 
series of ORs.

Is the only work around to upgrade to 3.2.2 and use LIMIT and OFFSET to 
get around the problem? Yes, I know this is probably a better solution in 
the long run, but...

Any advice would be appreciated.
Ciao,
Jonathan O'Connor
XCOM Dublin


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: EjbQL-bug in Jboss? (was: Re: [JBoss-user] Isn't the string literal '0' allowed?)

2003-09-15 Thread Jonathan . O'Connor
Jon,
pedantic
Java type char is a numeric type!  But of course you can store '0', '1', 
'a' and 'n' in it, as well as 0, 1, 789, and so on.
/pedantic
Of course, this doesn't explain your problem.
Ciao,
Jonathan O'Connor
XCOM Dublin




Jon Haugsand [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
15.09.2003 09:58
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:EjbQL-bug in Jboss? (was: Re: [JBoss-user] Isn't the string 
literal'0' 
allowed?)


* Adrian Brock
 On Mon, 2003-09-15 at 09:26, Jon Haugsand wrote:
 * Adrian Brock
  It is expecting a number not a string.
 
 And why should it expect a numer and not a string?  Strings are
 clearly allowed in EJB QL.

 because tillatLaaneadgang is a numeric type

But it isn't!  It is of char(1).  Does JBoss consider this as numeric?
It is the opposite in Weblogic where it fails if assumed numeric.

Oracle certainly does not consider this as numeric.  It can contain
any of the values '0', '1', 'A', 'N'.

Further, it certainly works in JBoss as well, e.g.

  public abstract void setTillatLaaneadgang( char v);
  kunde.setTillatLaaneadgang( 'N' );

I cannot possible imagine this as something else than a JBoss bug.

-- 
 Jon Haugsand, [EMAIL PROTECTED]
 http://www.norges-bank.no



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] forums versus mailing list

2003-09-11 Thread Jonathan . O'Connor
Sacha,
Could you not do it in your Blog if you have any?
And add a smiley to your jokes for those who left their sense of humour at 
home!
Ciao,
Jonathan O'Connor




Sacha Labourey [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
11.09.2003 07:43
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] forums versus mailing list


 Rod Macpherson wrote:
 
  That would definitely be more appropriate. 
 
 The most appropriate approach is to answer the question where 
 it had been asked, 
 IMHO.

Please, let me address that very specific point on the wiki.



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Advice wanted for tracking Deadlocks

2003-08-29 Thread Jonathan . O'Connor
I just started stress testing our JBoss server. I run our unit tests 
simultaneously in two different windows. However, I'm getting a number of 
deadlocks occurring in both Entity Bean creation and removal.
Does anyone have any bright ideas how I can track down the problem?
In case its relevant, JBoss version is 3.0.6 and I'm connected to a Sybase 
ASE 12.0 DB using JConnect 5.5 JDBC driver.

Ciao,
Jonathan O'Connor
XCOM Dublin


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Advice wanted for tracking Deadlocks

2003-08-29 Thread Jonathan . O'Connor
Bill,
Sadly, I'm getting DB deadlocks. Sometimes they freeze the whole system, 
and other times they don't. I'll have a look at the entity lock monitor. 
Sounds good.
Thanks,
Jonathan O'Connor





Bill Burke [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
29.08.2003 17:57
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Advice wanted for tracking Deadlocks


I don't remember, but I think my EntityLockMonitor is in 3.0.6. 
Uncomment this MBean within server/your-config/conf/jboss-service.xml

It has a number of utilities for debugging deadlocks.  See our for-pay 
doco for more info.

Are you getting DB deadlocks or JBoss deadlocks?

Bill

Jonathan.O'[EMAIL PROTECTED] wrote:

 I just started stress testing our JBoss server. I run our unit tests 
 simultaneously in two different windows. However, I'm getting a number 
of 
 deadlocks occurring in both Entity Bean creation and removal.
 Does anyone have any bright ideas how I can track down the problem?
 In case its relevant, JBoss version is 3.0.6 and I'm connected to a 
Sybase 
 ASE 12.0 DB using JConnect 5.5 JDBC driver.
 
 Ciao,
 Jonathan O'Connor
 XCOM Dublin
 
 
 ---
 This sf.net email is sponsored by:ThinkGeek
 Welcome to geek heaven.
 http://thinkgeek.com/sf
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user
 
 

-- 

Bill Burke
Chief Architect
JBoss Group LLC.




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Use of Blobs (Renamed from: CMP support for blobs brokenusing Sybase)

2003-08-14 Thread Jonathan . O'Connor
Stephen.
Thanks for the advice. As t why we are using blobs, here's my explanation, 
and I'd be interested in any other approaches:

We receive messages from Mastercard. They are formatted following ISO 8583 
(basically binary). We unpack the message and write many (about 30) of the 
unpacked fields to our DB. For auditing and future use, we also store the 
original raw message as a blob. Message size ranges from 100-1000 bytes. 
Typical values are around 300 bytes.

Ciao,
Jonathan O'Connor
XCOM Dublin





Stephen Coy [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
06.08.2003 13:31
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] CMP support for blobs broken using Sybase


Hi,

The current JBoss implementation does the following mapping for JDBC 
access:

Types.CLOB, LONGVARCHAR: use set/getCharacterStream
Types.BLOB, LONGVARBINARYuse set/getBinaryStream
Types.BINARY, VARBINARY  use set/getBytes

So, you could try setting the JDBC type to LONGVARBINARY.

I recently said the following to an Oracle user, and I think it applies 
to you as well:

In my opinion (knowing what I know now about EJB entity beans), you 
should not be storing LOBs in your primary entities anyway. Getting the 
LOB data to your client may result in multiple copies of it being 
instantiated in memory - and given the nature of LOBs (they can be BIG 
;-) ), this may be quite expensive and it won't scale very well.

I would either keep the LOB data in separate related tables, or use the 
same table and hide the LOB columns from the CMP engine by mapping the 
table to a couple of views. Then use a business facade style of session 
bean to load the LOB data in whatever fashion you see fit using pure 
JDBC or even the Oracle extensions. It may even be advantageous to load 
it directly from the client side using a business delegate and get full 
and proper advantage of the streaming interfaces.

Use the CMP engine to get yourself up and running quickly (you seem to 
have accomplished that) and then refine it as above and I think your 
application will be much happier.

Regards,

Steve Coy


On Wednesday, August 6, 2003, at 12:36  AM, Jonathan.O'[EMAIL PROTECTED] 
wrote:

 Further migration problems have reared their head. The Sybase JDBC 
 driver
 throws an exception when I try to write a blob using CMP. It complains
 that SQL Type 1004 is not supported. This is SqlType.BLOB.

 On talking to colleagues who have written JDBC code for sybase and 
 blobs,
 I have been told that we should use SqlType.BINARY and call
 PreparedStatement.setBinaryStream() instead of setBytes().
 Whatever, I would like to hear of anybody out there who is using JBoss
 (We're on 3.0.6) and Sybase 12.0 to write blobs (IMAGE in Sybase SQL).

 Finally, here's the stack trace:
 13:14:31,918 ERROR [Dispute] Could not create entity
 java.sql.SQLException: JZ006: Caught IOException: java.io.IOException:
 JZ0SL: Unsupported SQL type 2004.
 at
 com.sybase.jdbc2.jdbc.ErrorMessage.raiseError(ErrorMessage.java:526)
 at
 com.sybase.jdbc2.jdbc.ErrorMessage.raiseErrorCheckDead(ErrorMessage.jav 
 a:762)
 at com.sybase.jdbc2.tds.Tds.handleIOE(Tds.java:3160)
 at com.sybase.jdbc2.tds.Tds.language(Tds.java:702)
 at
 com.sybase.jdbc2.jdbc.SybStatement.sendQuery(SybStatement.java:1451)
 at
 com.sybase.jdbc2.jdbc.SybPreparedStatement.sendQuery(SybPreparedStateme 
 nt.java:1168)
 at
 com.sybase.jdbc2.jdbc.SybStatement.executeUpdate(SybStatement.java:1621 
 )
 at
 com.sybase.jdbc2.jdbc.SybPreparedStatement.executeUpdate(SybPreparedSta 
 tement.java:91)
 at
 org.jboss.resource.adapter.jdbc.local.LocalPreparedStatement.executeUpd 
 ate(LocalPreparedStatement.java:308)
 at
 org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.insertEntity(JDB 
 CCreateEntityCommand.java:196)
 at
 org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.execute(JDBCCrea 
 teEntityCommand.java:131)
 at
 org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.createEntity(JDBCStoreM 
 anager.java:527)
 at
 org.jboss.ejb.plugins.CMPPersistenceManager.createEntity(CMPPersistence 
 Manager.java:253)
 at
 org.jboss.resource.connectionmanager.CachedConnectionInterceptor.create 
 Entity(CachedConnectionInterceptor.jav
 a:270)
 at
 org.jboss.ejb.EntityContainer.createLocalHome(EntityContainer.java:580)
 at sun.reflect.GeneratedMethodAccessor40.invoke(Unknown Source)
 at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccesso 
 rImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:324)
 at
 org.jboss.ejb.EntityContainer$ContainerInterceptor.invokeHome(EntityCon 
 tainer.java:1119)
 at
 org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractIntercepto 
 r.java:73

Re: [JBoss-user] JBoss Error in generated SQL for finder (Sybaserestriction)

2003-08-09 Thread Jonathan . O'Connor
Stephen, sadly, I already do have that tag. I did code a workaround, by 
renaming the methods from getAccountObjs to getAccounts. Of course, that's 
cheating really!

Here's the relevant bits of source code for PersonBean:
/** 
 *  @ejb.interface-method 
 *
 *  @ejb.relation
 *  name=t_account-t_person
 *  role-name=t_person-has-t_accounts
 *
 *  @jboss.relation-table
 *  table-name=T_ACCOUNT_PERSON
 *
 *  @jboss.relation
 *  fk-constraint=true
 *  fk-column=T_ACCOUNT_ID
 *  related-pk-field=accountId
 */
public abstract Collection getAccounts();

And here's the code from the AccountBean:
/** 
 *  @ejb.interface-method
 *
 *  @ejb.relation
 *  name=t_account-t_person
 *  role-name=t_account-has-t_persons
 *
 *  @jboss.relation-table
 *  table-name=T_ACCOUNT_PERSON
 *
 *  @jboss.relation
 *  fk-column=T_PERSON_ID
 *  related-pk-field=personId
 */
public abstract Collection getPersonObjs();

Ciao,
Jonathan O'Connor
XCOM Dublin





Stephen Coy [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
07.08.2003 15:18
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] JBoss Error in generated SQL for finder 
(Sybase 
restriction)


You need the @jboss.relation-table (0..1) tag associated with the other 
account-person CMR tags.

Sybase is not alone with this restriction - Oracle has it as well - 32 
character identifiers.

Steve Coy

On Thursday, August 7, 2003, at 09:39  PM, Jonathan.O'[EMAIL PROTECTED] 
wrote:

 Well, finally I've hit upon a real JBoss problem (we're using JBoss 
 3.0.6
 with Sybase 12.0 and the JDBC driver is JConnect2 version 5.5).

 We have a finder on one of our entity beans. It's declared as such:
  *  @ejb.finder
  *signature=java.util.Collection 
 findCardsForPersonAndAccounts(java.lang.Long personId)
  *result-type-mapping=Local
  *method-intf=LocalHome
  *query=SELECT DISTINCT OBJECT(c) FROM T_Card c, T_Person p, IN 
 (p.accountObjs) accounts WHERE c.cardHolder.personId=?1 OR 
 (p.personId=?1 AND c MEMBER OF accounts.cardObjs)
  *

 A T_Card has one T_Person who is the card holder. An account can have 
 many
 cards, and a person can have many accounts. The problem is SQL 
 generated
 needs a name for the account-person relationship and it generates this
 very long name t5_p_accountObjs_RELATION_TABLE, which Sybase does 
 not like.

 2003-08-07 11:46:42,900 4344667 DEBUG
 [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.Card.findCardsForPersonA 
 ndAccounts]
 (RMI TCP Connection(12)-10.100.1.22:Card) Executing SQL: SELECT 
 DISTINCT
 t0_c.T_CARD_ID FROM T_CARD t0_c, T_PERSON t2_p, T_ACCOUNT t3_accounts,
 T_ACCOUNT_PERSON t5_p_accountObjs_RELATION_TABLE, T_PERSON 
 t1_c_cardHolder
 WHERE (t1_c_cardHolder.T_PERSON_ID = ? OR (t2_p.T_PERSON_ID = ? AND 
 EXISTS
 (SELECT t4_accounts_cardObjs.T_CARD_ID FROM T_CARD t4_accounts_cardObjs
 WHERE t3_accounts.T_ACCOUNT_ID=t4_accounts_cardObjs.T_ACCOUNT_ID AND
 t4_accounts_cardObjs.T_CARD_ID = t0_c.T_CARD_ID))) AND
 (t0_c.T_PERSON_ID=t1_c_cardHolder.T_PERSON_ID AND
 t2_p.T_PERSON_ID=t5_p_accountObjs_RELATION_TABLE.T_PERSON_ID AND
 t3_accounts.T_ACCOUNT_ID=t5_p_accountObjs_RELATION_TABLE.T_ACCOUNT_ID)
 2003-08-07 11:46:42,940 4344707 DEBUG
 [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.Card.findCardsForPersonA 
 ndAccounts]
 (RMI TCP Connection(12)-10.100.1.22:Card) Find failed
 com.sybase.jdbc2.jdbc.SybSQLException: The identifier that starts with
 't5_p_accountObjs_RELATION_TABL' is too long.  Maximum length is 30.

 at com.sybase.jdbc2.tds.Tds.processEed(Tds.java:2672)
 at com.sybase.jdbc2.tds.Tds.nextResult(Tds.java:2032)
 at
 com.sybase.jdbc2.jdbc.ResultGetter.nextResult(ResultGetter.java:69)
 at
 com.sybase.jdbc2.jdbc.SybStatement.nextResult(SybStatement.java:204)
 at
 com.sybase.jdbc2.jdbc.SybStatement.nextResult(SybStatement.java:187)
 at
 com.sybase.jdbc2.jdbc.SybStatement.queryLoop(SybStatement.java:1537)
 at
 com.sybase.jdbc2.jdbc.SybStatement.executeQuery(SybStatement.java:1522)
 at
 com.sybase.jdbc2.jdbc.SybPreparedStatement.executeQuery(SybPreparedStat 
 ement.java:72)
 at
 org.jboss.resource.adapter.jdbc.local.LocalPreparedStatement.executeQue 
 ry(LocalPreparedStatement.java:289)
 at
 org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractQueryCommand.execute(JDBCAbs 
 tractQueryCommand.java:112)
 at
 org.jboss.ejb.plugins.cmp.jdbc.JDBCFindEntitiesCommand.execute(JDBCFind 
 EntitiesCommand.java:40)
 at
 org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.findEntities(JDBCStoreM 
 anager.java:549)
 at
 org.jboss.ejb.plugins.CMPPersistenceManager.findEntities(CMPPersistence 
 Manager.java:348)
 at
 org.jboss.resource.connectionmanager.CachedConnectionInterceptor.findEn 
 tities

Re: [JBoss-user] CMP support for blobs broken using Sybase - Solution

2003-08-09 Thread Jonathan . O'Connor
Well, that fixed the problem. Firstly, I was very stupid, and my ant build 
script was still using Oracle9i as the type mapping. Once that was fixed, 
In standardjbosscmp-jdbc.xml, I just changed the jdbc type for 
java.lang.object mapping, from JAVA_OBJECT to LONGVARBINARY. After that it 
started working. Maybe this file should be changed for future JBoss 
releases.

Thanks for your help.
Ciao,
Jonathan O'Connor
XCOM Dublin





Stephen Coy [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
06.08.2003 13:31
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] CMP support for blobs broken using Sybase


Hi,

The current JBoss implementation does the following mapping for JDBC 
access:

Types.CLOB, LONGVARCHAR: use set/getCharacterStream
Types.BLOB, LONGVARBINARYuse set/getBinaryStream
Types.BINARY, VARBINARY  use set/getBytes

So, you could try setting the JDBC type to LONGVARBINARY.

I recently said the following to an Oracle user, and I think it applies 
to you as well:

In my opinion (knowing what I know now about EJB entity beans), you 
should not be storing LOBs in your primary entities anyway. Getting the 
LOB data to your client may result in multiple copies of it being 
instantiated in memory - and given the nature of LOBs (they can be BIG 
;-) ), this may be quite expensive and it won't scale very well.

I would either keep the LOB data in separate related tables, or use the 
same table and hide the LOB columns from the CMP engine by mapping the 
table to a couple of views. Then use a business facade style of session 
bean to load the LOB data in whatever fashion you see fit using pure 
JDBC or even the Oracle extensions. It may even be advantageous to load 
it directly from the client side using a business delegate and get full 
and proper advantage of the streaming interfaces.

Use the CMP engine to get yourself up and running quickly (you seem to 
have accomplished that) and then refine it as above and I think your 
application will be much happier.

Regards,

Steve Coy


On Wednesday, August 6, 2003, at 12:36  AM, Jonathan.O'[EMAIL PROTECTED] 
wrote:

 Further migration problems have reared their head. The Sybase JDBC 
 driver
 throws an exception when I try to write a blob using CMP. It complains
 that SQL Type 1004 is not supported. This is SqlType.BLOB.

 On talking to colleagues who have written JDBC code for sybase and 
 blobs,
 I have been told that we should use SqlType.BINARY and call
 PreparedStatement.setBinaryStream() instead of setBytes().
 Whatever, I would like to hear of anybody out there who is using JBoss
 (We're on 3.0.6) and Sybase 12.0 to write blobs (IMAGE in Sybase SQL).

 Finally, here's the stack trace:
 13:14:31,918 ERROR [Dispute] Could not create entity
 java.sql.SQLException: JZ006: Caught IOException: java.io.IOException:
 JZ0SL: Unsupported SQL type 2004.
 at
 com.sybase.jdbc2.jdbc.ErrorMessage.raiseError(ErrorMessage.java:526)
 at
 com.sybase.jdbc2.jdbc.ErrorMessage.raiseErrorCheckDead(ErrorMessage.jav 
 a:762)
 at com.sybase.jdbc2.tds.Tds.handleIOE(Tds.java:3160)
 at com.sybase.jdbc2.tds.Tds.language(Tds.java:702)
 at
 com.sybase.jdbc2.jdbc.SybStatement.sendQuery(SybStatement.java:1451)
 at
 com.sybase.jdbc2.jdbc.SybPreparedStatement.sendQuery(SybPreparedStateme 
 nt.java:1168)
 at
 com.sybase.jdbc2.jdbc.SybStatement.executeUpdate(SybStatement.java:1621 
 )
 at
 com.sybase.jdbc2.jdbc.SybPreparedStatement.executeUpdate(SybPreparedSta 
 tement.java:91)
 at
 org.jboss.resource.adapter.jdbc.local.LocalPreparedStatement.executeUpd 
 ate(LocalPreparedStatement.java:308)
 at
 org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.insertEntity(JDB 
 CCreateEntityCommand.java:196)
 at
 org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.execute(JDBCCrea 
 teEntityCommand.java:131)
 at
 org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.createEntity(JDBCStoreM 
 anager.java:527)
 at
 org.jboss.ejb.plugins.CMPPersistenceManager.createEntity(CMPPersistence 
 Manager.java:253)
 at
 org.jboss.resource.connectionmanager.CachedConnectionInterceptor.create 
 Entity(CachedConnectionInterceptor.jav
 a:270)
 at
 org.jboss.ejb.EntityContainer.createLocalHome(EntityContainer.java:580)
 at sun.reflect.GeneratedMethodAccessor40.invoke(Unknown Source)
 at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccesso 
 rImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:324)
 at
 org.jboss.ejb.EntityContainer$ContainerInterceptor.invokeHome(EntityCon 
 tainer.java:1119)
 at
 org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractIntercepto 
 r.java:73)
 at
 org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invokeHome(Entit 
 ySynchronizationInterceptor.java:207

[JBoss-user] JBoss Error in generated SQL for finder (Sybase restriction)

2003-08-07 Thread Jonathan . O'Connor
)
at 
org.jboss.ejb.plugins.local.BaseLocalContainerInvoker.invokeHome(BaseLocalContainerInvoker.java:230)
at 
org.jboss.ejb.plugins.local.LocalHomeProxy.invoke(LocalHomeProxy.java:110)
at $Proxy115.findCardsForPersonAndAccounts(Unknown Source)
at 
xcom.traxbahn.bproc.tasks.CardBcTasks.findCardsForPersonAndAccounts(CardBcTasks.java:318)
at 
xcom.traxbahn.bproc.ejb.PersonAddressBcBean.getAddressCompositeDTOsForPerson(PersonAddressBcBean.java:511)
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.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:660)
at 
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)
at 
org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.java:77)
at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:107)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:228)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:92)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
at 
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:204)
at 
org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.java:313)
at org.jboss.ejb.Container.invoke(Container.java:712)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
at 
org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:382)
at sun.reflect.GeneratedMethodAccessor34.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at 
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at 
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at 
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:536)
Ciao,
Jonathan O'Connor
XCOM Dublin


---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Sybase type-mapping of NUMERIC(10,7) read in as int

2003-08-06 Thread Jonathan . O'Connor
Alex,
Woops, maybe I misled people. JBoss does not fall over when writing out 
the real, so of course, there's no stack trace.
The Entity bean getter method looks like:
/**
 * Returns the FX fee percentage as a scaled decimal
 *
 * @return the fx fee percentage
 *
 * @ejb.interface-method view-type=local 
 * @ejb.persistence column-name=FX_FEE_PERCENT
 */
public abstract BigDecimal getFxFeePercentage();

I've tried changing the DB column type from NUMERIC(10,7) to REAL, but 
that had no effect, so I guess the problem is on the java side. Its either 
the JDBC driver or the mapping code in JBoss.

Tell me, when is the mapping stuff in standardjbosscmp-jdbc.xml used? For 
Sybase, there's no mapping with a java type of BigDecimal. Is that where 
the problem lies?
Ciao,
Jonathan O'Connor
XCOM Dublin





Alexey Loubyansky [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
02.08.2003 14:26
Please respond to jboss-user

 
To: Jonathan.O'[EMAIL PROTECTED] [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Sybase type-mapping of NUMERIC(10,7) read in 
as int


Hello Jonathan,

any stacktrace?

alex

Friday, August 01, 2003, 6:33:12 PM, Jonathan O'Connor wrote:

JOCxd Hi,
JOCxd I'm using JBoss 3.0.6, and I'm migrating from Oracle 9i to Sybase 
12.0
JOCxd One of my unit tests is failing because I have a column in a table 
defined 
JOCxd as NUMERIC(10,7). When I write a value like 1.24, the DB gets 1.

JOCxd Has anyone got any ideas? I tried adding in a mapping to 
jbossjdbccmp.xml 
JOCxd for java.math.BigDecimal but that's no help.
JOCxd Ciao,
JOCxd Jonathan O'Connor
JOCxd Development Manager
JOCxd XCOM Dublin
JOCxd Phone: +353 1 872 3305
JOCxd Mobile: +353 86 824 9736


JOCxd ---
JOCxd This SF.Net email sponsored by: Free pre-built ASP.NET sites 
including
JOCxd Data Reports, E-commerce, Portals, and Forums are available now.
JOCxd Download today and enter to win an XBOX or Visual Studio .NET.
JOCxd http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
JOCxd ___
JOCxd JBoss-user mailing list
JOCxd [EMAIL PROTECTED]
JOCxd https://lists.sourceforge.net/lists/listinfo/jboss-user



---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] CMP support for blobs broken using Sybase

2003-08-05 Thread Jonathan . O'Connor
)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:92)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
at 
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:204)
at 
org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.java:313)
at org.jboss.ejb.Container.invoke(Container.java:712)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
at 
org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:382)
at sun.reflect.GeneratedMethodAccessor38.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at 
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at 
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at 
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:536)
13:14:31,928 ERROR [STDERR] com.sybase.jdbc2.jdbc.SybSQLException: A wrong 
datastream has been sent to the server. The s
erver was expecting token 236 but got the token 33. This is an internal 
error.
13:14:31,928 ERROR [STDERR] at 
com.sybase.jdbc2.tds.Tds.processEed(Tds.java:2672)
13:14:31,928 ERROR [STDERR] at 
com.sybase.jdbc2.tds.Tds.nextResult(Tds.java:2032)
13:14:31,928 ERROR [STDERR] at 
com.sybase.jdbc2.tds.Tds.doCommand(Tds.java:2718)
13:14:31,928 ERROR [STDERR] at 
com.sybase.jdbc2.tds.Tds.endTransaction(Tds.java:1586)
13:14:31,928 ERROR [STDERR] at 
com.sybase.jdbc2.jdbc.SybConnection.rollback(SybConnection.java:840)
13:14:31,928 ERROR [STDERR] at 
org.jboss.resource.adapter.jdbc.local.LocalManagedConnection.rollback(LocalManagedCon
nection.java:282)
13:14:31,928 ERROR [STDERR] at 
org.jboss.resource.connectionmanager.LocalTxConnectionManager$LocalConnectionEventLis
tener.rollback(LocalTxConnectionManager.java:658)
13:14:31,928 ERROR [STDERR] at 
org.jboss.tm.TxCapsule.rollbackResources(TxCapsule.java:1779)
13:14:31,928 ERROR [STDERR] at 
org.jboss.tm.TxCapsule.rollback(TxCapsule.java:475)
13:14:31,928 ERROR [STDERR] at 
org.jboss.tm.TransactionImpl.rollback(TransactionImpl.java:83)
13:14:31,928 ERROR [STDERR] at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:241)

13:14:31,928 ERROR [STDERR] at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:92)
13:14:31,928 ERROR [STDERR] at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
13:14:31,928 ERROR [STDERR] at 
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:204)
13:14:31,928 ERROR [STDERR] at 
org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.java:313)
13:14:31,928 ERROR [STDERR] at 
org.jboss.ejb.Container.invoke(Container.java:712)
13:14:31,928 ERROR [STDERR] at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
13:14:31,928 ERROR [STDERR] at 
org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:382)
13:14:31,928 ERROR [STDERR] at 
sun.reflect.GeneratedMethodAccessor38.invoke(Unknown Source)
13:14:31,928 ERROR [STDERR] at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

13:14:31,928 ERROR [STDERR] at 
java.lang.reflect.Method.invoke(Method.java:324)
13:14:31,928 ERROR [STDERR] at 
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
13:14:31,928 ERROR [STDERR] at 
sun.rmi.transport.Transport$1.run(Transport.java:148)
13:14:31,938 ERROR [STDERR] at 
java.security.AccessController.doPrivileged(Native Method)
13:14:31,938 ERROR [STDERR] at 
sun.rmi.transport.Transport.serviceCall(Transport.java:144)
13:14:31,938 ERROR [STDERR] at 
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
13:14:31,938 ERROR [STDERR] at 
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
13:14:31,938 ERROR [STDERR] at java.lang.Thread.run(Thread.java:536)

Ciao,
Jonathan O'Connor
XCOM Dublin



---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Sybase type-mapping of NUMERIC(10,7) read in as int

2003-08-01 Thread Jonathan . O'Connor
Hi,
I'm using JBoss 3.0.6, and I'm migrating from Oracle 9i to Sybase 12.0
One of my unit tests is failing because I have a column in a table defined 
as NUMERIC(10,7). When I write a value like 1.24, the DB gets 1.

Has anyone got any ideas? I tried adding in a mapping to jbossjdbccmp.xml 
for java.math.BigDecimal but that's no help.
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 9736


---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Sybase Error: SET CHAINED occurring in 3.0.6

2003-07-30 Thread Jonathan . O'Connor
Hi,
We are currently migrating our server to Sybase ASE 12.0 and we keep 
getting SET CHAINED messages from the Sybase driver. I know this used to 
happen, and there was even a fix for this problem in 3.0.1RC1 (I have been 
trawling the archives!).

The code that fails gets a connection from JNDI and uses JDBC calls to 
read a table. Sadly, I haven't tried using CMP to do the same thing yet.

Here's the exception stack trace.

2003-07-29 18:08:52,272 71553 ERROR 
[xcom.traxbahn.util.sysconfig.SysConfig] (main:) Exception while reading 
System Configuration parameters from the database: SET CHAINED command not 
allowed within multi-statement transaction.

com.sybase.jdbc2.jdbc.SybSQLException: SET CHAINED command not allowed 
within multi-statement transaction.

at com.sybase.jdbc2.tds.Tds.processEed(Tds.java:2672)
at com.sybase.jdbc2.tds.Tds.nextResult(Tds.java:2032)
at 
com.sybase.jdbc2.jdbc.ResultGetter.nextResult(ResultGetter.java:69)
at 
com.sybase.jdbc2.jdbc.SybStatement.nextResult(SybStatement.java:204)
at 
com.sybase.jdbc2.jdbc.SybStatement.nextResult(SybStatement.java:187)
at 
com.sybase.jdbc2.jdbc.SybStatement.updateLoop(SybStatement.java:1642)
at 
com.sybase.jdbc2.jdbc.SybStatement.executeUpdate(SybStatement.java:1625)
at 
com.sybase.jdbc2.jdbc.SybPreparedStatement.executeUpdate(SybPreparedStatement.java:91)
at com.sybase.jdbc2.tds.Tds.setOption(Tds.java:)
at 
com.sybase.jdbc2.jdbc.SybConnection.setAutoCommit(SybConnection.java:769)
at 
org.jboss.resource.adapter.jdbc.local.LocalManagedConnection.checkTransaction(LocalManagedConnection.java:432)
at 
org.jboss.resource.adapter.jdbc.local.LocalConnection.checkTransaction(LocalConnection.java:756)
at 
org.jboss.resource.adapter.jdbc.local.LocalStatement.checkTransaction(LocalStatement.java:771)
at 
org.jboss.resource.adapter.jdbc.local.LocalPreparedStatement.executeQuery(LocalPreparedStatement.java:286)
at 
xcom.traxbahn.util.sysconfig.SysConfig.getConfigDataFromDb(SysConfig.java:146)
at 
xcom.traxbahn.util.sysconfig.SysConfig.refresh(SysConfig.java:48)
at 
xcom.traxbahn.util.sysconfig.SysConfig.clinit(SysConfig.java:39)
at 
xcom.traxbahn.util.issuer.IssuerManager.loadIssuers(IssuerManager.java:32)
at 
xcom.traxbahn.system.TraxbahnManagement.refreshIssuers(TraxbahnManagement.java:51)
at 
xcom.traxbahn.system.TraxbahnManagement.startService(TraxbahnManagement.java:77)
at 
org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:165)
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 9736


---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Sybase Error: SET CHAINED occurring in 3.0.6

2003-07-30 Thread Jonathan . O'Connor
I found a workaround. The Sybase DB must be accessed within a transaction. 
So, I moved my code into a session bean method, marked as transaction 
required, and whoopee-do, it works.

Oracle, (which seems much nicer) is not as fussy, and starts a transaction 
for you if you forgot. I guess the fix from 3.0.1RC1 did actually stay in 
the code in 3.0.6
Ciao,
Jonathan O'Connor
XCOM Dublin





Jonathan.O'[EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
30.07.2003 10:44
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Sybase Error: SET CHAINED occurring in 3.0.6


Hi,
We are currently migrating our server to Sybase ASE 12.0 and we keep 
getting SET CHAINED messages from the Sybase driver. I know this used to 
happen, and there was even a fix for this problem in 3.0.1RC1 (I have been 

trawling the archives!).

The code that fails gets a connection from JNDI and uses JDBC calls to 
read a table. Sadly, I haven't tried using CMP to do the same thing yet.

Here's the exception stack trace.

2003-07-29 18:08:52,272 71553 ERROR 
[xcom.traxbahn.util.sysconfig.SysConfig] (main:) Exception while reading 
System Configuration parameters from the database: SET CHAINED command not 

allowed within multi-statement transaction.

com.sybase.jdbc2.jdbc.SybSQLException: SET CHAINED command not allowed 
within multi-statement transaction.

at com.sybase.jdbc2.tds.Tds.processEed(Tds.java:2672)
at com.sybase.jdbc2.tds.Tds.nextResult(Tds.java:2032)
at 
com.sybase.jdbc2.jdbc.ResultGetter.nextResult(ResultGetter.java:69)
at 
com.sybase.jdbc2.jdbc.SybStatement.nextResult(SybStatement.java:204)
at 
com.sybase.jdbc2.jdbc.SybStatement.nextResult(SybStatement.java:187)
at 
com.sybase.jdbc2.jdbc.SybStatement.updateLoop(SybStatement.java:1642)
at 
com.sybase.jdbc2.jdbc.SybStatement.executeUpdate(SybStatement.java:1625)
at 
com.sybase.jdbc2.jdbc.SybPreparedStatement.executeUpdate(SybPreparedStatement.java:91)
at com.sybase.jdbc2.tds.Tds.setOption(Tds.java:)
at 
com.sybase.jdbc2.jdbc.SybConnection.setAutoCommit(SybConnection.java:769)
at 
org.jboss.resource.adapter.jdbc.local.LocalManagedConnection.checkTransaction(LocalManagedConnection.java:432)
at 
org.jboss.resource.adapter.jdbc.local.LocalConnection.checkTransaction(LocalConnection.java:756)
at 
org.jboss.resource.adapter.jdbc.local.LocalStatement.checkTransaction(LocalStatement.java:771)
at 
org.jboss.resource.adapter.jdbc.local.LocalPreparedStatement.executeQuery(LocalPreparedStatement.java:286)
at 
xcom.traxbahn.util.sysconfig.SysConfig.getConfigDataFromDb(SysConfig.java:146)
at 
xcom.traxbahn.util.sysconfig.SysConfig.refresh(SysConfig.java:48)
at 
xcom.traxbahn.util.sysconfig.SysConfig.clinit(SysConfig.java:39)
at 
xcom.traxbahn.util.issuer.IssuerManager.loadIssuers(IssuerManager.java:32)
at 
xcom.traxbahn.system.TraxbahnManagement.refreshIssuers(TraxbahnManagement.java:51)
at 
xcom.traxbahn.system.TraxbahnManagement.startService(TraxbahnManagement.java:77)
at 
org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:165)
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 9736


---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: AW: [JBoss-user] what if no beans are found by a finder ?

2003-07-28 Thread Jonathan . O'Connor
Further clarification:
I thought that if you specify DISTINCT in the EJBQL query then the system 
creates a Set underneath, but returns it as a Collection. This, of course, 
is fine as Set extends/implements Collection.
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 9736




Alexey Loubyansky [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
28.07.2003 09:27
Please respond to jboss-user

 
To: Janardhan Burugupalli [EMAIL PROTECTED]
cc: 
Subject:Re: AW: [JBoss-user] what if no beans are found by a finder ?


Hello Janardhan,

you're right, Set is not allowed as the return type for a finder.
Sorry for confusion.

alex

Monday, July 28, 2003, 10:47:14 AM, Janardhan Burugupalli wrote:

JB one short question regarding the return type Collection or Set..

JB I thought a finder always returns a Collection or atleast the default
JB finders. Or is there a way to make it return a Set. If yes, then is 
there a
JB performance gain between the two return types..and we extensivley use
JB iterators over these returned Colelctions. But i read some were that 
there
JB is some performance difference iterating over Collection, Map, 
Set...can u
JB just take few mins to eloborate..these things

JB regards
JB jani

JB -Ursprungliche Nachricht-
JB Von: [EMAIL PROTECTED]
JB [mailto:[EMAIL PROTECTED] Auftrag von Alexey
JB Loubyansky
JB Gesendet: Montag, 28. Juli 2003 08:00
JB An: Ionel Gardais
JB Betreff: Re: [JBoss-user] what if no beans are found by a finder ?


JB Hello Ionel,

JB if finder's return type is a local interface then if the entity is not
JB found, FinderException is thrown.
JB If finder's return type is Collection or Set then if no entity is
JB found an empty Collection or Set is returned (w/o exception).

JB alex

JB Friday, July 25, 2003, 4:53:08 PM, Ionel Gardais wrote:

IG Hi,

IG What happens if a finder doesn't find any beans matching its query ?
IG Does a FinderException is thrown or does a null value is returned ?

IG Thanks,
IG Ionel



IG ---
IG This SF.Net email sponsored by: Free pre-built ASP.NET sites 
including
IG Data Reports, E-commerce, Portals, and Forums are available now.
IG Download today and enter to win an XBOX or Visual Studio .NET.
IG
JB http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
IG ___
IG JBoss-user mailing list
IG [EMAIL PROTECTED]
IG https://lists.sourceforge.net/lists/listinfo/jboss-user



JB ---
JB This SF.Net email sponsored by: Free pre-built ASP.NET sites including
JB Data Reports, E-commerce, Portals, and Forums are available now.
JB Download today and enter to win an XBOX or Visual Studio .NET.
JB http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
JB ___
JB JBoss-user mailing list
JB [EMAIL PROTECTED]
JB https://lists.sourceforge.net/lists/listinfo/jboss-user



JB ---
JB This SF.Net email sponsored by: Free pre-built ASP.NET sites including
JB Data Reports, E-commerce, Portals, and Forums are available now.
JB Download today and enter to win an XBOX or Visual Studio .NET.
JB http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
JB ___
JB JBoss-user mailing list
JB [EMAIL PROTECTED]
JB https://lists.sourceforge.net/lists/listinfo/jboss-user



---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] Tricky problem with Transaction type Required and RequiresNew

2003-06-25 Thread Jonathan . O'Connor
Hi,
I have a stateless session bean marked as transaction required that was 
locking. Here's what it did:
/**
 * @ejb.transaction type=Required
*/
public void runAuditedTask() {
try {
auditor.doStart(); // Transaction RequiresNew
slsb1.doSomething(); // Transaction Required
slsb2.doSomethingElse(); // Transaction Required
auditor.doEnd(); // Transaction RequiresNew
} catch (Exception e) {
auditor.doAbort(e); // Transaction RequiresNew
}
}

The idea is that even if slsbx.doSomething is rolled back, we still can 
record this action in the database.

Sadly, my method comes to an abrupt halt when it tries to run 
auditor.doEnd(). The slightly altered Stack Trace follows at the end of 
the message.
My workaround is to mark runAuditedTask with transaction type = Never. 
But is there a better solution, and why should this block?

2003-06-25 11:30:40,391 WARN  [org.jboss.tm.TxCapsule] Transaction XidImpl 
[FormatId=257, GlobalId=XCOM-IRL-JONATHAN//22, BranchQual=] timed out. 
status=STATUS_ACTIVE
2003-06-25 11:30:41,703 WARN  [org.jboss.tm.TxCapsule] Transaction XidImpl 
[FormatId=257, GlobalId=XCOM-IRL-JONATHAN//24, BranchQual=] timed out. 
status=STATUS_ACTIVE
2003-06-25 11:30:41,703 WARN  [org.jboss.ejb.BeanLock] wait() interrupted 
in txLock, possibly a timeout
2003-06-25 11:30:41,713 ERROR [org.jboss.ejb.BeanLock] Thread[RMI TCP 
Connection(2)-10.100.1.22,5,RMI Runtime]Saw rolled back 
tx=TransactionImpl:XidImpl [FormatId=257, GlobalId=XCOM-IRL-JONATHAN//24, 
BranchQual=] waiting for txLock
2003-06-25 11:30:41,723 ERROR [org.jboss.ejb.plugins.LogInterceptor] 
TransactionRolledbackLocalException, causedBy:
java.lang.RuntimeException: Transaction marked for rollback, possibly a 
timeout
at 
org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.waitForTx(QueuedPessimisticEJBLock.java:339)
at 
org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.doSchedule(QueuedPessimisticEJBLock.java:211)
at 
org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.schedule(QueuedPessimisticEJBLock.java:159)
at 
org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:103)
at 
org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreationInterceptor.java:69)
at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:107)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:228)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:92)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
at 
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:204)
at org.jboss.ejb.EntityContainer.invoke(EntityContainer.java:493)
at 
org.jboss.ejb.plugins.local.BaseLocalContainerInvoker.invoke(BaseLocalContainerInvoker.java:301)
at 
org.jboss.ejb.plugins.local.EntityProxy.invoke(EntityProxy.java:38)
at $Proxy224.setToCompleted(Unknown Source)
at xcom.traxbahn.bproc.ejb.AuditorBean.doEnd(AuditorBean.java:121)
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.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:660)
at 
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)
at 
org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.java:77)
at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:107)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:305)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:92)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
at 
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:204)
at 
org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.java:313)
at 
org.jboss.ejb.plugins.local.BaseLocalContainerInvoker.invoke(BaseLocalContainerInvoker.java:301)
at 
org.jboss.ejb.plugins.local.StatelessSessionProxy.invoke(StatelessSessionProxy.java:81)
at $Proxy223.setToCompleted(Unknown Source)
at 
de.xcom.tips.xcombs.ejb.BsToTipsBean.runAuditedTask(BsToTipsBean.java:188)
Ciao,
Jonathan O'Connor
XCOM Dublin


---
This SF.Net email is sponsored by: INetU
Attention Web Developers  Consultants: Become An INetU Hosting Partner.
Refer Dedicated Servers. We Manage

Re: [JBoss-user] Using java.util.Calendar with CMP

2003-06-11 Thread Jonathan . O'Connor
Colin,
The error message is pretty clear. It says it can't convert a Calendar 
object into a SQL type. So, you need to do this for it.
What I would do is make a private CMP field (setter and getter) storing a 
long in the DB. This long should be the cal.getTime().getTime().
You should provide a public getter and setter, which call the private 
version. Something like:

public abstract long getPrivateTime();
public abstract void setPrivateTime(long timeInMilliseconds);

public Calendar getTime() {
long t = getPrivateTime();
return new Calendar( new Date( t ));
}

public void setTime( Calendar cal) {
setPrivateTime( cal.getTime().getTime());
}

You'll need to set up the XDoclet tags appropriately. Just don't export 
the privateTime stuff to the local interface class.
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Colin McFarlane [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
11.06.2003 09:34
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Using java.util.Calendar with CMP


I seem to be unable to use a CMP bean that has persistent fields of type 
java.util.Calendar with a mySQL database. (I am using XDoclet to generate 
the bean). I can create the bean class and deploy it okay and the table is 
created with the correct SQL columns. But when I try to create an instance 
of the bean I get a ClassCastException (see below). I can use a 
java.util.Date okay but I'm trying to integrate the bean with an Axis 
service which requires Calendar not Date. 

I converted the fields to dates and tried to create extra methods in the 
bean that take/return a calendar object and set/get the date fields but 
this causes the value objects to fail at compilation as the data object 
doesn't contain all the methods. Besides I would prefer not to have an 
extra layer converting between date  calendar.


Does anyone have any suggestions?

2003-06-08 13:05:14,795 ERROR [org.jboss.ejb.plugins.LogInterceptor] 
EJBException, causedBy:
javax.ejb.CreateException: Could not create entity:javax.ejb.EJBException: 
Internal error setting parameters for field test; CausedByException is:
Cannot convert class java.util.GregorianCalendar to SQL type requested due 
to java.lang.ClassCastException - null
at 
org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractVendorCreateCommand.insertEntity(JDBCAbstractVendorCreateCommand.java:136)
at 
org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractVendorCreateCommand.execute(JDBCAbstractVendorCreateCommand.java:76)
at 
org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.createEntity(JDBCStoreManager.java:569)
at 
org.jboss.ejb.plugins.CMPPersistenceManager.createEntity(CMPPersistenceManager.java:225)
at 
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.createEntity(CachedConnectionInterceptor.java:270)
at org.jboss.ejb.EntityContainer.createLocalHome(EntityContainer.java:571)
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.invokeHome(EntityContainer.java:998)
at 
org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java:88)
at 
org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invokeHome(EntitySynchronizationInterceptor.java:188)
at 
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invokeHome(CachedConnectionInterceptor.java:215)
at 
org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java:88)
at 
org.jboss.ejb.plugins.EntityInstanceInterceptor.invokeHome(EntityInstanceInterceptor.java:91)
at 
org.jboss.ejb.plugins.EntityLockInterceptor.invokeHome(EntityLockInterceptor.java:61)
at 
org.jboss.ejb.plugins.EntityCreationInterceptor.invokeHome(EntityCreationInterceptor.java:28)
at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:88)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:243)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:74)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.java:92)
at 
org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:120)
at 
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invokeHome(ProxyFactoryFinderInterceptor.java:93)
at 
org.jboss.ejb.EntityContainer.internalInvokeHome(EntityContainer.java:477)
at org.jboss.ejb.Container.invoke(Container.java:694)
at 
org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invokeHome(BaseLocalProxyFactory.java:272)
at 
org.jboss.ejb.plugins.local.LocalHomeProxy.invoke(LocalHomeProxy.java:110)
at $Proxy40.create(Unknown Source)
at com.incito.mirror.ejb.TicketMasterBean.issue(TicketMasterBean.java:100

Re: [JBoss-user] problem with DuplicateClass and LocaleBUndle

2003-06-09 Thread Jonathan . O'Connor
Jani,
Since (I think) about JBoss 3.0.5 there has been a new class loader 
mechanism. The benefits are that by default all JARs share the same class 
loader. For much more than I can explain or understand, check the 
documentation:
http://prdownloads.sourceforge.net/jboss/ClassLoading.pdf?download

This also explains how to fix your problem.
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




[EMAIL PROTECTED] (Janardhan Burugupalli)
Sent by: [EMAIL PROTECTED]
09.06.2003 10:32
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] problem with DuplicateClass and LocaleBUndle


hi All,

Does any one have a solution for this problem

I am bundling the LocaleBundle.properties files in two jar files 
NetServer.jar and WorkServer.jar
and deploying it in the Jboss-tomcat-3.2.1.everything works fine 
except for if there are some duplicate classes in the two jar files 
but why does it look in to the other jar files ...like NetServer and 
WorkServer should be two different contexts and it does not bother if 
there are same classes in both these jar files.as it was doing in the 
earlier Jboss versions. 

The problem with LocaleBundle.properties is both are exisiting with the 
same name in the above said jar fiels and i am using ResourceBundle to 
locate them ...but it could not find these filesbut it was working 
fine with the Jboss-2.2.2 version and i dont know why it is not working 
with the new Jboss-Tomcat-3.2.1 version

can any one help me regarding this  i tried a lot but failed to solve this 
.
Java version used is - jdk-1.3.1_04

regards
jani

Mauricio De Diana wrote:
I had the same error when I had a deployed ear with
another name but the same classes.

Regards,
Mauricio

 --- Janardhan Burugupalli [EMAIL PROTECTED]
escreveu:  HI guys,
 
I get the java.lang.ClassCastException: $Proxy320
exception when i 
deploy the jar file while the jboss is running
that is the hot 
deploy...and then if i again try to get the Home
interface it gives the 
above exception on JBoss-tomcat-3.2.1

can any one explain this

regards
jani




 
---
 
This SF.net email is sponsored by:  Etnus, makers of
TotalView, The best
thread debugger on the planet. Designed with thread
debugging features
you've never dreamed of, try TotalView 6 free at
www.etnus.com.
___
JBoss-user mailing list
[EMAIL PROTECTED]

 
https://lists.sourceforge.net/lists/listinfo/jboss-user 

___
Yahoo! Mail
Mais espaço, mais segurança e gratuito: caixa postal de 6MB, antivírus, 
proteção contra spam.
http://br.mail.yahoo.com/


---
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


 





---
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] auth login config file from JSP

2003-04-02 Thread Jonathan . O'Connor
Ionel,
We came across the same bug. Of course, it was our own fault. The problem 
is that you only get a principal if the page from where you are calling is 
specified as a secured page. So, even if the user has logged in correctly, 
if they move to a public page (one which has no security context) then 
your principal is gone. Of course, if they go back to a secured page, 
their principal comes back.

HTH,
Jonathan O'Connor
Development Manager
XCOM Dublin




Ionel Gardais [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
02.04.2003 10:17
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] auth login config file from JSP


Thanks Scott,

I am still having principal=null exception but they are no more related 
to the UsersRolesLoginModule.
I think i'm on the way to get it working.

As the username/role are retrieve in a database, is it a good thing to do 
:

application-policy name = scheduler
   authentication
  login-module code = org.jboss.security.ClientLoginModule
 flag = required
  /login-module

  login-module code = 
org.jboss.security.auth.spi.DatabaseServerLoginModule
 flag = required
 module-option name=dsJndiNamejava:/PasswordDS/module-option
 module-option name=principalsQueryselect Password from 
Principals where PrincipalID=?/module-option
 module-option name=rolesQueryselect Role, RoleGroup from 
Roles where PrincipalID=?/module-option
  /login-module
   /authentication
/application-policy

so my app, either a standalone or a web app must first use the 
ClientLoginModule and then use the DatabaseServerLoginModule ? (by 
specifying security-domain = java:/jaas/scheduler on jboss.xml and 
jboss-web.xml)

BTW, two little questions :
- my app is designed to use a singleton that act as an proxy for the 
SLSB home and remote interfaces. Is it possible that when a client uses 
the singleton, the calls are made using the client loginContext ?

CLIENT #1 --\ /--- CMP #1
   |- loginContext   \   /
  (owned by C#1)  +-- Interface PROXY /  /--- SLSB--+- CMP #2
 /   \
CLIENT #2 --/ \--- CMP #3
   |- loginContext
  (owned by C#2


- is there a NISLoginModule as there is an LDAPLoginModule ?



thanks,
ionel



---
This SF.net email is sponsored by: ValueWeb: 
Dedicated Hosting for just $79/mo with 500 GB of bandwidth! 
No other company gives more support or power for your dedicated server
http://click.atdmt.com/AFF/go/sdnxxaff00300020aff/direct/01/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.net email is sponsored by: ValueWeb: 
Dedicated Hosting for just $79/mo with 500 GB of bandwidth! 
No other company gives more support or power for your dedicated server
http://click.atdmt.com/AFF/go/sdnxxaff00300020aff/direct/01/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Latest CVS version

2003-03-25 Thread Jonathan . O'Connor
Simone,
I cut this line out of the SourceForge help pages:
cvs -d:pserver:[EMAIL PROTECTED]:80/cvsroot/jboss

try reading 
https://sourceforge.net/docman/display_doc.php?docid=14033group_id=1#repositorymirroring
 
for more info.
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Simone Milani [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
25.03.2003 16:19
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Latest CVS version


I tried using cygwin but again no luck.  Here is what I did.

/home/personal$
CVSROOT=:pserver:[EMAIL PROTECTED]:/cvsroot/jbo
ss
/home/personal$ cvs -z3 checkout -r Branch_3_2 jboss-3.2
cvs.exe [checkout aborted]: connect to
cvs-ssh.sourceforge.net(66.35.250.212):24
01 failed: Connection timed out
/home/personal$ CVS_RSH=ssh
/home/personal$ cvs -z3 checkout -r Branch_3_2 jboss-3.2
cvs.exe [checkout aborted]: connect to
cvs-ssh.sourceforge.net(66.35.250.212):24
01 failed: Connection timed out

Could you please tell how you did it?

Thanks


Simone

- Original Message -
From: Rupp,Heiko [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, March 25, 2003 1:11 PM
Subject: RE: [JBoss-user] Latest CVS version


 Hi Simone,

  Thanks, I am trying to setup an SSH tunnell on my NT
  machine to use with
  CVS but no luck.  Did you ever managed to do it?

 If you use anonymous access, you don't need to, as this
 is a non-encrypted connection. The trick here is to use
 a port that is normally open in the firewall for outgoing
 connections like e.g. https.
 I did try it once, but this failed and I did not look into
 it since.

 On my win2k box, I use cygwin including openssh to connect
 over normal cvs + ssh to sourceforge, which works.

 Tell me if you have success.

   Heiko
 --
 Bancotec GmbH  EMail: [EMAIL PROTECTED]
 Calwer Str. 33 Telefon: +49 711 222 992 900
 D-70173 Stuttgart  Telefax: +49 711 222 992 999
 Ein Unternehmen der Cellent AG http://www.cellent.de/


 ---
 This SF.net email is sponsored by:
 The Definitive IT and Networking Event. Be There!
 NetWorld+Interop Las Vegas 2003 -- Register today!
 http://ads.sourceforge.net/cgi-bin/redirect.pl?keyn0001en
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user



---
This SF.net email is sponsored by:
The Definitive IT and Networking Event. Be There!
NetWorld+Interop Las Vegas 2003 -- Register today!
http://ads.sourceforge.net/cgi-bin/redirect.pl?keyn0001en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.net email is sponsored by:
The Definitive IT and Networking Event. Be There!
NetWorld+Interop Las Vegas 2003 -- Register today!
http://ads.sourceforge.net/cgi-bin/redirect.pl?keyn0001en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] CMR with FK in the database

2003-03-24 Thread Jonathan . O'Connor

Simone,
Look for previous messages about INSERT after ejbPostCreate.
If you use oracle you can also mark the NON NULL constraint as DEFERRABLE INITIALLY DEFERRED. However, lots of DBAs don't like this.
Ciao,
Jonathan O'Connor







Simone Milani [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
24.03.2003 10:43
Please respond to jboss-user


To:[EMAIL PROTECTED]
cc:
Subject:[JBoss-user] CMR with FK in the database


Hi,

  I have a one to many relation with a FK constaint and the FK in the children declared as non nullable. The SQL that is generated by JBoss seems to violate this constraint.

Please help!!!


Thanks

Simone



Re: Re[4]: [JBoss-user] CMR with FK in the database

2003-03-24 Thread Jonathan . O'Connor

Alex,
Presumably, in ejbCreate() I have to call setFkAsCmpField(fkObj.getKey()), and then I don't need to call setFkAsCmrField( fkObj ) in ejbPostCreate().
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736






Alex Loubyansky [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
24.03.2003 15:52
Please respond to jboss-user


To:Simone Milani [EMAIL PROTECTED]
cc:
Subject:Re[4]: [JBoss-user] CMR with FK in the database


Hello Simone,

actually, it looks like exposing FK field[s] as non-null CMP field[s].
Just map FK fields to CMP fields in jbosscmp-jdbc.xml.

NOTE: there is currently a bug (stack overflow on loading) in FK fields map to CMP columns.
I can't commit changes to CVS the whole day. I hope Dain will help
help me and today it'll be fixed in CVS.

alex

Monday, March 24, 2003, 3:45:54 PM, Simone Milani wrote:

SM Hi Alex,

SM   Thanks! Do I have to expose the FK field in my ChildBean? Could you
SM provide an example?

SM Thanks

SM Simone
SM - Original Message -
SM From: Alex Loubyansky [EMAIL PROTECTED]
SM To: Jonathan.O'[EMAIL PROTECTED] [EMAIL PROTECTED]
SM Sent: Monday, March 24, 2003 12:06 PM
SM Subject: Re[2]: [JBoss-user] CMR with FK in the database


 JBoss-3.2 now supports NON-NULL foreig keys if foreign key fields are
 mapped to NON NULL CMP fields.

 alex

 Monday, March 24, 2003, 1:50:17 PM, Jonathan O'Connor wrote:

 JOCxd Simone,
 JOCxd Look for previous messages about INSERT after ejbPostCreate.
 JOCxd If you use oracle you can also mark the NON NULL constraint as
SM DEFERRABLE
 JOCxd INITIALLY DEFERRED. However, lots of DBAs don't like this.
 JOCxd Ciao,
 JOCxd Jonathan O'Connor





 JOCxd Simone Milani [EMAIL PROTECTED]
 JOCxd Sent by: [EMAIL PROTECTED]
 JOCxd 24.03.2003 10:43
 JOCxd Please respond to jboss-user


 JOCxd To:   [EMAIL PROTECTED]
 JOCxd cc:
 JOCxd Subject:[JBoss-user] CMR with FK in the database


 JOCxd Hi,

 JOCxd   I have a one to many relation with a FK constaint and the FK in
SM the
 JOCxd children declared as non nullable. The SQL that is generated by
SM JBoss
 JOCxd seems to violate this constraint.

 JOCxd Please help!!!


 JOCxd Thanks

 JOCxd Simone




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




Re: [JBoss-user] CMP Entity Bean Insert/Commit after ejbPostCreate()

2003-03-13 Thread Jonathan . O'Connor

Bernhard,
No, JBoss 3.x does the insert after ejbCreate. 4.0 is reputed to have (will have) support for INSERT after ejbPostCreate.

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736






Meyer-Willner, Bernhard [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
13.03.2003 15:09
Please respond to jboss-user


To:JBoss-User (E-Mail) [EMAIL PROTECTED]
cc:
Subject:[JBoss-user] CMP Entity Bean Insert/Commit after ejbPostCreate()


Hi,

does JBoss 3.2 issue INSERT/COMMIT after ejbPostCreate() or is it possible
to configure it this way (you can do this e.g. in WebLogic) ?

As far as I know, all JBoss 3.0.x versions already do an INSERT between
ejbCreate() and ejbPostCreate(). Has this changed in any newer version()?
This is a problem for me, since this means FK columns can't be declared as
NOT NULL since as y'all know CMR fields can only be set in ejbPostCreate().
I don't want to use Deferred Constraints feature some databases offer.


Cheers,
Bernhard


Bernhard Meyer-Willner, MSc
Insurance - Financial Services
_
 
LogicaCMG
Logica GmbH
Osterbekstrasse 90b - Alster City
22083 Hamburg
Germany
T: +49 (0) 40 27071-405 (direct)
M: +49 (0) 177 425-9036
E: mailto:[EMAIL PROTECTED] 
www.logicacmg.com

This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you.


---
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user




[JBoss-user] Neglected JBoss 3.0.5 falls into a coma

2003-03-10 Thread Jonathan . O'Connor
We noticed a worrying feature of JBoss 3.0.4 and 3.0.5 recently. If JBoss 
is started, and then not used for maybe a day or two, it goes into a coma. 
we are running this on Linux, with Java 1.4 JVM. The processes are still 
there, but it won't respond to requests from the web (via Jetty) or client 
applications. If we do a shutdown.sh, and then run.sh again, everything is 
OK.

I realise that most people are trying to ensure their system runs under 
heavy load, but its a bit worrying when the system falls over under no 
load at all!

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] Neglected JBoss 3.0.5 falls into a coma

2003-03-10 Thread Jonathan . O'Connor
Sascha,
You're right. It is very odd. We noted it because we use ITracker (not 
very much obviously :-) We also tried it with our own EAR file. In both 
cases we couldn't get to the main web page for those apps. I must check 
and see if we can get to the JMX-Console.

Lastly, is there a clever way to generate a stacktrace dump? Our JBoss 
server process was started in the background, and then I logged out. Can 
this be done with the JMX-Console? Is there a handy MBean to do this? Is 
that a clever idea or what :-)
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Sacha Labourey [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
10.03.2003 12:52
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] Neglected JBoss 3.0.5 falls into a coma


Hello,

That's interesting. You see that your process cannot be reached and at the
same time you say you kill it by using shutdown.sh which uses ones of 
JBoss
JMX invoker to shut it down if I remember correctly. A stackdump trace is
required to help here though.

Cheers,



 Sacha



 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf Of 
 Jonathan.O'[EMAIL PROTECTED]
 Sent: lundi, 10. mars 2003 12:34
 To: [EMAIL PROTECTED]
 Subject: [JBoss-user] Neglected JBoss 3.0.5 falls into a coma
 
 
 We noticed a worrying feature of JBoss 3.0.4 and 3.0.5 
 recently. If JBoss 
 is started, and then not used for maybe a day or two, it goes 
 into a coma. 
 we are running this on Linux, with Java 1.4 JVM. The 
 processes are still 
 there, but it won't respond to requests from the web (via 
 Jetty) or client 
 applications. If we do a shutdown.sh, and then run.sh again, 
 everything is 
 OK.
 
 I realise that most people are trying to ensure their system 
 runs under 
 heavy load, but its a bit worrying when the system falls over 
 under no 
 load at all!
 
 Ciao,
 Jonathan O'Connor
 Development Manager
 XCOM Dublin
 Phone: +353 1 872 3305
 Mobile: +353 86 824 0736
 
 
 ---
 This sf.net email is sponsored by:ThinkGeek
 Welcome to geek heaven.
 http://thinkgeek.com/sf
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user
 



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] Neglected JBoss 3.0.5 falls into a coma

2003-03-10 Thread Jonathan . O'Connor
Heiko,
Thanks for the tip. Sadly, that only gets me a list of threads. I reckon 
I'll need to write some code to create a stack trace of each thread.

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Rupp,Heiko [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
10.03.2003 15:57
Please respond to jboss-user

 
To: '[EMAIL PROTECTED]' [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] Neglected JBoss 3.0.5 falls into a coma


 Lastly, is there a clever way to generate a stacktrace dump? 
 Our JBoss 
 server process was started in the background, and then I 
 logged out. Can 
 this be done with the JMX-Console? Is there a handy MBean to 

At least there is a topic in the http-version, so I assume you can
do the same over rmi. Look at jboss.system,type=ServerInfo

  Heiko
-- 
Bancotec GmbH  EMail: [EMAIL PROTECTED]
Calwer Str. 33 Telefon: +49 711 222 992 900
D-70173 Stuttgart  Telefax: +49 711 222 992 999
Ein Unternehmen der Cellent AG http://www.cellent.de/


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] HiLo key generator

2003-03-06 Thread Jonathan . O'Connor
Pardon my ignorance, but what is a HiLo key generator? Many years ago, we 
used an incrementing number, but reversed the bits, so that the keys were 
well distributed. Is this the same thing? Should I have patented the idea 
:-) ? Too late I suppose!
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Alex Loubyansky [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
05.03.2003 19:36
Please respond to jboss-user

 
To: JBoss-User [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] HiLo key generator


I just added HiLo key generator to HEAD.
Now, using entity-command configuration, it's possible to create
entities with either known or unknown primary keys using UUID or
HiLo key generators.

Key generator is deployed with *-service.xml. Here is an excerpt from
hilo-service.xml:
   !--
  | HiLoKeyGeneratorFactory
   --
   mbean
 code=org.jboss.ejb.plugins.keygenerator.hilo.HiLoKeyGeneratorFactory
  name=jboss:service=KeyGeneratorFactory,type=HiLo

  attribute 
name=FactoryNamejava:/HiLoKeyGeneratorFactory/attribute
  attribute name=DataSourcejava:/DefaultDS/attribute
  attribute 
name=TransactionManagerjava:/TransactionManager/attribute
  attribute name=TableNameJBOSS_SEQUENCE/attribute
  attribute name=ColumnNameID/attribute
  attribute name=ColumnSQLTypeINTEGER/attribute
  attribute name=BlockSize100/attribute
   /mbean

If the table does not exist at deployment, it is created.
Is there a need to backport it to 3.2 and/or 3.0 versions?

Thanks,
alex




---
This SF.net email is sponsored by: Etnus, makers of TotalView, The 
debugger 
for complex code. Debugging C/C++ programs can leave you feeling lost and 
disoriented. TotalView can help you find your way. Available on major UNIX 

and Linux platforms. Try it free. www.etnus.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.net email is sponsored by: Etnus, makers of TotalView, The debugger 
for complex code. Debugging C/C++ programs can leave you feeling lost and 
disoriented. TotalView can help you find your way. Available on major UNIX 
and Linux platforms. Try it free. www.etnus.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Feature idea

2003-02-28 Thread Jonathan . O'Connor
David,
Two points about this: 
One: you HOPE the application is only down for a minute. You don't know if 
it will deploy properly.
Two: Maybe it could implemented with an interceptor, looking for requests 
to old Web apps. The web app would have to register with the interceptor 
saying it was going down. On deployment, it would unregister with the 
interceptor. However, I have no idea how you could implement it. No doubt, 
its easy enough for some interceptor expert.

Ciao,
Jonathan O'Connor





David Corbin [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
28.02.2003 13:02
Please respond to jboss-user

 
To: JBoss User [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Feature idea


The one thing I'd like to see jboss provide.  When I an application is 
redeployed, I'd like to see JBoss accept requests for the context of the 
application, and return a page that says Please try again in a few 
moments.  Even better would be some way to configure the response.  The 
key point is, that the application is down for a minute, we know that 
it's down for just a bit, we should be able to handle the error better.

David



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] automatic login in JBoss app?

2003-02-27 Thread Jonathan . O'Connor
Have a look at ITracker. You'll find it in SourceForge. It has the feature 
you are looking for.
Ciao,
Jonathan O'Connor





Rod Macpherson [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
27.02.2003 04:54
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] automatic login in JBoss app?


The cookies will be in the request header so if you have access to the
request in the custom login then a call to getCookies otta work fine.

- Original Message -
From: Ken Yee [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, February 26, 2003 7:07 PM
Subject: [JBoss-user] automatic login in JBoss app?



 No luck digging in the archives for this list or on the security
 forum on jboss.org.

 Has anyone done the feature you find in a lot of web sites where
 you can click a checkbox next to your login info and a cookie is
 stored to automatically log you in the next time you visit the
 site?
 Somehow, it would have to hook into the authentication process
 but I can't figure out how to read a browser cookie in a custom login
 module...

  thanks,


  ken


 ___
 Join Excite! - http://www.excite.com
 The most personalized portal on the Web!


 ---
 This SF.net email is sponsored by: Scholarships for Techies!
 Can't afford IT training? All 2003 ictp students receive scholarships.
 Get hands-on training in Microsoft, Cisco, Sun, Linux/UNIX, and more.
 www.ictp.com/training/sourceforge.asp
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user



---
This SF.net email is sponsored by: Scholarships for Techies!
Can't afford IT training? All 2003 ictp students receive scholarships.
Get hands-on training in Microsoft, Cisco, Sun, Linux/UNIX, and more.
www.ictp.com/training/sourceforge.asp
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] Separating a WAR from its EAR

2003-02-21 Thread Jonathan . O'Connor
Rod,
Thanks for that clarification. You are right on all points. We have some 
sneaky initialisation code that runs when the WAR is deployed, and this 
tries to connect to our EAR session beans. I suspect the the EAR file with 
the implementation of the session bean interfaces was not deployed when 
the WAR was deployed. Hence the naming server problems.

What I am glad to hear is that apart from sticking the remote interface 
classes into a JAR in WEB-INF/lib, I should be able to deploy the WAR 
outside the EAR with no other problems.

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Rod Macpherson [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
21.02.2003 17:02
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Separating a WAR from its EAR


The problem he was having was not being able to find EJB interfaces after 
moving the WAR file outside of the EAR. That does not appear to be a bug 
since you would expect to lose visibility in that case. Putting the EJB 
interfaces in a jar file under WEB-INF/lib will solve his problem without 
editing deployment descriptors. I am also using a WAR inside an EAR and 
that works fine and he actually had that working also. 
- Original Message - 
From: Andreas Mecky 
To: [EMAIL PROTECTED] 
Sent: Friday, February 21, 2003 8:14 AM
Subject: Re: [JBoss-user] Separating a WAR from its EAR

Hi Jonathan,
 
I never thought that we'd talk to each other using the jboss mailing list 
:)
 
Make sure you have all jars in your war file that are needed and add the 
web resource
entries to web.xml. Do not forget your ejb class files.
 
We went through this process as well when we deployed our application (an 
ear with a war inside)
on JBoss2.44 and Tomcat3.2.3 or something). Since there is a bug you have 
to deploy this
separately.
 
If you have more questions then you can contact me directly. Just put a 
dot between the first and the lastname
and replace the yahoo.de with our company account.
 
CU
 
Andreas
 
- Original Message - 
From: Jonathan.O'[EMAIL PROTECTED] 
To: [EMAIL PROTECTED] 
Sent: Friday, February 21, 2003 2:18 PM
Subject: [JBoss-user] Separating a WAR from its EAR


Folks, 
We have our front end in a WAR living inside our EAR file. For reasons I 
won't go into here, we thought it might be an idea to take the WAR out of 
the EAR and deploy it separately. 
However, when we try using it, we get JNP errors complaining about not 
finding remote interfaces. 

Do you need to add resoure references in the WAR to get access to the 
Remote interfaces, much like you do for a session bean to access entity 
beans that live in another JAR/EAR? 
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




---
This SF.net email is sponsored by: SlickEdit Inc. Develop an edge.
The most comprehensive and flexible code editor you can use.
Code faster. C/C++, C#, Java, HTML, XML, many more. FREE 30-Day Trial.
www.slickedit.com/sourceforge
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] Hot Deploy (JBOSS 3.2)

2003-02-18 Thread Jonathan . O'Connor
James,
I almost asked the same thing a few days ago, but if you scan the 
archives, you'll find its a known problem with 3.2RC1
BTW, on my PC, my ant script refuses to do the copy, but if I issue a copy 
command by hand, it works fine!

Finally, I believe this is fixed in 3.2RC2. I'll let you know if it 
doesn't work after I've downloaded it.
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Corbin, James [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
17.02.2003 22:02
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] Hot Deploy (JBOSS 3.2)



I am using JBOSS 3.2RC1.  When I rebuild my ear file and copy it to the
deploy directory, it doesn't appear that it is re-deploying the 
application.

J.D.

-Original Message-
From: David Jencks [mailto:[EMAIL PROTECTED]] 
Sent: Monday, February 17, 2003 1:56 PM
To: [EMAIL PROTECTED]
Subject: Re: [JBoss-user] Hot Deploy (JBOSS 3.2)

Which jboss 3.2? I have occasionally seen things not hot deploy, but today
I have been working with jboss 3.2 cvs and the packages I have been 
working
with (.rar and *-ds.xml files) are hot deploying fine.

david jencks


On 2003.02.17 15:03 Corbin, James wrote:
 JBOSS 3.2 doesn't appear to hot-deploy out of the box where JBOSS 2.4.x
 did.
 Is there a server setting that controls this?  When I rebuild my app and
 drop the ear into the deployment directory, it doesn't appear that it is
 deploying the ear.  I am forced to restart the server for my changes to
 be
 in effect.
 
 
 
 J.D.
 
 
 This electronic message transmission contains information from the
 Company that may be proprietary, confidential and/or privileged.
 The information is intended only for the use of the individual(s) or
 entity named above.  If you are not the intended recipient, be
 aware that any disclosure, copying or distribution or use of the 
contents
 of this information is prohibited.  If you have received
 this electronic transmission in error, please notify the sender
 immediately by replying to the address listed in the From: field.
 
 
 html
 
 head
 META HTTP-EQUIV=Content-Type CONTENT=text/html; charset=us-ascii
 
 
 meta name=Generator content=Microsoft Word 10 (filtered)
 
 style
 !--
  /* Style Definitions */
  p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:Times New Roman;}
 a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;}
 a:visited, span.MsoHyperlinkFollowed
{color:purple;
text-decoration:underline;}
 span.EmailStyle17
{font-family:Arial;
color:windowtext;}
 @page Section1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;}
 div.Section1
{page:Section1;}
 --
 /style
 
 /head
 
 body lang=EN-US link=blue vlink=purple
 
 div class=Section1
 
 p class=MsoNormalfont size=2 face=Arialspan 
style='font-size:10.0pt;
 font-family:Arial'JBOSS 3.2 doesn't appear to hot-deploy out of the box
 where JBOSS 2.4.x did.nbsp; Is there a server setting that controls
 this?nbsp; When I
 rebuild my app and drop the ear into the deployment directory, it 
doesn't
 appear that it is deploying the ear.nbsp; I am forced to restart the
 server for my
 changes to be in effect./span/font/p
 
 p class=MsoNormalfont size=2 face=Arialspan 
style='font-size:10.0pt;
 font-family:Arial'nbsp;/span/font/p
 
 p class=MsoNormalfont size=2 face=Arialspan 
style='font-size:10.0pt;
 font-family:Arial'J.D./span/font/p
 
 /div
 
 PRE
 This electronic message transmission contains information from the
 Company that may be proprietary, confidential and/or privileged.
 The information is intended only for the use of the individual(s) or
 entity named above.  If you are not the intended recipient, be
 aware that any disclosure, copying or distribution or use of the 
contents
 of this information is prohibited.  If you have received
 this electronic transmission in error, please notify the sender
 immediately by replying to the address listed in the From: field.
 /PRE
 /body
 
 /html
 
 
 


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user
This electronic message transmission contains information from the Company 
that may be proprietary, confidential and/or privileged.
The information is intended only for the use of the individual(s) or 
entity named above.  If you are not the intended recipient, be
aware that any disclosure, copying or distribution or use of the contents 
of this information is prohibited.  If you have received

Re: [JBoss-user] CMP/BMP Performance

2003-02-18 Thread Jonathan . O'Connor
Jan,
Use CMP2. Write load tests so you can measure performance. Then, you can 
optimise loading by changing the jbosscmp-jdbc.xml files. Look up the 
documentation on it.
Run your tests again. See if you've improved performance. If you don't 
measure performance, you can't tell if what you are doing is fast or slow.

If this is still too slow, you can always write some direct JDBC or use 
BMP.

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




NIELSEN JAN, Teliadk [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
18.02.2003 09:44
Please respond to jboss-user

 
To: '[EMAIL PROTECTED]' [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] CMP/BMP Performance


Hi All,

I'm about to start implementation of a fairly large system, where
performance is a big issure.

Can any one give me a tip on what road I should select. Should I choose 
CMP,
BMP or make a DAO layer where I'm using JDBC?

Hope you can give me a hint :-)


Cheers
Jan









---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] MBean start up code throwing Transaction exception

2003-02-18 Thread Jonathan . O'Connor
)
at java.lang.reflect.Method.invoke(Method.java:324)
at 
org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)
at $Proxy3.deploy(Unknown Source)
at 
org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:435)
at 
org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:561)
at 
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:21
2)
at 
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:225)

at 
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:202)

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Session Bean (Txn Required) commit error not being sentback to the client

2003-02-18 Thread Jonathan . O'Connor
David,
Summary: if commit fails at the end of a session bean method with Txn 
Required, the client caller of this method never receives notification.
In 3.0.5 and earlier, the client returned but did not receive notification 
of the problem.
In 3.2.0RC2, the session bean call never returns to the client! The server 
however is still active and ready for business.

As soon as I get this exception and stack trace, my junit client stops 
processing tests. If I kill the server, the tests continue with the 
expected failures because of no server.
This indicates the server is not returning control to the client!

2003-02-18 13:07:55,079 WARN  [org.jboss.tm.TransactionImpl] XAException: 
tx=TransactionImpl:XidImpl [FormatId=257, GlobalId=XCOM-IRL-JONATHAN//44, 
BranchQual=] errorCode=XA_UNKNOWN(0)
org.jboss.resource.connectionmanager.JBossLocalXAException: could not 
commit local tx; - nested throwable: 
(org.jboss.resource.JBossResourceException: SQLException; - nested 
throwable: (java.sql.SQLException: ORA-02091: transaction rolled back
ORA-02290: check constraint (JOCONNOR.SYS_C0025330) violated
))
at 
org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource.commit(TxConnectionManager.java:787)
at 
org.jboss.tm.TransactionImpl.commitResources(TransactionImpl.java:1580)
at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:366)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.endTransaction(TxInterceptorCMT.java:367)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:253)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:104)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
at 
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:208)
at 
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:154)
at 
org.jboss.ejb.StatelessSessionContainer.internalInvoke(StatelessSessionContainer.java:322)
at org.jboss.ejb.Container.invoke(Container.java:652)
at sun.reflect.GeneratedMethodAccessor88.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at 
org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549)
at 
org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:338)
at sun.reflect.GeneratedMethodAccessor92.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at 
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at 
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at 
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:536)
Caused by: org.jboss.resource.JBossResourceException: SQLException; - 
nested throwable: (java.sql.SQLException: ORA-02091: transaction rolled 
back
ORA-02290: check constraint (JOCONNOR.SYS_C0025330) violated
)
at 
org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.checkException(BaseWrapperManagedConnection.java:449)
at 
org.jboss.resource.adapter.jdbc.local.LocalManagedConnection.commit(LocalManagedConnection.java:95)
at 
org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource.commit(TxConnectionManager.java:778)
... 26 more
Caused by: java.sql.SQLException: ORA-02091: transaction rolled back
ORA-02290: check constraint (JOCONNOR.SYS_C0025330) violated

at 
oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
at oracle.jdbc.oci8.OCIDBAccess.check_error(OCIDBAccess.java:2321)
at oracle.jdbc.oci8.OCIDBAccess.commit(OCIDBAccess.java:665)
at 
oracle.jdbc.driver.OracleConnection.commit(OracleConnection.java:1341)
at 
org.jboss.resource.adapter.jdbc.local.LocalManagedConnection.commit(LocalManagedConnection.java:91)
... 27 more
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Jonathan.O'[EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
12.02.2003 11:04
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Session Bean (Txn Required) commit error not 
being sent 
back to the client


David,
I spent most of yesterday trying to download Branch_3_0, and I'm still not 

finished

Re: [JBoss-user] Session Bean (Txn Required) commit error not being sentback to the client

2003-02-18 Thread Jonathan . O'Connor
David,
It'll take a while, as my main dev machine is a Windows box. I'll get back 
to you when I have an answer, but it'll probably be tomorrow.

Still, having the client stop when we hot one these errors is a good thing 
(at least until we go into production).
Also, the error message is great. If we hit one of these again, it'll take 
a couple of minutes to find the constraint and fix the problem.
Ciao,
Jonathan O'Connor




David Jencks [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
18.02.2003 14:50
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Session Bean (Txn Required) commit error not 
being sent 
back to the client


Can you do a thread dump on the client and server when this happens?  I
didn't see this in the tests I wrote.

(on linux and mac osx, you can get a thread dump with ctrl-\)

thanks
david jencks

On 2003.02.18 09:00 Jonathan.O'[EMAIL PROTECTED] wrote:
 David,
 Summary: if commit fails at the end of a session bean method with Txn 
 Required, the client caller of this method never receives notification.
 In 3.0.5 and earlier, the client returned but did not receive
 notification 
 of the problem.
 In 3.2.0RC2, the session bean call never returns to the client! The
 server 
 however is still active and ready for business.
 
 As soon as I get this exception and stack trace, my junit client stops 
 processing tests. If I kill the server, the tests continue with the 
 expected failures because of no server.
 This indicates the server is not returning control to the client!
 
 2003-02-18 13:07:55,079 WARN  [org.jboss.tm.TransactionImpl] 
XAException:
 
 tx=TransactionImpl:XidImpl [FormatId=257, 
GlobalId=XCOM-IRL-JONATHAN//44,
 
 BranchQual=] errorCode=XA_UNKNOWN(0)
 org.jboss.resource.connectionmanager.JBossLocalXAException: could not 
 commit local tx; - nested throwable: 
 (org.jboss.resource.JBossResourceException: SQLException; - nested 
 throwable: (java.sql.SQLException: ORA-02091: transaction rolled back
 ORA-02290: check constraint (JOCONNOR.SYS_C0025330) violated
 ))
 at 
 
org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource.commit(TxConnectionManager.java:787)
 at 
 org.jboss.tm.TransactionImpl.commitResources(TransactionImpl.java:1580)
 at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:366)




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] JBoss 3.2RC2 only source available

2003-02-17 Thread Jonathan . O'Connor
Folks,
Maybe I'm jumping the gun here, but the 3.2RC2 release only offers source 
code on SourceForge. Is RC2 a temporary release for the likes of myself 
who can't easily access the source in CVS ?
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Main diff between 3.0.x and 3.2

2003-02-13 Thread Jonathan . O'Connor
Bernie,
If you are using Oracle, then mark your NOT NULL fields as DEFERRABLE 
INITIALLY DEFERRED.
Then these constraints are only checked at commit time and not at insert 
time.

If you are using other DBs, check for something similar.
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Meyer-Willner, Bernhard [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
13.02.2003 13:15
Please respond to jboss-user

 
To: JBoss-User (E-Mail) [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Main diff between 3.0.x and 3.2


Hi,

could anybody point out the main differences (architectural and otherwise)
between JBoss releases, say the 3.0.x (3.0.5 and up) series and 3.2 ? I
understand that Release 4 will be major release with big architectural
advances and J2EE 1.4 support etc. etc. But what's the main diff between
3.0.x and 3.2 ? In particular, are there any major advances or compelling
new features that would make upgrading an app to 3.2 from 3.0.5 
worthwhile? 

One point I'm especially interested in is the deferred commit feature
which hasn't been available so far: by deferred commit I mean that for 
CMP
the INSERT statement is committed only after the call to ejbPostCreate()
which would allow to declare an FK column as NOT NULL in the database. 
This
currently doesn't work?

Thanks for any enlightenment in these matters,

Bernie

This e-mail and any attachment is for authorised use by the intended 
recipient(s) only.  It may contain proprietary material, confidential 
information and/or be subject to legal privilege.  It should not be 
copied, disclosed to, retained or used by, any other party.  If you are 
not an intended recipient then please promptly delete this e-mail and any 
attachment and all copies and inform the sender.  Thank you.


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Session Bean (Txn Required) commit error not being sentback to the client

2003-02-12 Thread Jonathan . O'Connor
David,
I spent most of yesterday trying to download Branch_3_0, and I'm still not 
finished. However, this recent spate of emails suggests that its all under 
control. As soon as 3.0.7 is out, or a new version of 3.2, I'll test our 
code and let you know if its been fixed.

Sorry I couldn't help more, but firewalls and sloww internet 
connections don't help much!
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




David Jencks [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
12.02.2003 02:11
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Session Bean (Txn Required) commit error not 
being sent 
back to the client


Dain and I have been working to fix this farther.  He fixed the missing
cause you found.
I've made all these exceptions use Jason's NestedThrowable stuff so they
should print well.

Also, there is an XAExceptionFormatter thing you can do to supply special
formatting to xa exceptions: this works best with an xa driver: in 3.2
there's one for Oracle.

In 3.0 there (will be shortly) one for the XAExceptions generated by
jboss for the wrapped local jdbc drivers.

This should be committed very soon.

david jencks

On 2003.02.11 20:09 Gerald Turner wrote:
 Gerald Turner [EMAIL PROTECTED] writes:
 
  I'll build the latest Branch_3_0 and give that a try.
 
 Good news!
 
 David's changes to 3.0.7RC1 have fixed this problem!
 
 I noticed one minor problem: neither XAException, nor SQLException are
 nested in the TransactionRolledbackException.  The exception I get is:
 
   java.rmi.ServerException (if remote)
- org.jboss.tm.JBossTransactionRolledbackException
- org.jboss.tm.JBossRollbackException
- null
 
 I looked at the code for TxCapsule and it would appear that the
 JBossRollbackException is initialialized with the XAException thrown in
 commitResources but the 'cause' field is nulled by instanceDone first!
 
 Even if that gets fixed I think it'd be really nice if the origin of the
 XAException, in this case the commit method in LocalTxConnectionManager,
 would include information about it's linkedException in the message.  I
 inserted the following code in order to get ludicrous amounts of
 SQLException information:
 
 StringBuffer message =
 new StringBuffer(Could not commit local tx: 
  + re.getMessage());
 boolean paren = false;
 if (re.getErrorCode() != null) {
 if (!paren) {
 message.append( ();
 paren = true;
 }
 message.append(ErrorCode: );
 message.append(re.getErrorCode());
 }
 if (re.getLinkedException() != null) {
 if (!paren) {
 message.append( ();
 paren = true;
 }
 Exception linked = re.getLinkedException();
 message.append(LinkedException: );
 message.append(linked);
 if (linked instanceof SQLException) {
 SQLException sql = (SQLException) linked;
 while (sql != null) {
 message.append(; SQLException);
 boolean comma = false;
 if (sql != linked) {
 if (comma)
 message.append(',');
 message.append( Message=);
 message.append(sql.getMessage());
 comma = true;
 }
 
 if (comma)
 message.append(',');
 message.append( ErrorCode=);
 message.append(sql.getErrorCode());
 comma = true;
 
 if (comma)
 message.append(',');
 message.append( SQLState=);
 message.append(sql.getSQLState());
 comma = true;
 
 sql = sql.getNextException();
 }
 }
 }
 if (paren)
 message.append(')');
 
 XAException e = new XAException(message.toString());
 if (re.getCause() == null  re.getLinkedException() !=
 null)
 e.initCause(re.getLinkedException());
 else
 e.initCause(re);
 
 
 An example message looks like this:
 
   Could not commit local tx: SQLException (LinkedException:
 java.sql.SQLException: ORA-02091: transaction rolled back\nORA-02290:
 check constraint (OMS.SYS_C004928) violated\n; SQLException
 ErrorCode=2091, SQLState=42000)
 
 Which is cool because somebody can figure out what SYS_C004928 is made
 out

Re: [JBoss-user] Session Bean (Txn Required) commit error not being sentback to the client

2003-02-11 Thread Jonathan . O'Connor

David,
I'll see if I can CVSGrab the source tomorrow morning. Sadly we have a very slow ISDN line here for 4 of us. I normally just wait for a release to pick up the source in one go.
I'll let you know how it goes.
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736






David Jencks [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
10.02.2003 17:04
Please respond to jboss-user


To:[EMAIL PROTECTED]
cc:
Subject:Re: [JBoss-user] Session Bean (Txn Required) commit error not being sent back to the client


Could you try 3.0.x from cvs? I ported (I think all of) the recent fixes
plus some new ones last night. Perhaps we are slowly converging on
reasonable behavior.

What should be happening now is that any exceptions during
synch.beforeCompletion, delist, prepare, or 1pc commit end up generating a
TransactionRolledback[Local]Exception. The entire chain of exceptions
(probably at least 4 deep) should implement org.jboss.util.NestedThrowable
so you should be able to traverse the chain of exceptions until you get the
 original SQLException that Oracle threw.

You can also use or reimplement the JBossLocalXAExceptionFormatter to do
customized logging of the XAExceptions that wrap the original
SQLExceptions. To use it, just include an mbean descriptor for it in the
oracle-service.xml file.

Let me know how it works, I'd like feedback before porting this to 3.2 and
head.

david jencks

On 2003.02.10 11:28 Jonathan.O'[EMAIL PROTECTED] wrote:
 David,
 I finally got to try out 3.2.0RC1 and 3.0.6 today. As you probably know 
 3.0.6 still has problems with catching exceptions during the commit
 stage.
 3.2.0RC1 has one of the problems fixed, but not the other.
 
 Here's what's fixed:
 Using Oracle 9i thi driver, we try writing a large blob to the database, 
 using CMP. The write fails. In previous versions of JBoss 3, all 
 subsequent uses of the DB connection failed.
 In 3.2.0RC1 this is fixed. Well done!
 
 However, the other problem, where I forget to set a non-nullable field in
 
 ejbCreate or ejbPostCreate (same effect), still does not return to the 
 caller if the constraints are checked at commit time.
 As mentioned previously, this happens in ORACLE 9, if you set the field
 as 
 DEFERRABLE INITIALLY DEFERRED. I have not found a way of replicating the 
 problem using non-DB-specific SQL.
 
 Ciao,
 Jonathan O'Connor
 Development Manager
 XCOM Dublin
 Phone: +353 1 872 3305
 Mobile: +353 86 824 0736
 
 
 
 
 David Jencks [EMAIL PROTECTED]
 Sent by: [EMAIL PROTECTED]
 24.01.2003 17:14
 Please respond to jboss-user
 
 
 To:   [EMAIL PROTECTED]
 cc: 
 Subject:Re: [JBoss-user] Session Bean (Txn Required)
 commit error not being sent 
 back to the client
 
 
 I thought this was fixed at least in 3.2 and head. Is there any chance 
 you could try one of these?
 
 On Friday, January 24, 2003, at 12:11 PM, Jonathan.O'[EMAIL PROTECTED] 
 wrote:
 
  David,
  Apologies for not giving version info. We use JBoss 3.0.5 running on
  Windows and Linux. But it used to happen in 3.0.4 as well (I wrote to 
  the
  list last November about it).
 
  The whole problem is that the database rollsback the transaction, and 
  the
  JBoss server catches an XAException, but neither our entity/session 
  beans
  nor our client application (JUnit) code gets to find out about this
  rollback. Our client code continues on in its ignorant way, assuming 
  all
  was well, and of course, trips up and falls over almost immediately 
  after
  that.
 
  Sorry, I haven't read the spec, but TransactionRolledBackException or 
  TransactionRolledBackLocalException sound OK to me. It looks to me as 
  if fixing this will involve a good bit
  of rework, to ensure the commit of the session bean transaction happens
  while returning from the Session Bean method. As far as I can tell (or
  should that be guess), the session bean method is long returned to the
  client before the txn is actually committed.
 
 It is committed by the time the method returns.
 
 david
 
  Lastly, I'm off on holidays for a week, so if you don't see further
  replies from me, I'm not being rude!
  Ciao,
  Jonathan O'Connor
  Development Manager
  XCOM Dublin
  Phone: +353 1 872 3305
  Mobile: +353 86 824 0736
 
 
 
 
  David Jencks [EMAIL PROTECTED]
  Sent by: [EMAIL PROTECTED]
  24.01.2003 15:01
  Please respond to jboss-user
 
 
  To:   [EMAIL PROTECTED]
  cc:
  Subject:Re: [JBoss-user] Session Bean (Txn Required) 
  commit error not being sent
  back to the client
 
 
  Which jboss?
  What does happen?
  Do you know the spec required behavior? I think it should be
  TransactionRolledBackException or TransactionRolledBackLocalException,
  but I haven't looked in the spec recently.
 
  david jencks
 
  On Friday, January 24, 2003, at 07:22 AM, Jonathan.O'[EMAIL PROTECTED]
  wrote:
 
  Yesterday, we got bitten by the same bug that bit us last November.
  Here's
  what happens

Re: [JBoss-user] Help! Java Editor problems with JBOSS IDE

2003-02-11 Thread Jonathan . O'Connor
Michael,
This is a known problem with Eclipse 2.1M5
Try M4 instead and it will work fine there.
As to Hans, I think he's away on holidays for the next week. You'd think 
he'd at least bring a laptop with him :-)
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Michael Ukpong [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
11.02.2003 14:53
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Help! Java Editor problems with JBOSS IDE


I just installed the jboss IDE plugin (a0.6) on Elipse M5, it messes up 
the java Editor (gives an error while attemting to open a java file) so 
that I can only open my java files with the text editor. As a 
confirmation, uninstalling it gets the Java Editor to work properly again.
I'm running Win 2k on an intel box. I wonder what I have not done 
property.
thanx in advance


-
Michael Ukpong
Enterprise Portal Architect
SocketWorks Ltd
+2348033473455
-

With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits 
your needs




---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Session Bean (Txn Required) commit error not being sentback to the client

2003-02-10 Thread Jonathan . O'Connor

David,
I finally got to try out 3.2.0RC1 and 3.0.6 today. As you probably know 3.0.6 still has problems with catching exceptions during the commit stage.
3.2.0RC1 has one of the problems fixed, but not the other.

Here's what's fixed:
Using Oracle 9i thi driver, we try writing a large blob to the database, using CMP. The write fails. In previous versions of JBoss 3, all subsequent uses of the DB connection failed.
In 3.2.0RC1 this is fixed. Well done!

However, the other problem, where I forget to set a non-nullable field in ejbCreate or ejbPostCreate (same effect), still does not return to the caller if the constraints are checked at commit time.
As mentioned previously, this happens in ORACLE 9, if you set the field as DEFERRABLE INITIALLY DEFERRED. I have not found a way of replicating the problem using non-DB-specific SQL.

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736






David Jencks [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
24.01.2003 17:14
Please respond to jboss-user


To:[EMAIL PROTECTED]
cc:
Subject:Re: [JBoss-user] Session Bean (Txn Required) commit error not being sent back to the client


I thought this was fixed at least in 3.2 and head. Is there any chance 
you could try one of these?

On Friday, January 24, 2003, at 12:11 PM, Jonathan.O'[EMAIL PROTECTED] 
wrote:

 David,
 Apologies for not giving version info. We use JBoss 3.0.5 running on
 Windows and Linux. But it used to happen in 3.0.4 as well (I wrote to 
 the
 list last November about it).

 The whole problem is that the database rollsback the transaction, and 
 the
 JBoss server catches an XAException, but neither our entity/session 
 beans
 nor our client application (JUnit) code gets to find out about this
 rollback. Our client code continues on in its ignorant way, assuming 
 all
 was well, and of course, trips up and falls over almost immediately 
 after
 that.

 Sorry, I haven't read the spec, but TransactionRolledBackException or 
 TransactionRolledBackLocalException sound OK to me. It looks to me as 
 if fixing this will involve a good bit
 of rework, to ensure the commit of the session bean transaction happens
 while returning from the Session Bean method. As far as I can tell (or
 should that be guess), the session bean method is long returned to the
 client before the txn is actually committed.

It is committed by the time the method returns.

david

 Lastly, I'm off on holidays for a week, so if you don't see further
 replies from me, I'm not being rude!
 Ciao,
 Jonathan O'Connor
 Development Manager
 XCOM Dublin
 Phone: +353 1 872 3305
 Mobile: +353 86 824 0736




 David Jencks [EMAIL PROTECTED]
 Sent by: [EMAIL PROTECTED]
 24.01.2003 15:01
 Please respond to jboss-user


 To:   [EMAIL PROTECTED]
 cc:
 Subject:Re: [JBoss-user] Session Bean (Txn Required) 
 commit error not being sent
 back to the client


 Which jboss?
 What does happen?
 Do you know the spec required behavior? I think it should be
 TransactionRolledBackException or TransactionRolledBackLocalException,
 but I haven't looked in the spec recently.

 david jencks

 On Friday, January 24, 2003, at 07:22 AM, Jonathan.O'[EMAIL PROTECTED]
 wrote:

 Yesterday, we got bitten by the same bug that bit us last November.
 Here's
 what happens:
 1. A client app (JUnit tester) calls a method in a session bean (via
 remote interface). The method is marked as Transaction required.
 1a. A transaction is started automatically by JBoss.
 2. The session bean method creates an entity bean. Because we use
 Oracle,
 we mark a foreign key field as NOT NULL DEFERRABLE INITIALLY DEFERRED.
 This means that the NOT NULL constraint is only checked at commit 
 time,
 rather than at insert or update time.
 3. The ejbCreate and ejbPostCreate of our entity bean don't call
 setFKField(), so this field remains NULL.
 4. The code returns from the session bean method.
 5. JBoss sees that the code has exited the session bean method marked
 as
 Txn Required, and tries to commit the Txn.
 6. Oracle now kicks in, and checks all the deferred constraints.
 Naturally
 one of them fails, so Oracle returns an exception saying the
 transaction
 has failed.

 Now for the bug:
 There is no place in my code where I can catch this
 XAException.
 Expected Result:
 The XAException should be turned into some sort of 
 EJBException
 and returned to the caller of the session bean method.

 I'd be happy to provide a small test case for this, but it would use
 Oracle. I guess it is possible to get this bug using other databases,
 but
 I think the SQL script would be DB specific.

 2003-01-24 11:44:08,275 WARN [org.jboss.tm.TxCapsule] XAException:
 tx=XidImpl [FormatId=257, GlobalId=XCOM-IRL-JONATHAN//8, BranchQual=]
 errorCode=XA_UNKNOWN(0)
 javax.transaction.xa.XAException: could not commit local
 txjavax.resource.ResourceException: SQLException

[JBoss-user] Session Bean (Txn Required) commit error not being sent back to the client

2003-01-24 Thread Jonathan . O'Connor
Yesterday, we got bitten by the same bug that bit us last November. Here's 
what happens:
1. A client app (JUnit tester) calls a method in a session bean (via 
remote interface). The method is marked as Transaction required.
1a. A transaction is started automatically by JBoss.
2. The session bean method creates an entity bean. Because we use Oracle, 
we mark a foreign key field as NOT NULL DEFERRABLE INITIALLY DEFERRED. 
This means that the NOT NULL constraint is only checked at commit time, 
rather than at insert or update time.
3. The ejbCreate and ejbPostCreate of our entity bean don't call 
setFKField(), so this field remains NULL.
4. The code returns from the session bean method.
5. JBoss sees that the code has exited the session bean method marked as 
Txn Required, and tries to commit the Txn.
6. Oracle now kicks in, and checks all the deferred constraints. Naturally 
one of them fails, so Oracle returns an exception saying the transaction 
has failed.

Now for the bug:
There is no place in my code where I can catch this XAException.
Expected Result:
The XAException should be turned into some sort of EJBException 
and returned to the caller of the session bean method.

I'd be happy to provide a small test case for this, but it would use 
Oracle. I guess it is possible to get this bug using other databases, but 
I think the SQL script would be DB specific.

2003-01-24 11:44:08,275 WARN  [org.jboss.tm.TxCapsule] XAException: 
tx=XidImpl [FormatId=257, GlobalId=XCOM-IRL-JONATHAN//8, BranchQual=] 
errorCode=XA_UNKNOWN(0)
javax.transaction.xa.XAException: could not commit local 
txjavax.resource.ResourceException: SQLException
at 
org.jboss.resource.connectionmanager.LocalTxConnectionManager$LocalConnectionEventListener.commit(LocalTxConnectionManager.java:567)
at org.jboss.tm.TxCapsule.commitResources(TxCapsule.java:1714)
at org.jboss.tm.TxCapsule.commit(TxCapsule.java:393)
at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:73)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:251)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:92)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
at 
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:204)
at 
org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.java:313)
at org.jboss.ejb.Container.invoke(Container.java:712)
at 
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
at 
org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:382)
at sun.reflect.GeneratedMethodAccessor35.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at 
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at 
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at 
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:536)
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736


---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Session Bean (Txn Required) commit error not being sentback to the client

2003-01-24 Thread Jonathan . O'Connor
David,
Apologies for not giving version info. We use JBoss 3.0.5 running on 
Windows and Linux. But it used to happen in 3.0.4 as well (I wrote to the 
list last November about it).

The whole problem is that the database rollsback the transaction, and the 
JBoss server catches an XAException, but neither our entity/session beans 
nor our client application (JUnit) code gets to find out about this 
rollback. Our client code continues on in its ignorant way, assuming all 
was well, and of course, trips up and falls over almost immediately after 
that.

Sorry, I haven't read the spec, but TransactionRolledBackException or 
TransactionRolledBackLocalException sound OK to me. It looks to me as if fixing this 
will involve a good bit 
of rework, to ensure the commit of the session bean transaction happens 
while returning from the Session Bean method. As far as I can tell (or 
should that be guess), the session bean method is long returned to the 
client before the txn is actually committed.

Lastly, I'm off on holidays for a week, so if you don't see further 
replies from me, I'm not being rude!
Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




David Jencks [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
24.01.2003 15:01
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Session Bean (Txn Required) commit error not 
being sent 
back to the client


Which jboss?
What does happen?
Do you know the spec required behavior?  I think it should be 
TransactionRolledBackException or TransactionRolledBackLocalException, 
but I haven't looked in the spec recently.

david jencks

On Friday, January 24, 2003, at 07:22 AM, Jonathan.O'[EMAIL PROTECTED] 
wrote:

 Yesterday, we got bitten by the same bug that bit us last November. 
 Here's
 what happens:
 1. A client app (JUnit tester) calls a method in a session bean (via
 remote interface). The method is marked as Transaction required.
 1a. A transaction is started automatically by JBoss.
 2. The session bean method creates an entity bean. Because we use 
 Oracle,
 we mark a foreign key field as NOT NULL DEFERRABLE INITIALLY DEFERRED.
 This means that the NOT NULL constraint is only checked at commit time,
 rather than at insert or update time.
 3. The ejbCreate and ejbPostCreate of our entity bean don't call
 setFKField(), so this field remains NULL.
 4. The code returns from the session bean method.
 5. JBoss sees that the code has exited the session bean method marked 
 as
 Txn Required, and tries to commit the Txn.
 6. Oracle now kicks in, and checks all the deferred constraints. 
 Naturally
 one of them fails, so Oracle returns an exception saying the 
 transaction
 has failed.

 Now for the bug:
 There is no place in my code where I can catch this 
 XAException.
 Expected Result:
 The XAException should be turned into some sort of EJBException
 and returned to the caller of the session bean method.

 I'd be happy to provide a small test case for this, but it would use
 Oracle. I guess it is possible to get this bug using other databases, 
 but
 I think the SQL script would be DB specific.

 2003-01-24 11:44:08,275 WARN  [org.jboss.tm.TxCapsule] XAException:
 tx=XidImpl [FormatId=257, GlobalId=XCOM-IRL-JONATHAN//8, BranchQual=]
 errorCode=XA_UNKNOWN(0)
 javax.transaction.xa.XAException: could not commit local
 txjavax.resource.ResourceException: SQLException
 at
 org.jboss.resource.connectionmanager.LocalTxConnectionManager$LocalConn 
 ectionEventListener.commit(LocalTxConnectionManager.java:567)
 at org.jboss.tm.TxCapsule.commitResources(TxCapsule.java:1714)
 at org.jboss.tm.TxCapsule.commit(TxCapsule.java:393)
 at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:73)
 at
 org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxIntercepto 
 rCMT.java:251)
 at
 org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:92)
 at
 org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.ja 
 va:130)
 at
 org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:204)
 at
 org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContaine 
 r.java:313)
 at org.jboss.ejb.Container.invoke(Container.java:712)
 at
 org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
 at
 org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:38 
 2)
 at sun.reflect.GeneratedMethodAccessor35.invoke(Unknown Source)
 at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccesso 
 rImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:324)
 at
 sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
 at sun.rmi.transport.Transport$1.run(Transport.java:148)
 at java.security.AccessController.doPrivileged(Native

Re: [JBoss-user] Again: How to use org.jboss.verifier ?

2003-01-24 Thread Jonathan . O'Connor
Heiko,
I asked this about a year ago, and the answer was that the code no longer 
worked.
My guess it was written for when JBoss didn't support hot deploy. Now, the 
need is limited.

Ciao,
Jonathan O'Connor
Development Manager
XCOM Dublin
Phone: +353 1 872 3305
Mobile: +353 86 824 0736




Rupp,Heiko [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
24.01.2003 17:22
Please respond to jboss-user

 
To: JBoss Users (E-Mail) [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Again: How to use org.jboss.verifier ?


Hi,

I have 

   java classname=org.jboss.verifier.Main 
fork=true failonerror=true 
classpathref=xdoclet.path.ref
arg value=${build.dir}/xdoclet-test-ejb.jar/ 
classpath
pathelement
path=${jboss.home}/server/default/lib/jboss.jar/
pathelement
path=${jboss.home}/server/default/lib/jpl-pattern.jar/
pathelement
path=${jboss.home}/server/default/lib/jpl-util.jar/
pathelement path=${jboss.home}/lib/xercesImpl.jar/
/classpath
/java 

Which gives

verify-ejb:
 [java] Problem starting the application:
 [java] Exception: org.jboss.deployment.DeploymentException: no
standardjboss.xml found
 [java] Message:   no standardjboss.xml found
 [java] org.jboss.deployment.DeploymentException: no standardjboss.xml
found
 [java] at
org.jboss.metadata.XmlFileLoader.load(XmlFileLoader.java:161)
 [java] at org.jboss.verifier.Main.main(Main.java:79

How can I use the verifier in my ant task to check the EJBs *before*
deployment?

Thanks
  Heiko


-- 
Bancotec GmbH  EMail: [EMAIL PROTECTED]
Calwer Str. 33 Telefon: +49 711 222 992 900
D-70173 Stuttgart  Telefax: +49 711 222 992 999
Ein Unternehmen der Cellent AG http://www.cellent.de/


---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] New JBoss breaks CMP of serializable object fields (Upgradefrom 3.0.2 to 3.0.4)

2003-01-09 Thread Jonathan . O'Connor
Randahl,
Unfortunately, some code changed, and 3.0.4 can't read data written with 
3.0.2. I think it happened when JBoss went from 3.0.2 to 3.0.3.
No doubt, somebody else knows the exact reason.
Ciao,
Jonathan




Randahl Fink Isaksen [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
09.01.2003 11:48
Please respond to jboss-user

 
To: [EMAIL PROTECTED], 
[EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] New JBoss breaks CMP of serializable object 
fields (Upgrade 
from 3.0.2 to 3.0.4)


After upgrading from 3.0.2 to 3.0.4 it seems JBoss handles EJB properties 
of type Serializable in a different way.
 
My whole solution is running the way it used to except for one thing: 
Those of my EJB's which have CMP fields which are of type serializable 
object fail. For instance, one of my beans has a field called validator 
which stores a serialized java object. After I started using JBoss 3.0.4 
it was no longer possible to read these beans from the database. JBoss 
threw this exception:
 
java.sql.SQLException: Got a [B[cl=0, value=[B@1ab7626] while looking for 
a dk.r
ockit.puls.value.property.validator.Validator[cl=31889293]
at 
org.jboss.ejb.plugins.cmp.jdbc.JDBCUtil.coerceToJavaType(JDBCUtil.jav
a:570)
at 
org.jboss.ejb.plugins.cmp.jdbc.JDBCUtil.getResult(JDBCUtil.java:437)
at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.load
ArgumentResults(JDBCAbstractCMPFieldBridge.java:359)
at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.load
InstanceResults(JDBCAbstractCMPFieldBridge.java:312)
?
 
Extensive testing has shown that all EJBs which have a serializable object 
field with a non-null value cannot be read from or written to the database 
(a SAP DB). As another example, I have an EJB which has a field called 
menuBar which stores a serialized java object. When setting a non-null 
value for this field on my EJB I get the following exception



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



RE: [JBoss-user] New JBoss breaks CMP of serializable object fields (Upgradefrom 3.0.2 to 3.0.4)

2003-01-09 Thread Jonathan . O'Connor
Randahl,
Have you updated your client libs? I found that with the 3.0.2 jboss 
client libs, I couldn't run my JUnit tests on a 3.0.4 system. The problem 
went away once I moved to 3.0.4 client libs.

As to the blobs, if you use Oracle, have a look at the recent messages 
about Oracle and Blobs/CLobs.
Ciao,
Jonathan




Randahl Fink Isaksen [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
09.01.2003 14:41
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] New JBoss breaks CMP of serializable object 
fields 
(Upgrade from 3.0.2 to 3.0.4)


Well, as I mentioned I can't make it write new data either (see the
original post below). Something is definitely wrong - or am I the only
one having trouble writing EJBs with fields containing serialized
objects into BLOB columns?


Randahl

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of
Jonathan.O'[EMAIL PROTECTED]
Sent: 9. januar 2003 14:47
To: [EMAIL PROTECTED]
Subject: Re: [JBoss-user] New JBoss breaks CMP of serializable object
fields (Upgrade from 3.0.2 to 3.0.4)

Randahl,
Unfortunately, some code changed, and 3.0.4 can't read data written with

3.0.2. I think it happened when JBoss went from 3.0.2 to 3.0.3.
No doubt, somebody else knows the exact reason.
Ciao,
Jonathan




Randahl Fink Isaksen [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
09.01.2003 11:48
Please respond to jboss-user

 
To: [EMAIL PROTECTED], 
[EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] New JBoss breaks CMP of
serializable object fields (Upgrade 
from 3.0.2 to 3.0.4)


After upgrading from 3.0.2 to 3.0.4 it seems JBoss handles EJB
properties 
of type Serializable in a different way.
 
My whole solution is running the way it used to except for one thing: 
Those of my EJB's which have CMP fields which are of type serializable 
object fail. For instance, one of my beans has a field called
validator 
which stores a serialized java object. After I started using JBoss 3.0.4

it was no longer possible to read these beans from the database. JBoss 
threw this exception:
 
java.sql.SQLException: Got a [B[cl=0, value=[B@1ab7626] while looking
for 
a dk.r
ockit.puls.value.property.validator.Validator[cl=31889293]
at 
org.jboss.ejb.plugins.cmp.jdbc.JDBCUtil.coerceToJavaType(JDBCUtil.jav
a:570)
at 
org.jboss.ejb.plugins.cmp.jdbc.JDBCUtil.getResult(JDBCUtil.java:437)
at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.load
ArgumentResults(JDBCAbstractCMPFieldBridge.java:359)
at 
org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCAbstractCMPFieldBridge.load
InstanceResults(JDBCAbstractCMPFieldBridge.java:312)
?
 
Extensive testing has shown that all EJBs which have a serializable
object 
field with a non-null value cannot be read from or written to the
database 
(a SAP DB). As another example, I have an EJB which has a field called 
menuBar which stores a serialized java object. When setting a non-null

value for this field on my EJB I get the following exception



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld =omething 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] DatabaseServerLoginModule is caching Roles Info...how todeactivate?

2003-01-07 Thread Jonathan . O'Connor
Victor,
we thought about this same issue, and then we remembered the following:
If you change a user's groups in Linux, they won't see them until they log 
in again.
Of course, your business people may say you have to have immediate update.
Maybe you can add the user to a list in the application attributes which 
is checked before each response generation. If their name is in the list, 
they get booted off. This forces them to log in again!
This is probably not the answer you wanted. Sorry!
Jonathan




Victor Batista [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
07.01.2003 16:06
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] DatabaseServerLoginModule is caching Roles 
Info...how to 
deactivate?


Hello!
 My JBoss is caching the user's roles info. How can I 
deactivate this
caching mechanism?
 Suppose I am logged with a User with Roles A and B. If 
this user changes
his roles (Administrator :-)), and adds Role C, the user wan't have this
permission until JBoss is restarted. If I change the roles of a user who 
has
already loggen in any time, I get the same problem.
 Is it possible to deactivate this caching mechanism, and 
force JBoss to
read data from the database every time?

 Any help would be welcome.

 Thanks in advance,
 Victor Batista

 PS - I am using JBoss 3.0.4 with bundled Tomcat 4.0.6. I 
am using
DatabaseServerLoginModule




---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] Connection problems after BLOB/CLOBs failure

2003-01-06 Thread Jonathan . O'Connor
Folks, all this discussion on BLOBs and slobs (:-) made me check our own 
code which uses a BLOB.

Sure enough, it worked with a 2000 character string, but fell over with 
the following exception with a 4000 char string.
15:44:28,664 ERROR [DeferredData] Could not create entity
java.sql.SQLException: Io exception: Connection reset
at 
oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
at 
oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
at 
oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:333)
at 
oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2061)
at 
oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:1940)
at 
oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2709)
at 
oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:589)
at 
org.jboss.resource.adapter.jdbc.local.LocalPreparedStatement.executeUpdate(LocalPreparedStatement.java:308)

However, now the connection has been reset, and all further use of it 
causes failure.

Q: How can I have JBoss automatically recover from this situation?
Q: Can I manually re-open the connection when I catch the SQLException?

Is this proper behaviour?

Finally, we're using JBoss 3.0.4 with Oracle 9.2
Ciao,
Jonathan


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] How to INSERT after ebjPostCreate versus ejbCreate

2002-12-31 Thread Jonathan . O'Connor
Dain,
I did a hunt on google for any problems, and the only thing I found was 
this:
www.geocities.com/lydian_third/ admintips/pkconstraint.pdf 

Basically it seems that unique indexes may cause a problem with deferrable 
constraints. However, I think the way we use the deferrable fk constraint, 
then it should be OK.

Ciao,
Jonathan




Dain Sundstrom [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
30.12.2002 17:26
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] How to INSERT after ebjPostCreate versus 
ejbCreate


I've had a lot of Oracle DBAs tell me that DEFERRABLE INITIALLY 
DEFERRED does very bad things to Oracle.  I don't remember the 
details, but it was bad enough that I gave up on some code that 
depended on it.

-dain

On Monday, December 30, 2002, at 10:17 AM, Bill Burke wrote:

 nice, thanks Jonathan.

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]On Behalf Of
 Jonathan.O'[EMAIL PROTECTED]
 Sent: Monday, December 30, 2002 6:10 AM
 To: [EMAIL PROTECTED]
 Subject: Re: [JBoss-user] How to INSERT after ebjPostCreate versus
 ejbCreate


 Rod,
 If you are using Oracle as your DB, then you can mark your CMR fk 
 columns
 as DEFERRABLE INITIALLY DEFERRED.
 Oracle will only check the non-null constraints at commit time. 
 Shouldn't
 be a problem for you.

 Other DBs may have something similar.

 Ciao,
 Jonathan




 Rod Macpherson [EMAIL PROTECTED]
 Sent by: [EMAIL PROTECTED]
 21.12.2002 19:53
 Please respond to jboss-user


 To: [EMAIL PROTECTED]
 cc:
 Subject:[JBoss-user] How to INSERT after
 ebjPostCreate versus ejbCreate


 Calling an entity bean CMR setter method within ejbCreate is 
 prohibited.
 The
 general solution is to make CMP calls within ejbCreate and CMR calls 
 in
 ejbPostCreate. That solution does not work when the CMR field maps
 directly
 to a non-nullable required column value. WebLogic resolves this issue 
 by
 deferring INSERT statements. How does one specify that option in 
 JBoss?





 ---
 This SF.NET email is sponsored by: Order your Holiday Geek Presents 
 Now!
 Green Lasers, Hip Geek T-Shirts, Remote Control Tanks, Caffeinated 
 Soap,
 MP3 Players,  XBox Games,  Flying Saucers,  WebCams,  Smart Putty.
 T H I N K G E E K . C O M   http://www.thinkgeek.com/sf/
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user





 ---
 This sf.net email is sponsored by:ThinkGeek
 Welcome to geek heaven.
 http://thinkgeek.com/sf
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user



 ---
 This sf.net email is sponsored by:ThinkGeek
 Welcome to geek heaven.
 http://thinkgeek.com/sf
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Re: Using CMR with PK-Field as FK

2002-12-31 Thread Jonathan . O'Connor
Alex,
Let me repeat what I think happens during entity bean creation:
In ejbCreate we set all primary key fields.
In ejbPostCreate we can set up any CMR fields.
Any CMR fields set in ejbCreate are ignored, and must be set again in 
ejbPostCreate.

Now if we have a table, T1,  with PK = {pkCol1, pkCol2}, and pkCol1 acts 
as a foreign key to another table, T2, then our entity bean will have a 
problem, because the field mapped to pkCol1 will also be marked as a CMR 
field, and so it will be blanked out at the end of ejbCreate (actually 
throws the IllegalStateException seen below).

So, can we instead only nullify CMR fields that are not mapped to primary 
key fields. This should work fine if T1-T2 is many to one or one to one 
relationship. Many to many is not a problem in this case because we are 
using foreign key constraints and not a mapping table to implement the 
relationship.

So, in Frank's example, he sets up the two parts of the primary key in 
ejbCreate, and does nothing in ejbPostCreate. He can use his CMR getter no 
problem. Of course, the CMR setter would throw an exception as you can't 
change the primary key.

Have I missed anything?
Happy New Year,
Jonathan




Alex Loubyansky [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
31.12.2002 12:22
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Re: Using CMR with PK-Field as FK


Hello Frank,

see my answer below.

Tuesday, December 31, 2002, 2:06:52 PM, you wrote:

LF I have two beans Feature and FeatureOption with CMR.
LF JBoss-HEAD created the tables correct, using the new feature to have 
the 
LF same field as FK to parent and part of PK:
LF create table feature ( feature_id smallint not null,  description 
LF varchar(30),  primary key (feature_id)  constraint pk_feature );
LF create table feature_option ( feature_id smallint not null, 
LF  option_id integer not null,  description varchar(30),  primary key 
LF (feature_id,option_id) constraint pk_feature_option );
LF alter table feature_option add constraint (foreign key 
(feature_id) 
LF references feature  constraint fk_featur_1isvfy8);

LF But everytime I try to add FeatureOptions to Feature, I get an 
Exception:
LF java.lang.IllegalStateException: CMR field Feature_options is 
mapped 
LF to a foreign key which is a part for a primary key,
LF and primary key may only be set once in ejbCreate [EJB 2.0 
Spec.10.3.5].

LF My code looks like this:
LF feature = featureHome.create( feature_id, description );
LF coll = feature.getOptions();
LF featureOption = featureOptionHome.create( feature_id, option_id, 
LF description );
LF coll.add( featureOption ); // this line throws the exception.

LF So my Question is: How to add a FeatureOption to Feature ?

This is the expected behaviour.
In this case, the relationships are assigned between ejbCreate and 
ejbPostCreate.
Having the same values in pk field and the corresponding fk field
means having a relationship.
Any attempt to modify the relationship with CMR accessors or
with collection api will throw this exception.
The relationship is removed only with one of the participant removal.

Do you think it should work other way?

alex




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] How to INSERT after ebjPostCreate versus ejbCreate

2002-12-30 Thread Jonathan . O'Connor
Rod,
If you are using Oracle as your DB, then you can mark your CMR fk columns 
as DEFERRABLE INITIALLY DEFERRED.
Oracle will only check the non-null constraints at commit time. Shouldn't 
be a problem for you.

Other DBs may have something similar.

Ciao,
Jonathan




Rod Macpherson [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
21.12.2002 19:53
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] How to INSERT after ebjPostCreate versus ejbCreate


Calling an entity bean CMR setter method within ejbCreate is prohibited. 
The
general solution is to make CMP calls within ejbCreate and CMR calls in
ejbPostCreate. That solution does not work when the CMR field maps 
directly
to a non-nullable required column value. WebLogic resolves this issue by
deferring INSERT statements. How does one specify that option in JBoss?





---
This SF.NET email is sponsored by: Order your Holiday Geek Presents Now!
Green Lasers, Hip Geek T-Shirts, Remote Control Tanks, Caffeinated Soap,
MP3 Players,  XBox Games,  Flying Saucers,  WebCams,  Smart Putty.
T H I N K G E E K . C O M   http://www.thinkgeek.com/sf/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Question about CMP/CMR

2002-12-30 Thread Jonathan . O'Connor
Stefan,
Most of our tables use a generated key (via an Oracle Sequence) as the 
primary key. Any tables that wanty a foreign key reference to this, always 
use this generated key.
Can you give an example where you want to have some other field or 
combination of fields as a unique reference to a foreign table?

I would think this is probably a bad idea in the long run.
HTH,
Jonathan O'Connor




Stefan Arentz [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
30.12.2002 16:55
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] Question about CMP/CMR


Alex Loubyansky wrote:

Frank,

if I understood you right, you want to map a CMR field with foreign
key to a CMP field that is not a primary key. Currently, this is not
supported.

Yeah I also removed foreign key constraints from my tables. This is 
pretty silly though.

How are other people handling this? Use another CMP2 engine? I can image 
that for many projects it is a requirement to have foreign keys or map 
to existing databases. How do you solve that with JBoss?

 S.




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] auditing

2002-12-20 Thread Jonathan . O'Connor
Miso,
Here's what we do:
1. Each normal table comes with a change control id column. The change 
control is points to a change control table, much like your master audit 
table.
2. We use triggers to copy the new row to audit/history tables. It is 
simpler from a query point of view if the audit tables also contain the 
current data, rather than just the historical data.
3. We use CMP2 to create the master audit record, and update the standard 
tables. We tend to do this in our session beans, although sometimes, we 
pass in a change control id as a parameter to a session bean method.

We find this the least invasive method of auditing. Yes, you could do this 
all in CMP2, but for every write to a base entity, you'd have to insert a 
new record in an audit table. 

HTH,
Jonathan




Miso Pach [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
19.12.2002 18:31
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] auditing


Hello!

I was wondering if someone can provide an insight into
what is the best way of auditing oracle (8i/9i)
database updates/inserts from within jboss when using
CMP beans and conteiner managed transactions.

Please follow this scenario:

- one jboss transaction updates 3 entity beans

- each of the 3 entity beans has a small auditing
table associated with it where I want to store the
values prior to the update

- there is also a master auditing table where I want
to record id of the user who did it, location, reason
for updating etc.

- the small audting tables have a foreign key link to
the master auditing table

What is the best way to arrange this in jboss?

I think I somehow need to find out when a new
transaction is started so I can run an insert into the
master table. Then I need to make the transaction id
available for the updates, so they can create the
entries in the small audit tables.

I am quite happy to use oracle triggers and oracle
variables in global packages etc. The tricky bit is
how to pass the extra information that I need in the
master audit table and how to link the small audit
tables with the foreign key to the master one.

I have read here people tried to inherit some jboss
interceptors to achieve this. Can anyone share a
sample code? Are there any other or better ways? I
believe so many people must have solved a similiar
people. What did you do?

Any replies would be appreciated.

thanks!

Miso


__
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com


---
This SF.NET email is sponsored by: Geek Gift Procrastinating?
Get the perfect geek gift now!  Before the Holidays pass you by.
T H I N K G E E K . C O M  http://www.thinkgeek.com/sf/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.NET email is sponsored by:  The Best Geek Holiday Gifts!
Time is running out!  Thinkgeek.com has the coolest gifts for
your favorite geek.   Let your fingers do the typing.   Visit Now.
T H I N K G E E K . C O Mhttp://www.thinkgeek.com/sf/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] MethodOnlyEJBLock has been deprecated - Huh???

2002-12-18 Thread Jonathan . O'Connor
Folks,
I recently got my grubby paws on an open source bug tracker, ITracker. I 
have it up and running under JBoss 3.0.4 using an Oracle database. But its 
spewing (really the only word for it) out 100's of error messages in the 
logs. See below for an example:
2002-12-18 16:49:39,782 ERROR [STDERR] WARNING: MethodOnlyEJBLock has been 
deprecated!

Is there a simple fix for this?

Ciao,
Jonathan O'Connor


---
This SF.NET email is sponsored by: Order your Holiday Geek Presents Now!
Green Lasers, Hip Geek T-Shirts, Remote Control Tanks, Caffeinated Soap,
MP3 Players,  XBox Games,  Flying Saucers,  WebCams,  Smart Putty.
T H I N K G E E K . C O M   http://www.thinkgeek.com/sf/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] What should be in client auth.conf to enable login atserver?

2002-11-26 Thread Jonathan . O'Connor
Emerson,
Thanks for your advice. I ended up creating MyDatabaseServerLoginModule 
which gets a DB connection using DriverManager and not JNDI.
And this works nicely. I suppose the fully correct way would be to have 
the client LoginModule connect to the EJB server, and call a session bean 
to authenticate the user and password.
This way, we can prevent client access to the DB. The authentication 
session bean can be allowed to be run by anyone, and all other beans can 
insist on an authenticated user.

However, for my unit tests, I don't need to worry about access to the DB.
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612




Emerson Cargnin - SICREDI Serviços [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
25.11.2002 20:26
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] What should be in client auth.conf to enable 
login at 
server?


 Symptoms:
 On the client side, lc.getSubject().getPrincipals().size() is always 0, 
 meaning we aren't logged on.
 On the client side, lc.login() with a bad password returns silently.
 On the server side, context.getCallerPrincipal() gives the correct name, 

 even if the client thinks I'm logged in.
 
 Questions:
 1. How can I trigger my DatabaseServerLoginModule authentication for my 
 client?
You must explicitly tell that you want the DatabaseServerLoginModule to 
be used, the ClientLoginModule just keeps the user/pass to be used in 
subsequent calls

 2. I thought that lc.login() should throw a LoginException if the 
username 
 and password are bad. Why does this not happen?

the same answer from 1

 3. I thought about putting the DatabaseServerLoginModule declaration 
into 
 the client auth,conf file, but I presume as this is a client, it can't 
do 
 the JNDI lookup on the DS name. Is this correct?

We use LDap login and it works right, but the client have access to the 
ldap server. Any idea at how to solve this using a datasource?


 Ciao,
 Jonathan O'Connor
 Ph: +353 1 872 3305
 Mob: +353 86 824 9736
 Fax: +353 1 873 3612
 
 
 ---
 This SF.net email is sponsored by: Get the new Palm Tungsten T 
 handheld. Power  Color in a compact size! 
 http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0002en
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user
 


-- 

| Emerson Cargnin  |
| Analista de Sistemas Sr. |
| Tel : (051) 3358-4959|
| SICREDI Serviços |
| Porto Alegre - Brasil|
|xx|



---
This SF.net email is sponsored by: Get the new Palm Tungsten T 
handheld. Power  Color in a compact size! 
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0002en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.net email is sponsored by: Get the new Palm Tungsten T
handheld. Power  Color in a compact size!
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0002en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] Where should auth.conf go for a client app?

2002-11-25 Thread Jonathan . O'Connor
Folks,
I'm trying to test my login code, and I've written a little junit test. 
However, when I call loginContext.login() it tells me:
Caused by: java.lang.SecurityException: Unable to locate a login 
configuration

I stuck the auth.conf file into a directory on my class path, but it still 
does not work? Any suggestions gratefully received.
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



RE: [JBoss-user] Where should auth.conf go for a client app?

2002-11-25 Thread Jonathan . O'Connor
Heiko,
We're using 3.0.4, but this is irrelevamt because we want to configure the 
client and not the server.
I had a look at the source code for LoginContext. The  solution is to set 
environment variable java.security.auth.login.config to the location of 
auth.conf file you want to use.
Just put -Djava.security.auth.login.config=/conf/auth.conf, and then 
there's no problem.

Adele (Sorry, I always liked Schwabisch),
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612




Rupp,Heiko [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
25.11.2002 12:51
Please respond to jboss-user

 
To: '[EMAIL PROTECTED]' [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] Where should auth.conf go for a client app?


Hi,

 Caused by: java.lang.SecurityException: Unable to locate a login 
 configuration

What JBoss Version are you using? AFAIK, auth.conf is no longer
in 3.x, but conf/login-config.xml is used instead.

 Heiko
-- 
Bancotec GmbH  EMail: [EMAIL PROTECTED]
Calwer Str. 33 Telefon: +49 711 222 992 900
D-70173 Stuttgart  Telefax: +49 711 222 992 999
Ein Unternehmen der Cellent AG http://www.cellent.de/


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] What should be in client auth.conf to enable login at server?

2002-11-25 Thread Jonathan . O'Connor
As part of my junit tests, I need a test to log in to my server using the 
DatabaseServerLoginModule.

My client auth.conf has the following lines:
other {
   // The JBoss LoginModule
   org.jboss.security.ClientLoginModule  required
  ;
};

My server login-config.xml contains the following section:
application-policy name = other
   authentication
  login-module code = org.jboss.security.ClientLoginModule flag 
= required/
  login-module code = 
org.jboss.security.auth.spi.DatabaseServerLoginModule flag = required
 module-option name = 
dsJndiNamejava:/OracleDS/module-option
 module-option name = principalsQuerySELECT password FROM 
Users WHERE principal_id=?/module-option
 module-option name = rolesQuerySELECT role, Role_group 
from User_Roles WHERE principal_id=?/module-option
  /login-module
   /authentication
/application-policy

My client login code looks like this:
CallbackHandler handler = new UsernamePasswordHandler(username, password);
LoginContext lc = new LoginContext(other, handler);
lc.login();
Subject subj = lc.getSubject();

Symptoms:
On the client side, lc.getSubject().getPrincipals().size() is always 0, 
meaning we aren't logged on.
On the client side, lc.login() with a bad password returns silently.
On the server side, context.getCallerPrincipal() gives the correct name, 
even if the client thinks I'm logged in.

Questions:
1. How can I trigger my DatabaseServerLoginModule authentication for my 
client?
2. I thought that lc.login() should throw a LoginException if the username 
and password are bad. Why does this not happen?
3. I thought about putting the DatabaseServerLoginModule declaration into 
the client auth,conf file, but I presume as this is a client, it can't do 
the JNDI lookup on the DS name. Is this correct?
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612


---
This SF.net email is sponsored by: Get the new Palm Tungsten T 
handheld. Power  Color in a compact size! 
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0002en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] Jetty: FORM authentication fails when cookies are turned off

2002-11-19 Thread Jonathan . O'Connor
Folks,
If we turn off all cookies in our browser, then FORM based authentication 
fails.
We use c:url / to append SESSIONID=blah to the URL. When the user clicks 
on a protected link, we get to the login page with the correct session id. 
After entering the correct user name and password, it fails to pass on to 
the protected link. Instead we jump to an error.jsp with a DIFFERENT 
session ID! It seems as if the login form is creating a new session, and 
adding session attributes to the new session. But, the URL we are 
forwarding to contains the old session ID which does not have any security 
attributes, and so the system says you are not logged in.

There is no logging output to suggest what is happening.

If we turn session cookies on, then it all works fine.

Is this normal behaviour? Are there any workarounds?
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612


---
This sf.net email is sponsored by: To learn the basics of securing 
your web site with SSL, click here to get a FREE TRIAL of a Thawte 
Server Certificate: http://www.gothawte.com/rd524.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



RE: [JBoss-user] Better exception logging (Was: TX Bug: Transacti onfailure not passed back to the client)

2002-11-14 Thread Jonathan . O'Connor
Craig,
Thanks for the example, although you didn't have to. I'll look up 
Effective Java. The problem with doing a printStackTrace() for each 
exception in the causation chain, is that the exceptions share part of the 
stack trace, and this of course drives us all mad, seeing the same 20 
function calls over and over again. There are three possibilities to avoid 
this situation:
1. Avoid catching and throwing another exception. Probably not possible 
for JBoss which must follow well defined interfaces.

2. At the point of logging, write something like this:
logger.error( makeDetailedMessage(Caught some error, e), e );

static String makeDetailedMessage( String firstMsg, Exception e ) {
String s = firstMessage;
for ( Exception ex = e; ex != null; ex = ex.getCause()) {
s = s + \nCause:  + ex.toString();
}
return s;
}

In this case, we only get the stack trace from the point of the last 
exception to be thrown, but we do get details of the nested exceptions, 
but no stack traces for them.

3. At the point of logging, write something like:
logger.error( makeDetailedMessage( Caught some error, e ), 
getRootCause(e));

static Exception getRootCause(Exception e) {
while ( e != null  e.getCause() != null ) e = e.getCause();
return e;
}

Thus, we get the full stack trace, plus all the causes. One final, but 
difficult improvement, would be to interleave the cause messages in the 
stack trace anywhere an exception was caught and another thrown. That's 
probably asking for too much.

Dain, yes, I appreciate that 1.3 has to be supported for many more years. 
At least org.jboss.util.NestedThrowable follows the 1.4 Throwable names.

Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612




Demyanovich, Craig - Apogent [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
13.11.2002 18:45
Please respond to jboss-user

 
To: '[EMAIL PROTECTED]' [EMAIL PROTECTED]
cc: 
Subject:RE: [JBoss-user] Better exception logging (Was: TX Bug: 
Transacti   on 
failure not passed back to the client)


 We really can't use the 1.4 exception class because we need 
 to support 
 1.3 for a long time.
 
 -dain

At my place, we write exception classes patterned after the changes to SDK
1.4.x so that we can use them in either 1.3.x or 1.4.x.  We based our work
on Item 43 of Joshua Bloch's _Effective Java_.  You just need to support 
the
constructors that take a cause as a parameter and add a getCause() method.
I will create an example or find an existing one and send it along later.

Craig


---
This sf.net email is sponsored by: Are you worried about 
your web server security? Click here for a FREE Thawte 
Apache SSL Guide and answer your Apache SSL security 
needs: http://www.gothawte.com/rd523.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by: To learn the basics of securing 
your web site with SSL, click here to get a FREE TRIAL of a Thawte 
Server Certificate: http://www.gothawte.com/rd524.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] JBoss Xdoclet Tag Question

2002-11-13 Thread Jonathan . O'Connor
Greg,
I've forgotten how you do this in 1.1.2, but if you are using JBoss 3.0.1 
or later, I'd recommend getting the new XDoclet beta. The documentation is 
quite good. As far as I know, XDoclet 1.1.2 only worked up to JBoss 3.0.0, 
or was it a beta?

BTW, you will need Ant 1.5 and you'll need to change your build script 
slightly for the new XDoclet, and you may have to rework your relationship 
code.
HTH,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612




Greg Turner [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
12.11.2002 17:55
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] JBoss Xdoclet Tag Question


I'm using jboss xdoclet tags to specify a many to many relationship 
between 2 beans.  In the jbosscmp-jdbc.xml that is generated, the 
relation-table-mapping element comes up empty.  The XDoclet jboss docs 
do not specify how to specify the relationship's table name in a tag.. 
 Does anyone know how to do it?  I'm using XDoclet 1.1.2

Thanks

Greg





---
This sf.net email is sponsored by: 
To learn the basics of securing your web site with SSL, 
click here to get a FREE TRIAL of a Thawte Server Certificate: 
http://www.gothawte.com/rd522.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by: Are you worried about 
your web server security? Click here for a FREE Thawte 
Apache SSL Guide and answer your Apache SSL security 
needs: http://www.gothawte.com/rd523.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] TX Bug: Transaction failure not passed back to the client

2002-11-13 Thread Jonathan . O'Connor
)
at 
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at 
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:536)

Lastly, my environment is: Windows 2000 for client and JBoss 3.0.4 server 
using Sun's JVM 1.4.1, Oracle 9i running on a Linux box.
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612


---
This sf.net email is sponsored by: Are you worried about 
your web server security? Click here for a FREE Thawte 
Apache SSL Guide and answer your Apache SSL security 
needs: http://www.gothawte.com/rd523.html
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] TX Bug: Transaction failure not passed back to the client

2002-11-13 Thread Jonathan . O'Connor
Folks,
I found my main problem. It turned out that I had a trigger on the Card 
insert which inserted a record in another table using a FK which at insert 
time was still null.

I have two points to make:
1. The logging in the server just told me it was a SQL error, but it never 
gave any details. I had to change the 
org.jboss.resource.connectionmanager.LocalTxConnectionManager
class to log the linkedException. Can we print the messages in all linked 
exceptions when they are logged?
2. I still don't know why the transaction can fail during commit and not 
send notification back to the client.

Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612




Jonathan.O'[EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
13.11.2002 12:29
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] TX Bug: Transaction failure not passed back to 
the client


We are implementing a workaround to allow NOT NULL foreign key columns to 
be set in ejbPostCreate.
We converted our NOT NULL constraints in our Oracle9 DB into NOT NULL 
DEFERABLE INITIALLY DEFERRED. This means that constraints are only checked 

at commit time. This is great because this lets us have non null foreign 
keys without changing the way JBoss (I'm on 3.0.4) works.

This seems to work for some of our entities. However, for our Card EJB 
shows the following strange behavior:
1. client code calls sessionBeanRemote.issueCard( ... );
2. JBoss automatically starts a transaction
3. SessionBean.issueCard(...) calls cardHome.create(...)
4. JBoss internally calls CardBean.ejbCreate, followed by 
CardBean.ejbPostCreate
5. SessionBean.issueCard() returns cardLocal.getPrimaryKey() to the client
6a. JBoss tries to call UPDATE for the ejbPostCreate stuff which seems to 
succeed.
6b. JBoss then tries to commit the transaction started in step 2, and 
fails, throwing an exception. The server logs show a stack trace of the 
problem.
6b. The client continues on after calling sessionBeanRemote.issueCard(...) 

as if nothing went wrong.

Some questions come to mind:
a) Why is the client not told of the exception?
b) Why is the UPDATE command executed long after cardHome.create() has 
returned? Is this a Don't trust the order of the logs problem?
c) What is causing the XaException?

Here's the relevant pieces of my log:

[Steps 1 and 2]
2002-11-13 11:37:00,043 INFO 
[xcom.traxbahn.bproc.bcomponents.ejb.CardBcBean] Getting ChangeControl for 

changeControlId: 1
[Step 3 and 4]
2002-11-13 11:37:00,234 DEBUG 
[org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.Card] Create: 
pk=383
2002-11-13 11:37:00,234 DEBUG 
[org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.Card] Executing 
SQL: SELECT COUNT(*) FROM T_CARD WHERE T_CARD_ID=?
2002-11-13 11:37:00,244 DEBUG 
[org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.Card] Executing 
SQL: INSERT INTO T_CARD (T_CARD_ID, PAN, EXPIRY_DATE, HOST_ID, VALID_FROM, 

PRODUCT_TYPE, HAS_PIN, HAS_CARD, STATUS, CREDITLIMIT, TMPLIMIT, 
TMPLIMITVALID, OVERDRAFT, OVERDRAFTVALID, OVERPAY, RISKDETECTED, 
REISSUE_CODE, REPLACE_ID, REPLACE_DATE, T_PERSON_ID, AUTHPROFILE, 
RISKPROFILE, OWNPROFILE, T_CHANGECONTROL_ID, T_ACCOUNT_ID, 
STATEMENT_ADDRESS, DELIVERY_ADDRESS) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, 

?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
2002-11-13 11:37:00,264 DEBUG 
[org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.Card] Rows 
affected = 1
[Step 4]
2002-11-13 11:37:00,334 DEBUG [xcom.traxbahn.baseentity.ejb.CardBean] 
PostCreate: accountId=275 stmtAddr=288 billingAddr=288
[Step 5]
2002-11-13 11:37:00,334 DEBUG 
[xcom.traxbahn.bproc.bcomponents.ejb.CardBcBean] Issued New Card 
ThinCardDTO:

cardID: 383
pan 4539782720326763
expiryDate: 2003.06
productType Cirrus

[Step 6a]
2002-11-13 11:37:00,334 DEBUG 
[org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreEntityCommand.Card] Executing 
SQL: UPDATE T_CARD SET STATEMENT_ADDRESS=?, DELIVERY_ADDRESS=? WHERE 
T_CARD_ID=?
2002-11-13 11:37:00,344 DEBUG 
[org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreEntityCommand.Card] Rows affected 

= 1
[Step 6b]
2002-11-13 11:37:00,384 WARN  [org.jboss.tm.TxCapsule] XAException: 
tx=XidImpl [FormatId=257, GlobalId=XCOM-IRL-JONATHAN//9, BranchQual=] 
errorCode=XA_UNKNOWN(0)
javax.transaction.xa.XAException: could not commit local 
txjavax.resource.ResourceException: SQLException
at 
org.jboss.resource.connectionmanager.LocalTxConnectionManager$LocalConnectionEventListener.commit(LocalTxConnectionManager.java:567)
at org.jboss.tm.TxCapsule.commitResources(TxCapsule.java:1714)
at org.jboss.tm.TxCapsule.commit(TxCapsule.java:393)
at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:73)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:201)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:60)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke

Re: [JBoss-user] ejbCreate violating database 'NOT NULL' constraints (foreignkeys) - Workaround

2002-11-08 Thread Jonathan . O'Connor
As Alex Lobansky has already said, you can't. But, here's what we do to 
work around the problem.
1. Add cmp fields for all the non-null foreign keys.
2. In the ejbCreate, call setNonNullFKCmpField( fkObj.getPrimaryKey()).
3. Remove any call to setNonNullFKCMRField( fkObj), as you've already 
done the work.
4. Add ejbSelect methods to get the fkObj given its id. This is easy to do 
if you're using XDoclet (but don't use 1.1.2, get the beta instead)
5. Rewrite getFKCMRField() funtion like so:
public FKObj getFKCMRField() {
Collection objs = ejbSelectFKObjs( getFKCMPField());
Iterator it = objs.iterator();
return (FKObj) it.next();
}

6. Rewrite setFKCMRField( FKObj fkObj ) {
setFKCMPField( fkObj.getPrimaryKey());
}

If you're relationship is bidirectional, you'll have to do something 
similar on the other side as well.

Given a free choice, I'd just turn off the NOT-NULL DB constraint, but 
politically, I couldn't do that, so we went through much pain.

I have been looking at ways of allowing a CMP and a CMR field to access 
the same DB column, but so far I've only had partial success. You may be 
able to get away with it on some DBs. But Oracle is not forgiving.
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612




Michael Angelo Libio [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
08.11.2002 10:14
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] ejbCreate violating database 'NOT NULL' 
constraints (foreign 
keys)


How can I avoid violating NOT NULL constraints on foreign keys that are 
mapped to cmr-fields?

I know that we're not suppose to set cmr fields during the ejbCreate 
method 
of an entity bean.  However, it seems that the call to insert into is 
executed before the cmr fields are set (ejbPostCreate).  Is there a way 
around this?  I'd like to keep my database schema the way it is (with it's 

relationship intact).


_
The new MSN 8: advanced junk mail protection and 2 months FREE* 
http://join.msn.com/?page=features/junkmail



---
This sf.net email is sponsored by: See the NEW Palm 
Tungsten T handheld. Power  Color in a compact size!
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0001en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by: See the NEW Palm 
Tungsten T handheld. Power  Color in a compact size!
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0001en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] Jetty falling over using DatabaseServerLoginModule with unauthorised user

2002-11-05 Thread Jonathan . O'Connor
I have finally got a WAR that has secured pages using JAAS. When I use 
UsersRolesLoginModule, it correctly goes to my error page with a 403 error 
if I login with a user who does not have the right role.
Now, I have changed to using the DatabaseServerLoginModule, and it works 
correctly if I login with a user who has the correct role. It also works 
correctly, (it displays an error page) if I try logging in an unknown user 
or if I give a bad password. But when I give a valid user/password for a 
user who lacks the correct role, JBoss 3.0.3 spits out a stack trace:
13:37:53,542 WARN  [jbossweb] WARNING: AUTH FAILURE: role for aidan
13:37:53,582 WARN  [jbossweb] WARNING: Exception for 
/security-test/restricted/Welcome.jsp
org.apache.jasper.JasperException: No output directory: String index out 
of range: -1
at 
org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:536)
at 
org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(JspServlet.java:176)
at 
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:188)
at 
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381)
at 
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at 
org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:366)
at 
org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:284)
at 
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:577)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1674)
at 
org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:544)
at org.mortbay.http.HttpResponse.sendError(HttpResponse.java:360)
at 
org.mortbay.http.SecurityConstraint.check(SecurityConstraint.java:391)
at 
org.mortbay.http.HttpContext.checkSecurityContstraints(HttpContext.java:1433)
at 
org.mortbay.jetty.servlet.WebApplicationContext.checkSecurityContstraints(WebApplicationContext.java:1210)
at 
org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:225)
at 
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:577)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1674)
at 
org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:544)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1624)
at org.mortbay.http.HttpServer.service(HttpServer.java:875)
at org.jboss.jetty.Jetty.service(Jetty.java:541)
at 
org.mortbay.http.HttpConnection.service(HttpConnection.java:785)
at 
org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:935)
at org.mortbay.http.HttpConnection.handle(HttpConnection.java:802)
at 
org.mortbay.http.SocketListener.handleConnection(SocketListener.java:200)
at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:294)
at org.mortbay.util.ThreadPool$JobRunner.run(ThreadPool.java:743)
at java.lang.Thread.run(Thread.java:536)

13:37:53,682 WARN  [jbossweb] WARNING: Error 500 while serving error page 
for 403

Any clues would be welcome.
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612


---
This sf.net email is sponsored by: See the NEW Palm 
Tungsten T handheld. Power  Color in a compact size!
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0001en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] DatabaseServerLoginModule

2002-11-04 Thread Jonathan . O'Connor
Scott,
Hang on a moment. But, Todd has a WEB-INF/jboss-web.xml file and the 
security domain is pointing to his AbilSoftRealm and not to other.
Do you have to point to other for this stuff to work? And why does what 
Todd is doing not work?

Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612




Scott M Stark [EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
03.11.2002 16:50
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] DatabaseServerLoginModule


There is no jboss-web.xml descriptor describing the security domain
under which authentication should occur. See the getting started guide
where a WEB-INF/jboss-web.xml file is described as being required
to enable security:

jboss-web
 security-domainjava:/jaas/other/security-domain
/jboss-web

On Sunday, November 3, 2002, at 07:30  AM, Todd Gould wrote:


 Hello:

 I'm trying to configure the DatabaseServerLoginModule to use as an
 authentication mechanism for a simple JSP with simple FORM based
 security. I'm sure I am missing something, but have not been able to
 find my error(s) in the documentation or other related posts. This is
 with JBoss 3.0.0 with Tomcat 4.0.3.

 The problem is as follows: The JSP presents and appears to process the
 login form correctly and just as expected. The problem is that no 
 matter
 what I respond to the form with for user and password, I am 
 successfully
 transferred to the JSP that is supposed to be guarded. This is to say
 that users/pws that are in the database and any other garbabge that is
 not both appear to work equally well and result in successful
 authentication. There are no errors on the console or log that I have
 found. There are also no errors during startup. There are also no
 indications that any authentication is ocurring.

 I'd appreciate any and all help as I'm not sure what I'm missing at 
 this
 point.

 Here are the relevant sections from the files:

 web.xml:
 security-constraint
 web-resource-collection
 web-resource-nameBookMarks/web-resource-name
 url-pattern/*/url-pattern
 /web-resource-collection
 auth-constraint
 role-namePortalUser/role-name
 /auth-constraint
 /security-constraint

 login-config
 auth-methodFORM/auth-method
 realm-nameAbilSoftRealm/realm-name
 form-login-config
 form-login-page/login.html/form-login-page
 form-error-page/login-error.html/form-error-page
 /form-login-config
 /login-config

 security-role
 role-namePortalUser/role-name
 /security-role

 jboss-web.xml:

 jboss-web security-domainjava:/jaas/AbilSoftRealm/security-domain
 /jboss-web

 login-config.xml:

 application-policy name = SecurityDbRealm
 authentication
 login-module code =
 org.jboss.resource.security.ConfiguredIdentityLoginModule flag =
 required
 module-option name = principaltestuser/module-option
 module-option name = userNametestuser/module-option
 module-option name = passwordpw/module-option
 module-option name =
 managedConnectionFactoryNamejboss.jca:service=LocalTxCM,name=Securit 
 yDS/module-option
 /login-module
 /authentication
 /application-policy


 application-policy name = AbilSoftRealm
 authentication
 login-module code =
 org.jboss.security.auth.spi.DatabaseServerLoginModule
 flag = required
 module-option name = dsJndiNamejava:/SecurityPool/module-option
 module-option name = principalsQueryselect password from users
 where username = ?/module-option
 module-option name = rolesQueryselect role, rolegroup from roles
 where username = ?/module-option
 module-option name = hashAlgorithmMD5/module-option
 module-option name = hashEncodingbase64/module-option
 /login-module
 /authentication
 /application-policy

 Thanks again.



---
This SF.net email is sponsored by: ApacheCon, November 18-21 in
Las Vegas (supported by COMDEX), the only Apache event to be
fully supported by the ASF. http://www.apachecon.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.net email is sponsored by: ApacheCon, November 18-21 in
Las Vegas (supported by COMDEX), the only Apache event to be
fully supported by the ASF. http://www.apachecon.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] 3.0.4 Release Notes are brilliant

2002-11-04 Thread Jonathan . O'Connor
Kudos to whoever wrote the release notes for 3.0.4
They are excellently organised, nicely formatted and the information is 
relevant and interesting.

Also, thanks for the comment about where to find test results.
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612


---
This SF.net email is sponsored by: ApacheCon, November 18-21 in
Las Vegas (supported by COMDEX), the only Apache event to be
fully supported by the ASF. http://www.apachecon.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Re: ClassCastException on redeploy of .ear

2002-11-04 Thread Jonathan . O'Connor
John,
What environment are you running in?

We had similar difficulties in previous versions of JBoss. Most of these 
seem to have gone away when we started using Sun's 1.4.1 JVM on Windows 
2000. We had lots of problems with Linux 6.2 and Sun's 1.3.1 JVM.


Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612




[EMAIL PROTECTED]
Sent by: [EMAIL PROTECTED]
04.11.2002 13:14
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Re: ClassCastException on redeploy of .ear


Hi David,

As I indicated to Scott, I upgraded to jboss-
3.0.4_tomcat-4.0.6 (the most recent version, as far as I 
know), but I still have the exact same problem. 
Everything works fine when I first start JBoss and 
deploy the .ear, but as soon as I re-deploy the .ear, I 
get a ClassCastException when trying to access a session 
bean from within a servlet.

I don't mean to be a whiner -- I think JBoss is great -- 
but having to restart JBoss every time an .ear is 
redeployed is just not acceptable for a production 
system.

I can only imagine that what I am doing (accessing a 
session bean from a servlet) is extremely common.  Am I 
the only one with this problem?  Is there anybody out 
there who *doesn't* have this problem?  How are other 
people dealing with it?

Any solution or advice would be most welcome.

Thanks,

-- John

Date: Sun, 3 Nov 2002 15:33:26 -0500
 From: David Jencks [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Subject: Re: [JBoss-user] Re: ClassCastException on 
redeploy of .ear
 Reply-To: [EMAIL PROTECTED]

 At various times there have been various class cast 
problems, and many of
 them have been fixed.  Please be sure you are using an 
up to date jboss
 version (such as 3.0.4) before complaining too loudly.

 thanks
 david jencks


---
This SF.net email is sponsored by: ApacheCon, November 18-21 in
Las Vegas (supported by COMDEX), the only Apache event to be
fully supported by the ASF. http://www.apachecon.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This SF.net email is sponsored by: ApacheCon, November 18-21 in
Las Vegas (supported by COMDEX), the only Apache event to be
fully supported by the ASF. http://www.apachecon.com
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] Running CMP2 tests: HSqlDB allows duplicate columns

2002-11-01 Thread Jonathan . O'Connor
Folks,
I'm on a mission to allow the same column be mapped to both a CMP field 
and a CMR field.
I made some mods to one of the tests (ReadOnlyUnitTestCase) and found that 
the create table SQL that JBoss generates contains a column name twice.
That's fine, but hsqldb doesn't complain. However, Oracle hates such SQL.

Which DBs do the unit tests get run against?

Also, are all new releases supposed to run all unit tests cleanly? I'd 
like to see the test suite report added to release.
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612


---
This sf.net email is sponsored by: See the NEW Palm 
Tungsten T handheld. Power  Color in a compact size!
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0001en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] JBoss 3.0.3 unit tests that store and retrieve Dates fail

2002-10-31 Thread Jonathan . O'Connor
Hi,
I ran the test suite that comes with the source. I get 3 test failures in 
the cmp2 tests.
In particular, they all occur due to problems storing java.util.Dates. 
What happens is they store new Date() in the DB and when this is read 
again, it comes out as Date(1222).
I presume this happens because the HS DB only stores dates to the 
precision of the machine clock (about 50 cycles per second), rather than 
to the millisecond.
Is this a known problem and should I fix these unit tests by say storing 
Date(  * 1000 ) instead?
Ciao,
Jonathan O'Connor
Ph: +353 1 872 3305
Mob: +353 86 824 9736
Fax: +353 1 873 3612


---
This sf.net email is sponsored by: Influence the future 
of Java(TM) technology. Join the Java Community 
Process(SM) (JCP(SM)) program now. 
http://ads.sourceforge.net/cgi-bin/redirect.pl?sunm0004en
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



  1   2   >