Baqend / Orestes-Bloomfilter

Library of different Bloom filters in Java with optional Redis-backing, counting and many hashing options.
Other
843 stars 245 forks source link

Question: How to implement this as a standalone server #35

Closed mezuqu closed 8 years ago

mezuqu commented 8 years ago

I couldn't find any how-to about, how I can use the software as a standalone server app, so that I can implement and use as a REST api. Should I use this with ie. play-framework?

DivineTraube commented 8 years ago

Yes, the Bloom filter can be wrapped in any kind of server. My recommendation would be to use a lightweight HTTP server to implement methods like:

In terms of an HTTP server/framework you can use anything, my recommendation would be Jetty, as it is very fast and stable. For a more high-level approach at the REST level, I would recommend a JAX-RS implementation, e.g. Restlet (see https://en.wikipedia.org/wiki/Java_API_for_RESTful_Web_Services )

While you could definitely use larger frameworks such as a Play and Dropwizard, they might be an overkill for a simple REST API around the Bloom filter.

I you would like to share your implementation of a Bloom filter microservice, I'm happy to accept a pull request.

Best, Felix