Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 920974

Summary: CLI: data-source add --enable=true does not enable data source
Product: [JBoss] JBoss Enterprise Application Platform 6 Reporter: Dominik Pospisil <dpospisi>
Component: Web ConsoleAssignee: Stefano Maestri <smaestri>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.1.0CC: bbaranow, brian.stansberry, vrastsel
Target Milestone: ER4   
Target Release: EAP 6.1.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-07-23 18:38:06 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Dominik Pospisil 2013-03-13 08:37:18 UTC
Description of problem:
CLI: data-source add --enable=true does not actually enable data source. Datasource is created in disabled state and must be enabled later.

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


How reproducible:
always.


Steps to Reproduce:
1. data-source add --name=NoTxTradeDataSource --jndi-name=java:jboss/datasources/NoTxTradeDataSource --driver-name=h2 --connection-url=jdbc:h2:notxtrade.db:trade --enable
  
Actual results:
Datasource is not enabled.

Expected results:
Datasource should be enabled.

Tested on 6.1.0 ER2.

Comment 2 baranowb 2013-03-19 13:01:31 UTC
It seems thats intentional. There is the '--enabled' property. However its set as "read-only" atm, not sure why. It is accepted as valid data-source add parameter, but it does nothing.

Comment 3 Dominik Pospisil 2013-03-19 13:10:32 UTC
I understand the arumentation that having ability to create datasource in two steps is valid in certain situation. However that does not mean that one step creation should not be possible in cases that there is no extra property or subresource to add. 

Anyway, if it is not to be supported at all (for which I still see no reason), the CLI should not have this option as well.

Comment 4 baranowb 2013-03-19 14:39:21 UTC
Either there is some assumption Im not aware or its broken.
1. --enabled=true is accepted in 'data-source add' but does nothing
2. 
 cd subsystem=datasources/data-source=NoTxTradeDataSource
 :enable(persistent=false)

Does not work, it fails in CLI, server side:
 - @Message(id = 10432, value = "Unable to start the ds because it generated more than one cf")

3. 
 cd subsystem=datasources/data-source=NoTxTradeDataSource
 :enable(persistent=true)
Works fine.

From Maeste comment CLI should support this.

Comment 5 baranowb 2013-03-20 11:20:01 UTC
Ref JIRA.

Comment 7 Vladimir Rastseluev 2013-04-05 12:36:57 UTC
Verified on EAP 6.1 ER4.
There is a fix for AS7-6760 applied.

The described problem won't be fixed.