Bug 1129400
Summary: | Unable to create resource-adapter using HTTP management interface | ||
---|---|---|---|
Product: | [JBoss] JBoss Enterprise Application Platform 6 | Reporter: | Libor Zoubek <lzoubek> |
Component: | Domain Management | Assignee: | Brian Stansberry <brian.stansberry> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Petr Kremensky <pkremens> |
Severity: | medium | Docs Contact: | |
Priority: | unspecified | ||
Version: | 6.2.4 | CC: | brian.stansberry, dandread, kkhan, theute |
Target Milestone: | DR1 | ||
Target Release: | EAP 6.4.0 | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: |
In previous versions of JBoss EAP 6, the logic in the operation to add a resource-adapter resource required that the target address be represented as a list of elements of DMR ModelType.PROPERTY.
This meant that HTTP-based management clients that used JSON could not reliably create operations using the expected format (as representing the $PROPERTY element in JSON syntax can be problematic).
In this release of JBoss EAP 6, the handler for the resource-adapter `add` operation has been updated to use standard address parsing code which is more forgiving of formatting differences. As a result, operations that add a resource-adapter using the HTTP interface and JSON similar to the example above now succeed as expected.
|
Story Points: | --- |
Clone Of: | Environment: | ||
Last Closed: | 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: | |||
Bug Depends On: | |||
Bug Blocks: | 1116788 |
Description
Libor Zoubek
2014-08-12 16:45:37 UTC
Not a CLI bug, since it seems the CLI works. This is either a core Domain Management issue, in how it reads the HTTP request, or a problem in the JCA component. The problem here is RaOperationUtil is using a very unorthodox method of reading the address of the operation: final List<ModelNode> address = operation.get(ModelDescriptionConstants.ADDRESS).asList(); final String id = address.get(address.size()-1).get(0).asString(); The issue is the ModelNode returned by "address.get(address.size()-1)". When you use the CLI, the ModelNode is of ModelType.PROPERTY. To create a ModelNode of ModelType.PROPERTY using JSON syntax is difficult. (TBH I'm not sure how to do it.) The syntax in the curl command results in a node of ModelType.OBJECT. That get(0) call fails on ModelType.OBJECT. It's quite the quirk that it works for ModelType.PROPERTY. Easy fix. |