-
1. Re: seam design flaw with db down or driver problem?
deanhiller2000 Feb 1, 2010 8:44 PM (in response to deanhiller2000)no takers here?
I wrote a XADatasourceProxy and it turns out jboss/seam/hibernate is calling to getTransactionIsolation so my proxy won't work :(...if only jboss get the transactionIsolation just before sql was run...ie. I don't think jboss should be calling into the datasource PERIOD until REAL sql starts to be done...This seems like a big design flaw here.
My proxy had to call getConnection on the DS when getTransactionIsolation was called as I don't know the answer there...only the driver does....
Caused by: java.lang.RuntimeException: Exception opening connection at net.voicelog.oracleworkaround.CachingConnection.getConnection(CachingConnection.java:68) at net.voicelog.oracleworkaround.CachingConnection.getTransactionIsolation(CachingConnection.java:169) at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.<init>(BaseWrapperManagedConnection.java:143) at org.jboss.resource.adapter.jdbc.xa.XAManagedConnection.<init>(XAManagedConnection.java:56)
-
2. Re: seam design flaw with db down or driver problem?
deanhiller2000 Feb 1, 2010 9:55 PM (in response to deanhiller2000) -
3. Re: seam design flaw with db down or driver problem?
sefai Feb 26, 2010 9:54 PM (in response to deanhiller2000)Same here...I am using DB2 Local-XA datasource on JBoss, I was blaming JBoss until I saw your post. Infinite redirects and JBoss crash, then a system reboot is required...
-
4. Re: seam design flaw with db down or driver problem?
sefai Feb 26, 2010 10:14 PM (in response to deanhiller2000)Now I tried the XA datasource, both given here http://community.jboss.org/wiki/SetUpADB2Datasource, same thing happens...
-
5. Re: seam design flaw with db down or driver problem?
deanhiller2000 Mar 3, 2010 4:22 PM (in response to deanhiller2000)glad to see someone else with the post(misery loves company). My proxy on the non-XA Datasource turned out to have a bug and I found out autocommit had to be true...it is very bizarre (with oracle at least). I may post more as I need to dig deeper into the issues today to compare postgres and oracle and why one works and one doesn't in non-XA world.
-
6. Re: seam design flaw with db down or driver problem?
deanhiller2000 Mar 8, 2010 11:46 PM (in response to deanhiller2000)Well, after digging into this, I thought I could put a page in JSF using facelets that was not through seam so the tx would not start but it turns out jboss-seam.jar has a faces-config.xml that wires in a listener that starts the transaction so even in JSF you end up with starting these transactions.
ie. I guess I am not going to raw jsp or servlet to do this page and then try to redirect to that page(which I think is broken as well from our last testing in this issue). If it is broken, we will then be doing an inifinite redirect detection filter :(.
-
7. Re: seam design flaw with db down or driver problem?
asookazian Mar 9, 2010 1:24 AM (in response to deanhiller2000)
Dean Hiller wrote on Jan 21, 2010 20:36:
Is this a seam design flaw or is oracle the ones that should fix this?You could try sql server to get some more data ;)
-
8. Re: seam design flaw with db down or driver problem?
deanhiller2000 Mar 10, 2010 7:54 PM (in response to deanhiller2000)Actually, I found postgres broke when using check-valid-connection-sql which is required for recovery if db goes down and back up(and you hit web pages while db was down).
My final fix was a jsp page that we redirect to along with using check-valid-connection-sql.
Full test case discovered has to be specifically run this way
1. hit a web page in your app
2. take down the database
3. hit a web page in your app
RESULT: goes to a a nice error page
our result when adding check-valid-connection-sql was getting infinite redirect
4. bring db back up
5. hit a web page
RESULT: app works again
our result 'without' check-valid-connection-sql was the connection was hosed and never worked again. -
9. Re: seam design flaw with db down or driver problem?
deanhiller2000 Mar 10, 2010 7:54 PM (in response to deanhiller2000)damn formatting...
Full test case discovered has to be specifically run this way 1. hit a web page in your app 2. take down the database 3. hit a web page in your app RESULT: goes to a a nice error page our result when adding check-valid-connection-sql was getting infinite redirect 4. bring db back up 5. hit a web page RESULT: app works again our result 'without' check-valid-connection-sql was the connection was hosed and never worked again.
-
10. Re: seam design flaw with db down or driver problem?
deanhiller2000 Mar 10, 2010 7:58 PM (in response to deanhiller2000)please vote if you have the problem and I would bet you that you do....(I have done way too much testing on this issue)
The full bug reports are here https://jira.jboss.org/jira/browse/JBAS-7788 and https://jira.jboss.org/jira/browse/JBSEAM-4528