-
1. Re: do NOT use XA datasources with Seam!!!!!
cbensemann Feb 2, 2010 2:08 AM (in response to deanhiller2000)Hi Dean,
After reading your post I thought
oh no!
and promptly went and shutdown my DB to test the application I'm currently working on. I'm using mysql 5.1.38 with an XA datasource. After shutting down mysql seam immediately logs the loss of connection however all static content (images and xhtml pages without DB access) still render fine. When attempting to connect to the DB to login etc you are redirected to a page and a nice message ofconnection refused
is displayed - which is what I would expect given that the DB is down. :)So unless I've missed the point it appears that seam + mysql + XA works just fine.
MySQL might be worth a try if you are not tied to either postgres or oracle.
Craig
-
2. Re: do NOT use XA datasources with Seam!!!!!
deanhiller2000 Feb 2, 2010 4:29 PM (in response to deanhiller2000)I am jealous ;). I assume the page you are redirected to is a typical facelets/seam error.xhtml page or some sort, correct?
and you are using the exception handlers in pages.xml, correct?
(ie. just hoping maybe I could steal a way to workaround this from you).
thanks for responding with info on mysql!!!
thanks,
Dean -
3. Re: do NOT use XA datasources with Seam!!!!!
ctomc Feb 2, 2010 4:52 PM (in response to deanhiller2000)Hi,
I also have no problems using MS SQL server 2000,2005 or 2008, same goes for Postgres 8.3 and up
XA data sources work just fine.. I had some minor problems with my code with it but nothing with seam...Must be oracle jdbc problem, which wouldnt surprise me too much :)
cheers,
tomaz -
4. Re: do NOT use XA datasources with Seam!!!!!
deanhiller2000 Feb 2, 2010 9:15 PM (in response to deanhiller2000)Tomaz, I thought I tested postgres XA...I know postgres JDBC worked fine. You are using XA ds not JDBC with postgres, right?
Also, your test is logging in while the db is down results in a nice error page from seam, correct? (maybe I messed my postgres XA test up somehow but I could have sworn it tried to open a db connection when any http request came in for every request which ended in infinite redirect).
thanks,
Dean -
5. Re: do NOT use XA datasources with Seam!!!!!
cbensemann Feb 2, 2010 11:01 PM (in response to deanhiller2000)Happy to help if I can. Am about to go away for a couple of days though (back sunday). But briefly - Yes the page I redirect users back to on error is the home.xhtml page where I display error/info messages and it is defined as the page to go to for exceptions in pages.xhtml. Am happy to provide code examples on my return if needed.
Craig
-
6. Re: do NOT use XA datasources with Seam!!!!!
deanhiller2000 Mar 10, 2010 8:03 PM (in response to deanhiller2000)Craig,
can you run this full test case...(I beleive this new test case fails for all databases including yours but wanted to verify)...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 A: goes to a a nice error page our result when adding check-valid-connection-sql was getting infinite redirect regardless of postgres or oracle now 4. bring db back up 5. hit a web page RESULT B: app works again our result 'without' check-valid-connection-sql was the connection was hosed and never worked again.
ie. we needed check-valid for result B but then needed to go solve the infinite redirect problem.
-
7. Re: do NOT use XA datasources with Seam!!!!!
cbensemann Mar 12, 2010 11:25 PM (in response to deanhiller2000)Sorry for the delay. I'm happy to check this for you but I had a major hardware failure a couple of days ago and am busy rebuilding. Am back on deck today and will hopefully get to this soon.
-
8. Re: do NOT use XA datasources with Seam!!!!!
deanhiller2000 Mar 13, 2010 1:08 AM (in response to deanhiller2000)thanks, we did work around it but the solution is not as clean as it would be had this test case worked to begin with :(. I will be looking forward to your results...I can be patient now that we have a hack in place for this.