Apologies in advance if this is a stupid question.
I was going through the api for thrift TServlet and TProcessor and found
that I could not imagine a way to do user specific processing inside the
Service.Iface implementation.

Maybe code snippet would make things clearer
public MyServiceServlet extends TServlet {
  public MyServiceServlet() {
    super(new MyService.Processor(new MyServiceHandler()),
          new TJSONProtocol.Factory());
  }

  private static class MyServiceHandler implements MyService.Iface {
    public boolean getUserSpecificTruth() {
      // Get information for the user HttpServletRequest.getUserPrincipal()
      // who initiated this request
    }
  }
}


Thanks in advance
Aditya Dalmia

Reply via email to