Search in sources :

Example 1 with Update

use of com.linkedin.restli.server.annotations.RestMethod.Update in project rest.li by linkedin.

the class MixedResource method update.

@Update
public Promise<UpdateResponse> update(Long key, Greeting entity) {
    final SettablePromise<UpdateResponse> result = Promises.settable();
    Runnable requestHandler = new Runnable() {

        public void run() {
            result.done(new UpdateResponse(HttpStatus.S_200_OK));
        }
    };
    scheduler.schedule(requestHandler, DELAY, TimeUnit.MILLISECONDS);
    return result;
}
Also used : UpdateResponse(com.linkedin.restli.server.UpdateResponse) Update(com.linkedin.restli.server.annotations.RestMethod.Update)

Aggregations

UpdateResponse (com.linkedin.restli.server.UpdateResponse)1 Update (com.linkedin.restli.server.annotations.RestMethod.Update)1