[standalone@localhost:9999 endpoint=CLIWebservicesWsdlPortTestCase%3Aorg.jboss.test.ws.cli.AnnotatedServiceImpl] pwd /deployment=CLIWebservicesWsdlPortTestCase.war/subsystem=webservices/endpoint=CLIWebservicesWsdlPortTestCase%3Aorg.jboss.test.ws.cli.AnnotatedServiceImpl [standalone@localhost:9999 endpoint=CLIWebservicesWsdlPortTestCase%3Aorg.jboss.test.ws.cli.AnnotatedServiceImpl] :write-attribute(name="wsdl-url",value="aaa") { "outcome" => "failed", "failure-description" => "JBAS014792: Unknown attribute wsdl-url", "rolled-back" => true } [standalone@localhost:9999 endpoint=CLIWebservicesWsdlPortTestCase%3Aorg.jboss.test.ws.cli.AnnotatedServiceImpl] :write-attribute(name="request-count",value="1") { "outcome" => "failed", "failure-description" => "JBAS014639: Attribute request-count is not writable", "rolled-back" => true } [standalone@localhost:9999 endpoint=CLIWebservicesWsdlPortTestCase%3Aorg.jboss.test.ws.cli.AnnotatedServiceImpl] :read-resource(include-runtime=true) { "outcome" => "success", "result" => { "average-processing-time" => "0", "class" => "org.jboss.test.ws.cli.AnnotatedServiceImpl", "context" => "CLIWebservicesWsdlPortTestCase", "fault-count" => "0", "max-processing-time" => "0", "min-processing-time" => "0", "name" => "org.jboss.test.ws.cli.AnnotatedServiceImpl", "request-count" => "0", "response-count" => "0", "total-processing-time" => "0", "type" => "JAXWS_JSE", "wsdl-url" => "http://localhost:8080/CLIWebservicesWsdlPortTestCase/AnnotatedSecurityService?wsdl" } } [standalone@localhost:9999 endpoint=CLIWebservicesWsdlPortTestCase%3Aorg.jboss.test.ws.cli.AnnotatedServiceImpl] :read-resource() { "outcome" => "success", "result" => { "class" => "org.jboss.test.ws.cli.AnnotatedServiceImpl", "context" => "CLIWebservicesWsdlPortTestCase", "name" => "org.jboss.test.ws.cli.AnnotatedServiceImpl", "type" => "JAXWS_JSE", "wsdl-url" => "http://localhost:8080/CLIWebservicesWsdlPortTestCase/AnnotatedSecurityService?wsdl" } } [standalone@localhost:9999 endpoint=CLIWebservicesWsdlPortTestCase%3Aorg.jboss.test.ws.cli.AnnotatedServiceImpl] ls -l ATTRIBUTE VALUE TYPE average-processing-time 0 INT class org.jboss.test.ws.cli.AnnotatedServiceImpl n/a context CLIWebservicesWsdlPortTestCase n/a fault-count 0 INT max-processing-time 0 INT min-processing-time 0 INT name org.jboss.test.ws.cli.AnnotatedServiceImpl n/a request-count 0 INT response-count 0 INT total-processing-time 0 INT type JAXWS_JSE n/a wsdl-url http://localhost:8080/CLIWebservicesWsdlPortTestCase/AnnotatedSecurityService?wsdl n/a
The problem is WSExtension is not registering attribute metadata for the stuff included in org.jboss.as.webservices.dmr.ModelDeploymentAspect. It registers the metrics, but not these fixed values.
CLI commands: deploy /tmp/CLIWebservicesWsdlPortIT.war /deployment=CLIWebservicesWsdlPortIT.war/subsystem=webservices/endpoint=CLIWebservicesWsdlPortIT%3Aorg.jboss.qa.management.ws.cli.AnnotatedServiceImpl/:write-attribute(name=wsdl-url,value=test) Result: /deployment=CLIWebservicesWsdlPortIT.war/subsystem=webservices/endpoint=CLIWebservicesWsdlPortIT%3Aorg.jboss.qa.management.ws.cli.AnnotatedServiceImpl/:write-attribute(name=wsdl-url,value=test) { "outcome" => "failed", "failure-description" => "JBAS014639: Attribute wsdl-url is not writable", "rolled-back" => true } Result is correct, but CLI GUI still offers write and undefine operations on this attribute, which is wrong
Created attachment 864066 [details] deployment (war with webservice)
I consulted with Brian Stansberry and Stan Silvert on this change. Brian speculated this might be a general problem that occurs with any read-only attribute. Stan confirmed it. -- Stan wrote ... > I implemented the fix but I don't like the way it turned out from a > usability standpoint. > > If it is a read-only attribute then there will be no operations menu > when you right-click the node. That's very confusing because some nodes > will have a menu and others will not. > > The alternative to displaying nothing is to display some sort of error > or warning like "This attribute is read only". IMO, that's more > annoying than just letting the user execute the command. > > Furthermore, the regular CLI does not do this check either. It happily > performs tab completion and lets you execute. > > So I think it's best if we just leave it alone and tell the customer it > is working as designed. So in summary, this behavior is common to all read-only attributes. There is no satisfactory way to change the CLI to provide the behavior you've requested. The CLI team considers this working as designed and not a bug.
Verified as per comment 11. New BZ 1083877 created for issue that CLI GUI offers write and undefine operations on read-only attribute