What do the server logs say when you're accessing via the proxy? Have you retried restarting the proxy?
Patrick On Tue, Mar 8, 2016 at 3:54 PM, Kunal Pariani <[email protected]> wrote: > So i tried building the REST contrib proxy in ZK ( > https://github.com/apache/zookeeper/tree/trunk/src/contrib/rest) to access > the data using curl but i still don't get any output when i hit the > /znodes/v1 endpoint. > > jar: > [echo] contrib: rest > [jar] Building jar: > /opt/zookeeper/build/contrib/rest/zookeeper-dev-rest.jar > > run: > [echo] contrib: rest > [java] Starting grizzly ... > [java] Started / - WADL: http://localhost:9998/application.wadl > [java] Server started. > > *root@7112b65ec69c:/opt/zookeeper# curl http://localhost:9998/znodes/v1 > <http://localhost:9998/znodes/v1>* > *root@7112b65ec69c:/opt/zookeeper#* > > Able to access the data using the zkCli though > > [zk: 127.0.0.1:2181(CONNECTED) 0] ls / > [zookeeper] > [zk: 127.0.0.1:2181(CONNECTED) 1] get /zookeeper > > cZxid = 0x0 > ctime = Thu Jan 01 00:00:00 UTC 1970 > mZxid = 0x0 > mtime = Thu Jan 01 00:00:00 UTC 1970 > pZxid = 0x0 > cversion = -1 > dataVersion = 0 > aclVersion = 0 > ephemeralOwner = 0x0 > dataLength = 0 > numChildren = 1 > [zk: 127.0.0.1:2181(CONNECTED) 2] > > Any ideas on what i might be missing ? > > Thanks > > On Thu, Mar 3, 2016 at 4:17 PM, Patrick Hunt <[email protected]> wrote: > >> There's also the REST interface in ZK's contrib directory. >> >> Patrick >> >> On Thu, Mar 3, 2016 at 4:14 PM, Jordan Zimmerman >> <[email protected]> wrote: >> > FYI - I wrote a Thrift wrapper around Curator that might working: >> http://curator.apache.org/curator-x-rpc/index.html >> > >> >> On Mar 3, 2016, at 7:12 PM, Kunal Pariani <[email protected]> wrote: >> >> >> >> Hello, >> >> I am new to ZK and running it inside a docker container. Was looking >> for a >> >> way to access the znodes through a REST api. Found this >> >> https://github.com/ezbz/Zookie but wasn't able to build it >> successfully. >> >> Looks like its not being updated either >> >> Any suggestions on how else could i do this ? >> >> >> >> Also looking to register the endpoints (ip:port) of all my backend >> services >> >> running in docker with ZK using registrator. Any ideas on how to do this >> >> too ? >> >> >> >> Thanks >> > >>
