I tried switching to version 1.6 ("Current Milestone") and now it works.

Am I correct in concluding that the restful client services are not compatible 
with version 1.5?

As version 1.5 is listed as the "current stable version", I'm a little 
suprised/concerned by this.

Frank

On Nov 30, 2011, at 8:37 PM, Michael Hunger [via Neo4j Community Discussions] 
wrote:

> Frank, 
> 
> sorry to hear that. 
> 
> I just tried it and it works as expected. 
> 
>         final SpringRestGraphDatabase gdb = new 
> SpringRestGraphDatabase("http://localhost:7474/db/data/";); 
>         final Node node = gdb.getReferenceNode(); 
>         assertEquals(0,node.getId()); 
> 
> What version of the Neo4j-Server are you using? Could you please also show 
> the output of mvn dependency:tree ? 
> 
> Thanks a lot 
> 
> Michael 
> 
> if you execute it via curl, what are the results? 
> 
> ynagzet:spring-data-neo4j mh$ curl http://localhost:7474/db/data/ -i 
> HTTP/1.1 200 OK 
> Content-Length: 620 
> Content-Encoding: UTF-8 
> Content-Type: application/json 
> Access-Control-Allow-Origin: * 
> Server: Jetty(6.1.25) 
> 
> { 
>   "relationship_index" : "http://localhost:7474/db/data/index/relationship";, 
>   "node" : "http://localhost:7474/db/data/node";, 
>   "relationship_types" : "http://localhost:7474/db/data/relationship/types";, 
>   "neo4j_version" : "1.6.M01", 
>   "batch" : "http://localhost:7474/db/data/batch";, 
>   "extensions_info" : "http://localhost:7474/db/data/ext";, 
>   "node_index" : "http://localhost:7474/db/data/index/node";, 
>   "reference_node" : "http://localhost:7474/db/data/node/0";, 
>   "extensions" : { 
>     "GremlinPlugin" : { 
>       "execute_script" : 
> "http://localhost:7474/db/data/ext/GremlinPlugin/graphdb/execute_script"; 
>     } 
>   } 
> }ynagzet:spring-data-neo4j mh$ curl http://localhost:7474/db/data -i 
> HTTP/1.1 302 Found 
> Location: http://localhost:7474/db/data/
> Content-Length: 0 
> Server: Jetty(6.1.25) 
> 
> 
> Am 01.12.2011 um 00:19 schrieb Frank: 
> 
> > The server is running on localhost and can be hit from a browser. The 
> > server's configuration was modified to allow requests from any IP address, 
> > although all of my attempts are from the localhost anyway. 
> > 
> > I've tried this with and without a trailing slash on the URI, no 
> > difference. 
> > 
> > Code: 
> > 
> > GraphDatabase graphDb = new 
> > SpringRestGraphDatabase("http://localhost:7474/db/data";); 
> > graphDb.getReferenceNode(); 
> > 
> > Result: 
> > 
> > java.lang.NullPointerException 
> > at 
> > org.neo4j.rest.graphdb.ExecutingRestRequest.uriWithoutSlash(ExecutingRestRequest.java:78)
> >  
> > at 
> > org.neo4j.rest.graphdb.ExecutingRestRequest.<init>(ExecutingRestRequest.java:72)
> >  
> > at 
> > org.neo4j.rest.graphdb.ExecutingRestRequest.with(ExecutingRestRequest.java:149)
> >  
> > at org.neo4j.rest.graphdb.entity.RestEntity.<init>(RestEntity.java:52) 
> > at org.neo4j.rest.graphdb.entity.RestNode.<init>(RestNode.java:47) 
> > at org.neo4j.rest.graphdb.RestAPI.getReferenceNode(RestAPI.java:168) 
> > at 
> > org.neo4j.rest.graphdb.RestGraphDatabase.getReferenceNode(RestGraphDatabase.java:71)
> >  
> > at neo4j.Populate.<init>(Populate.java:35) 
> > at neo4j.Populate.main(Populate.java:18) 
> > 
> > 
> > -- 
> > View this message in context: 
> > http://neo4j-community-discussions.438527.n3.nabble.com/NullPointerException-in-ExecutingRestRequest-tp3550067p3550067.html
> > Sent from the Neo4j Community Discussions mailing list archive at 
> > Nabble.com. 
> > _______________________________________________ 
> > Neo4j mailing list 
> > [hidden email] 
> > https://lists.neo4j.org/mailman/listinfo/user
> 
> _______________________________________________ 
> Neo4j mailing list 
> [hidden email] 
> https://lists.neo4j.org/mailman/listinfo/user
> 
> 
> If you reply to this email, your message will be added to the discussion 
> below:
> http://neo4j-community-discussions.438527.n3.nabble.com/NullPointerException-in-ExecutingRestRequest-tp3550067p3550419.html
> To unsubscribe from NullPointerException in ExecutingRestRequest, click here.
> NAML



--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/NullPointerException-in-ExecutingRestRequest-tp3550067p3552186.html
Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
_______________________________________________
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user

Reply via email to