Bug 900447 (JBPAPP6-834) - Datasource after creation is in a peculiar state
Summary: Datasource after creation is in a peculiar state
Keywords:
Status: CLOSED NEXTRELEASE
Alias: JBPAPP6-834
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: Web Console
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: ---
: EAP 6.0.0
Assignee: Paul Gier
QA Contact:
URL: http://jira.jboss.org/jira/browse/JBP...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-05-16 11:44 UTC by Jan Martiska
Modified: 2014-06-28 12:32 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-06-04 07:24:02 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker AS7-4865 0 Critical Resolved Datasource after creation is in a peculiar state 2013-06-04 01:51:29 UTC
Red Hat Issue Tracker JBPAPP6-834 0 Blocker Closed Datasource after creation is in a peculiar state 2013-06-04 01:51:29 UTC

Description Jan Martiska 2012-05-16 11:44:04 UTC
Workaround: Workaround Exists
Workaround Description: disable and enable the datasource using CLI, after that it will start working in console as well. Another workaround is to force server reload. 
project_key: JBPAPP6

Create a (xa)datasource in admin console. Try to disable it using the appropriate button. This error will happen:

{noformat}
Request
{
    "xa-datasource-class" => "org.h2.jdbcx.JdbcDataSource",
    "pad-xid" => false,
    "wrap-xa-resource" => false,
    "same-rm-override" => false,
    "interleaving" => false,
    "name" => "qrh",
    "driver-name" => "h2",
    "password" => "",
    "enabled" => true,
    "user-name" => "",
    "security-domain" => "",
    "jndi-name" => "java:/uyyyy",
    "pool-name" => "",
    "transaction-isolation" => "",
    "new-connection-sql" => "",
    "connection-url" => "",
    "driver-class" => "",
    "valid-connection-checker-class-name" => "",
    "check-valid-connection-sql" => "",
    "background-validation" => false,
    "background-validation-millis" => -1L,
    "validate-on-match" => false,
    "stale-connection-checker-class-name" => "",
    "exception-sorter-class-name" => "",
    "prepared-statements-cache-size" => -1L,
    "share-prepared-statements" => false,
    "use-ccm" => false,
    "operation" => "disable",
    "address" => [
        ("subsystem" => "datasources"),
        ("xa-data-source" => "qrh")
    ],
    "operation-headers" => {"allow-resource-service-restart" => true}
}

Response

Internal Server Error
{
    "outcome" => "failed",
    "failure-description" => "JBAS010455: Data-source service [qrh] is not enabled",
    "rolled-back" => true,
    "response-headers" => {"process-state" => "restart-required"}
}
{noformat}

It states that "Data-source service [qrh] is not enabled" even though the datasource has property "enabled" equal "true". 
After you disable the datasource in CLI using :disable operation (this works) and then enable it back -> from this point, disabling and enabling in console will work, just the first time (after creation) it doesn't.

*RESOLUTION* - the datasource has its property "enabled" wrongly set to true, even though it is actually disabled after creation. This is a JCA subsystem issue.

Comment 1 Heiko Braun 2012-05-22 07:32:30 UTC
Stefano, can you take a look at it?

Comment 2 Heiko Braun 2012-05-22 09:14:57 UTC
seems to be an issue with the operation handler: leaving out the operation header ("allow-resource-service-restart" => true) puts the server into reload state.

Comment 3 Heiko Braun 2012-05-22 12:11:28 UTC
maeste: hbraun: ah ok, if I can reproduce it I can take alook for sure
[2:08pm] maeste: hbraun: the issue says "However, this is not easily reproducible and doesn't appear always."
[2:09pm] hbraun: i believe this statement relates to the stack trace only
[2:09pm] hbraun: but it's not true for the overall issue
[2:09pm] hbraun: they don't need to be related
[2:10pm] hbraun: maeste: no, they don't relate to each otehr
[2:10pm] hbraun: i can reproduce it everytime
[2:10pm] hbraun: i am going to remove that comment, it's confusing

Comment 4 Stefano Maestri 2012-05-22 13:28:53 UTC
Link: Added: This issue Cloned to JBPAPP-9111


Comment 5 Anne-Louise Tangring 2012-05-22 16:24:48 UTC
Is this two issues in one? ]f so, we need a JIRA per issue or a clear understanding if the work around fixes the entire issue. 
Does "shown in the JNDI tree" a display issue or is it missing from the JNDI tree?
Please explain more. Thanks.

Comment 6 John Doyle 2012-05-22 16:27:36 UTC
By two issues in one we're trying to understand if we should divided the enable->disable part from the JNDI part.  Does the proposed workaround fix both parts?

Comment 7 Jesper Pedersen 2012-05-22 17:21:22 UTC
Fix provided by AS7-4865

Comment 8 Jan Martiska 2012-05-23 06:39:09 UTC
It is NOT two issues in one. Datasource after creation is disabled, the only problem is that it has the property "enabled" wrongly set to true (so admin console thinks that it is enabled). Therefore the fact that it doesn't appear in JNDI registry is not an issue, that is correct behavior, because the datasource is disabled.

Comment 9 Shelly McGowan 2012-05-23 11:56:22 UTC
Upstream pull request:
https://github.com/jbossas/jboss-as/pull/2367

Comment 11 Shelly McGowan 2012-05-23 17:14:39 UTC
This commit can be pulled onto product branch.

Comment 12 Shelly McGowan 2012-05-25 00:14:12 UTC
Waiting QE verification that the [upstream] fix does solve the issue as reported.

Comment 13 Jan Martiska 2012-05-25 07:13:25 UTC
Verified the fix in jbossas 7.1 branch (commit 82b9fd6), it works very well.

Comment 14 Paul Gier 2012-05-25 15:16:36 UTC
Merged [82b9fd66|https://github.com/jbossas/jboss-as/commit/82b9fd6614293d0804cc656fa219aa0589ce728d] to eap.

Comment 15 Misty Stanley-Jones 2012-06-01 04:38:55 UTC
Release Notes Docs Status: Added: Not Yet Documented
Affects: Added: Release Notes


Comment 17 Misty Stanley-Jones 2012-06-01 06:47:06 UTC
Release Notes Docs Status: Removed: Not Yet Documented Added: Not Required
Affects: Removed: Release Notes 


Comment 18 Jan Martiska 2012-06-04 07:24:02 UTC
Verified the fix in EAP 6.0.0 CR1, I have no objections.

Comment 19 Anne-Louise Tangring 2012-11-05 17:55:50 UTC
Release Notes Docs Status: Removed: Not Required 
Docs QE Status: Removed: NEW 



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