Child type is a sibling of operation, not a child of operation.
On 6/2/11 6:36 PM, James Perkins wrote:
I'm working on the deployment maven plugin. I want the redeploy
goal to
either deploy if the deployment does not exist or redeploy if it does
exist. I'm having trouble determining if the deployment already exists.
This bit of CLI :read-children-names(child-type=deployment) shows me
what deployments exist. I've tried to duplicate it via a ModelNode.
ModelNode op = new ModelNode();
op.get("operation", READ_CHILDREN_NAMES_OPERATION).set(CHILD_TYPE,
DEPLOYMENT);
final InetAddress host = InetAddress.getByName(hostname);
final ModelControllerClient client =
ModelControllerClient.Factory.create(host, port);
ModelNode result = client.execute(op);
which results in
{
"outcome" => "failed",
"failure-description" => "No handler for
{\"read-children-names\"
=> (\"child-type\" => \"deployment\")} at address []"
}
I tried assigning an address, but I don't know I did it right. Any
pointers would be appreciated.
--
Jason T. Greene
JBoss, a division of Red Hat