Description of problem: There is no clear description of the base URL used by the REST server. The Python and Ruby examples both show it as "/infinispan/rest". The default page that comes up when the server comes up "http://localhost:8080" does not give the base URL at all. Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: 1. 2. 3. Actual results: Expected results: The examples and front page for the REST server should show the base URL as "http://localhost:8080/rest/<cache name>/<key>" Additional info:
Brian, I may be misunderstanding you, but is it sufficient to add a note specifying the base url with a brief explanation of the same, for example: "The JBoss Data Grid REST server is mapped onto the location "/" as a default. As a result, the base URL is: http://localhost:8080/rest/MyData/MyKey In the listed base URL, "/rest" represents the REST servlet, "MyData" represents the name of the cache and "MyKey" represents the key. Please clarify if I am missing what you intended for this bug.
I see the problem here. The following part of documentation specifies /infinispan/rest/... as the path for REST server: http://documentation-stage.bne.redhat.com/docs/en-US/JBoss_Data_Grid/6/html/Developer_Guide/chap-The_REST_Interface.html This issue is only present with Ruby and Python examples. E.g. http.post('/infinispan/rest/MyData/MyKey', DATA HERE', {"Content-Type" => "text/plain"}) should be replaced with http.post('/rest/MyData/MyKey', DATA HERE', {"Content-Type" => "text/plain"}) but there are more issues like this one. Otherwise the home page of JDG server shows the proper context path starting with /rest (home page at http://localhost:8080/) so this should not be a problem.
Ruby Client code: http://documentation-stage.bne.redhat.com/docs/en-US/JBoss_Data_Grid/6/html/Developer_Guide/chap-The_REST_Interface.html#Ruby_Client_Code Have corrected occurrence of /infinispan in 5 parts of the example code on lines 4, 6, 8, 10, and 12. 4) http.post('/rest/MyData/MyKey', DATA HERE', {"Content-Type" => "text/plain"}) 6) puts http.get('/rest/MyData/MyKey').body 8) http.put('/rest/MyData/MyKey', 'MORE DATA', {"Content-Type" => "text/plain"}) 10) http.delete('/rest/MyData/MyKey') 12) http.put('/rest/MyImages/Image.png', File.read('/Users/michaelneale/logo.png'), {"Content-Type" => "image/png"}) Python Client code: http://documentation-stage.bne.redhat.com/docs/en-US/JBoss_Data_Grid/6/html/Developer_Guide/chap-The_REST_Interface.html#Python_Client_Code Corrected occurrence of /infinispan in 2 parts of the example code: 3rd line after #How to insert data: conn.request("POST", "/rest/Bucket/0", data, {"Content-Type": "text/plain"}) 3rd line after #How to retrieve data: conn.request("GET", "/rest/Bucket/0") Changes will appear on the stage after the next brew.
Those are the changes that I was looking for. Thanks.
Thanks Martin and Brian. Marking this bug resolved and awaiting release.