]
Work on ISPN-10748 started by Gustavo Fernandes.
------------------------------------------------
Rest endpoint is not able to reach a preconfigured cache
--------------------------------------------------------
Key: ISPN-10748
URL:
https://issues.jboss.org/browse/ISPN-10748
Project: Infinispan
Issue Type: Bug
Affects Versions: 10.0.0.CR3
Reporter: Diego Lovison
Assignee: Gustavo Fernandes
Priority: Blocker
infinispan.xml
{code:xml}
<cache-container name="default">
<transport cluster="${infinispan.cluster.name}"
stack="${infinispan.cluster.stack:tcp}"/>
<distributed-cache name="rest"/>
</cache-container>
{code}
{code:java}
public static void main(String[] args) throws IOException {
String key = "k1";
String value = "v1";
OkHttpClient client = new OkHttpClient();
String url = "http://%s:%s/rest/v2/caches/%s/%s";
//String url = "http://%s:%s/rest/%s/%s";
Request request = new Request.Builder()
.url(String.format(url, "localhost", 11222, "rest",
key))
.put(RequestBody.create(TEXT_PLAIN, value))
.build();
Response response = client.newCall(request).execute();
assertEquals(200, response.code());
}
{code}
A few notes:
* When created via rest, it works.
* When using the v2 rest endpoint, it works.
* It is only failing with the legacy endpoint.