Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[lyo-dev] Consumer REST Update problem

Hi all,
I have started with implementation of a Dummy Consumer, and the Provider is the Lyo example StockQuote.
So far I can retrieve the Information like this :
OslcRestClient oslcRestClient = new OslcRestClient(providers, queryBase, MEDIA_TYPE, timeout); StockQuote[] stocks = oslcRestClient.getOslcResources(StockQuote[].class);
And in main Method I can output them in my Console.

Now I want to change some values and update them, so I used the Method like this :

OslcRestClient oslcRestClient = new OslcRestClient(providers, resourceBase, MEDIA_TYPE, timeout); ClientResponse clientResponse = oslcRestClient.updateOslcResourceReturnClientResponse(updatedResource);

resourceBase is "http://localhost:8080/OSLC4JStockQuote/stockQuotes/nasdaq_nflx"; which I target to.

And then the System responses with Status 405- Method Not Allowed. I really dont know , what I did wrong,
Could someone help me with this issue ? Thanks a lot

Best Regards
Heng Cao



Back to the top