UnsupportedOperationException when using RestGraphDatabaseServiceProvider and executing a query

60 views
Skip to first unread message

denis...@gmail.com

unread,
Dec 10, 2013, 12:11:15 PM12/10/13
to neo4j...@googlegroups.com
Hello all,
could you please help a newbie(:me:) figure out why an UnsupportedOperationException is thrown when executing a query with a REST provider?

My code is below

object UserRepository extends Neo4jWrapper with RestGraphDatabaseServiceProvider with Cypher{

  private val FETCH_USER_BY_EMAIL: String = "START user=node(*) WHERE (user.email = \"%s\") RETURN user LIMIT 1"

  def uri: URI = new URI("http://localhost:7474/db/data/")
 
  def fetchForEmail(email: String) : Option[UserIdentity] = {
    withTx {
      implicit  neo =>
        val query = FETCH_USER_BY_EMAIL.format(email)
        val users = query.execute.asCC[UserIdentity]("user")
        if(users.isEmpty) Option.empty
        else Option(users.next())
    }
  }
}


The stack trace is attached.
Any help you would be greatly appreciated.
Thank you.

stacktrace.txt

Christopher Schmidt

unread,
Dec 11, 2013, 1:07:13 AM12/11/13
to denis...@gmail.com, neo4j...@googlegroups.com
Hi Denis, not all functionality is implemented in module neo4j-rest-graphdb.
Maybe you can try to use a newer version as 1.9 or use a local database.

best Christopher


--
You received this message because you are subscribed to the Google Groups "neo4j-scala" group.
To unsubscribe from this group and stop receiving emails from it, send an email to neo4j-scala...@googlegroups.com.
To post to this group, send email to neo4j...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages