3 Replies Latest reply on Sep 20, 2018 12:48 PM by Galder Zamarreño

    Change Infinispan cache-availability status

    Purushothaman S Newbie

      Hi,

       

      I am trying to change the cache-availability status of infinispan through the management REST interface as a work around to address the issue here. However, the REST request fails with the following error:

       

      curl -u <username>:<password> --digest -X POST --header "Content-Type: application/json" -L -D - "http://<hostname>:9900/management/subsystem/datagrid-infinispan/cache-container/clustered/replicated-cache/default?operation=write-attribute" --data "{name: cache-availability, value: AVAILABLE}"

      HTTP/1.1 401 Unauthorized

      Connection: keep-alive

      WWW-Authenticate: Digest realm="ManagementRealm",domain="/management",nonce="Y2XHA1pcp0ENMTUzNjk3MjY0OTczMDKGGS9biTFCjPo7lTl66kU=",opaque="00000000000000000000000000000000",algorithm=MD5,qop="auth"

      Content-Length: 77

      Content-Type: text/html

      Date: Sat, 15 Sep 2018 00:50:49 GMT

       

       

      HTTP/1.1 500 Internal Server Error

      Connection: keep-alive

      Authentication-Info: nextnonce="Y2XHA1pcp0ENMTUzNjk3MjY0OTczMDKGGS9biTFCjPo7lTl66kU=",qop="auth",rspauth="c4da7d4df96ae557cfc90b5e1eb10b42",cnonce="ICAgICAgICAgICAgICAgICAgICAgICAgIDE0MDM2Mzk=",nc=00000001

      Content-Type: application/json; charset=utf-8

      Content-Length: 43

      Date: Sat, 15 Sep 2018 00:50:49 GMT

       

       

      "java.io.IOException: Invalid character: n"

       

      It doesn't work even if I change the request type to PUT.

       

      However, I am able to set the cache-availability through Management CLI.

       

      Can you please let me know what is wrong with the REST request which I am sending here?