OpenTreeOfLife / taxomachine

taxonomy graphdb
Other
7 stars 4 forks source link

Index all taxonomy nodes by flags and provide a simple boolean search #53

Closed chinchliff closed 10 years ago

chinchliff commented 10 years ago

Index all nodes by flag, and provide a plugin to allow users to search for taxa matching one of any of a set of flags (boolean OR).

jar398 commented 10 years ago

An option to just return counts, rather than list all the matching taxa, would be useful for metrics purposes, see 7 July 2014 software hangout minutes.

chinchliff commented 10 years ago

I think counts may be the only feasible option anyway. The results are likely to be in the hundreds of thousands if not millions, and this is probably more than we want to bother returning. Users can download OTT and grep for flags if they need all the names or ids.

chinchliff commented 10 years ago

Ok, I have made a service for this. @jar398, I tried deploying to devapi, but it seems to be doing the thing where it updates the local maven dependency with the new changes from git and then fails to trigger the plugin update because the changes from git were already pulled (so it thinks there are no new changes to update the plugin with). I thought we had a fix for this? If there is one, please let me know how to use it.

Here is the call that should work:

curl -X POST http://devapi.opentreeoflife.org/taxomachine/ext/OTTServices/graphdb/getFlaggedTaxonCount -H "content-type:application/json" -d '{"flag":"not_otu"}'

And it should return:

{
  "not_otu" : 39123
}

But it is returning:

{
  "message" : "No plugin \"getFlaggedTaxonCount\" for interface org.neo4j.graphdb.GraphDatabaseService",
  "exception" : "PluginLookupException",
  "fullname" : "org.neo4j.server.plugins.PluginLookupException",
  "stacktrace" : [ "org.neo4j.server.plugins.ServerExtender.getExtensionPoint(ServerExtender.java:79)", "org.neo4j.server.plugins.PluginManager.extension(PluginManager.java:126)", "org.neo4j.server.plugins.PluginManager.invoke(PluginManager.java:165)", "org.neo4j.server.rest.web.ExtensionService.invokeGraphDatabaseExtension(ExtensionService.java:300)", "org.neo4j.server.rest.web.ExtensionService.invokeGraphDatabaseExtension(ExtensionService.java:122)", "java.lang.reflect.Method.invoke(Method.java:606)", "org.neo4j.server.rest.security.SecurityFilter.doFilter(SecurityFilter.java:112)" ]
}
jimallman commented 10 years ago

I thought we had a fix for this? If there is one, please let me know how to use it.

@chinchliff : The latest fix I've seen here is to clobber ~/.m2/ (as users admin and opentree), then push again.

jar398 commented 10 years ago

I installed a fix for this, which was to delete the jar file when refreshing. Maybe the fix didn't work. Did you do 'git pull' on the opentree repo before pushing?

On Wed, Aug 6, 2014 at 12:34 AM, Jim Allman notifications@github.com wrote:

I thought we had a fix for this? If there is one, please let me know how to use it.

@chinchliff https://github.com/chinchliff : The latest fix I've seen here is to clobber ~/.m2/ (as users admin and opentree), then push again.

— Reply to this email directly or view it on GitHub https://github.com/OpenTreeOfLife/taxomachine/issues/53#issuecomment-51292834 .

jar398 commented 10 years ago

I wouldn't expect clobbering ~/.m2 to work. The problem has to do with the taxomachine build commands and is not sensitive to .m2.

On Fri, Aug 8, 2014 at 1:55 PM, Jonathan A Rees rees@mumble.net wrote:

I installed a fix for this, which was to delete the jar file when refreshing. Maybe the fix didn't work. Did you do 'git pull' on the opentree repo before pushing?

On Wed, Aug 6, 2014 at 12:34 AM, Jim Allman notifications@github.com wrote:

I thought we had a fix for this? If there is one, please let me know how to use it.

@chinchliff https://github.com/chinchliff : The latest fix I've seen here is to clobber ~/.m2/ (as users admin and opentree), then push again.

— Reply to this email directly or view it on GitHub https://github.com/OpenTreeOfLife/taxomachine/issues/53#issuecomment-51292834 .

chinchliff commented 10 years ago

@jar398, to confirm, your fix does seem to be working. I probably had not pulled those changes into my copy of the opentree repo. The service seems to be working now:

curl -X POST http://devapi.opentreeoflife.org/taxomachine/ext/OTTServices/graphdb/getFlaggedTaxonCount -H "content-type:application/json" -d '{"flag":"not_otu"}'
{
  "not_otu" : 39123
}

Is this service going to be sufficient? Can we close this issue?

chinchliff commented 10 years ago

Closing for now. Reopen as needed.