Bug 802747 - Scalable jbossas app failed to connect to embedded mysql
Scalable jbossas app failed to connect to embedded mysql
Status: CLOSED NOTABUG
Product: OpenShift Origin
Classification: Red Hat
Component: Containers (Show other bugs)
2.x
Unspecified Unspecified
high Severity high
: ---
: ---
Assigned To: Dan McPherson
libra bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-03-13 08:36 EDT by jizhao
Modified: 2015-05-14 18:52 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-03-13 10:03:28 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
connect to mysql, insert some data, and read them (1016 bytes, application/octet-stream)
2012-03-13 08:37 EDT, jizhao
no flags Details

  None (edit)
Description jizhao 2012-03-13 08:36:01 EDT
Description of problem:
Create a scalable jbossas app and embed mysql to it. Copy the app template to the git repo and git push.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.Create an scalable jbossas app using REST API
$ curl -k -H "Accept: application/xml" --user "<user>:<pass>"  https://<server_dns>/broker/rest/domains/<domain_name>/applications -X POST -d name=<appname> -d cartridge=jbossas-7 -d scale=true
2.Embed mysql to the app
$ rhc app cartridge add -a <app_name> -c mysql-5.1
3.Copy the attached app template to git repo, change the username, password to your own ones and git push.
  
Actual results:
<-------------web page------------->
type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

javax.servlet.ServletException: java.sql.SQLException: javax.resource.ResourceException: IJ000453: Unable to get managed connection for java:jboss/datasources/MysqlDS
...........
javax.resource.ResourceException: IJ000658: Unexpected throwable while trying to create a connection: null
.........
javax.resource.ResourceException: Could not create connection
......
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown database '98a78c714b'
........
<-------------------------------->

Expected results:
The app should connect to mysql successfully.

Additional info:
Comment 1 jizhao 2012-03-13 08:37:26 EDT
Version-Release number of selected component (if applicable):
rhc-cartridge-haproxy-1.4-0.6.5-1.el6_2.noarch
rhc-cartridge-jbossas-7-0.88.4-1.el6_2.noarch
rubygem-stickshift-controller-0.6.6-1.el6_2.noarch
stickshift-abstract-0.6.6-1.el6_2.noarch
rubygem-stickshift-node-0.6.7-1.el6_2.noarch
rubygem-stickshift-common-0.6.4-1.el6_2.noarch
Comment 2 jizhao 2012-03-13 08:37:53 EDT
Created attachment 569660 [details]
connect to mysql, insert some data, and read them
Comment 3 Dan McPherson 2012-03-13 10:03:28 EDT
This use case doesn't make sense to me.  Embedded mysql shouldn't work with a scalable app.  It would only be embedded in the haproxy gear in this case right?  What should work is connecting to a standalone mysql from jboss based on US2009.

Note You need to log in before you can comment on or make changes to this bug.