I have been playing with ElasticSearch for a while now, both at work as well as personally. In recent discussions I came across a use case to perform faceted searches and figured this would be a good topic for a blog post. Lets explore by example how to implement faceted searches using both the older facet module as well as the newer aggregations module.
Highly experienced & passionate technologists have a challenging task in terms of figuring out their career strategies. For some this process of self discovery and adjustment works itself out quick, but for others its a harder journey. A passionate technologist often feels the need to be exposed to new cutting edge technologies and at the same time expects appropriate career growth and recognition.
Once you spend a lot of time with a set of tools there is a tendency to come up with solutions to every problem with just those tools. This narrow tunnel vision is dangerous for a techie since you can be completely blindsided when something new comes up and you are found lacking in new skills. It also inhibits the ability to learn new things and take in new ideas. Having spent a lot of time in the Java Spring tunnel, it was a welcome break for me to try out SparkJava & JDBI recently – void of any Spring, JEE or IoC.
Quick review of setting up a HTTP proxy server to front two separate projects. One containing just the UI code (html, js, css, etc.) and the other a Java Tomcat (Spring) based RESTful API backend.
If you have used ElasticSearch (ES) you will be familiar with the two ways you can access the index – the RESTful HTTP API’s and the Java API which uses a binary protocol. What is missing is a pure RESTful HTTP Java Client API. Open source Jest library attempts to fill that gap. Updated July 2016 to use ElasticSearch 2.3.4 and Jest 2.0.0.
While SpringMVC makes it quite easy to create RESTful services, this starter project adds a few things more. It provides a consistent way to send error messages in json back to the caller and also integrates Spring Security into the mix.
You must have surely heard the tag lines “Data is gold” or “Data is oil”! If not, then you heard it now. The notion is that with the right type and volume of data, you can pull out very valuable insights to help support your business/IT goals. This data might be coming from your own applications, log files, social media data, blogs, online news media, etc. Data is everywhere. And when you have that data, you want to search through it for intelligent information. That is where search engines come to the rescue. I will cover one such search engine – ElasticSearch.
Extending from some of my previous posts around the 2012 Presidential political contributions, here I will use Spring Integration, ActiveMQ, JMS and Mongodb to load the CSV data into Mongodb.
Finally got around to deploying one of my old restful applications to the open source PaaS Cloudfoundry.com. I have updated the original post with new instructions at Secure RESTful Services with Maven, Spring, Apache CXF and Spring Security.