[Hawkular-dev] deploy / undeploy / remove

John Mazzitelli mazz at redhat.com
Thu Aug 4 11:52:56 EDT 2016


> >    <operation-dmr name="Deploy"   internal-name="deploy"/>
> >    <operation-dmr name="Undeploy" internal-name="undeploy"/>
> >
> > On the "Host Controller" resource (which is only in domain mode),
> > there are these same two operations defined.
> >
> > So, you can deploy an application through the "WildFly Server"
> > (standalone mode) and "Host Controller" (domain mode) - you need to
> > pass in content when you do this, hence why DeployApplicationRequest
> > JSON has to be used.
> >
> > But notice you can also undeploy an application through those top
> > level resources as well. You do this via UndeployApplicationRequest
> > JSON.
> 
> And this is where the problem starts. The above two look exactly
> like
> 
>    <operation-dmr name="Resume"   internal-name="resume" />
> 
> There is no way to determine that the above Deploy and Undeploy
> are not generic commands, but special ones, that can't be run
> with this ExecuteOperationRequest, but need something special.
> 
> More later ... :)


Right. I think the way I might want to solve this is to add a new piece of metadata on <operation-dmr> so clients at least know what to send in - "json-request-name" (or something similar). It's value is the name of the JSON request schema (e.g. DeployApplicationRequest or UndeployApplicationRequest). These map to those schemas defined by cmdgw:

https://github.com/hawkular/hawkular-commons/tree/master/hawkular-command-gateway/hawkular-command-gateway-api/src/main/resources/schema

We don't even have to store this anywhere. It is really just used for documentation for the developer to see. I don't see any value-add for actually storing this anywhere in inventory.


More information about the hawkular-dev mailing list