title: How to design a RESTful HTTP gateway for a protocol that requires persistent connections?
body: <p>I'm working with a persistent client/server protocol and I need to design a RESTful gateway. I don't have a lot of experience designing REST interfaces and I don't understand how I should handle (in a RESTful way) the session IDs needed to maintain persistent connections on the server and how I should represent server state as resources. </p>
  
  <p>I'm asking this because I don't want to end-up with a RPC-ish result that looks "RESTful". </p>
  
  <p>Problem specific context: I want to improve the existing ZooKeeper REST gateway to support ephemeral nodes and watches. An ephemeral node exists while the client is connected to the server. </p>
  
  <p>Thanks. </p>