Story goes like this, I’m following Peter Lawrey on twitter, if you don’t know him that’s because either you’re better at Java than him and thus you didn’t had to read anything related to Java on StackOverflow in the past decade, or you’re just not programming, in which case you won’t care about what I’m going to write. OK so not even one paragraph and I’m already digressing, let’s get back on track. While browsing his blog Vanilla Java I saw an article about performance comparison between redis and OpenHFT’s SharedHashMap on May 26, 2015. I was just surprised about its final result concerning redis writes which for him culminates at 10K updates/sec using one thread, and 100K updates/sec using multithreading while OpenHFT being 300x faster. I’m not questioning super performance of OpenHFT, I’m just sceptic about poor redis performance. I’m a big big fan of redis, I use it […]

I’ve just received my new iPhone and I wanted to install MonMet on it, but I discovered that the service provided by the bus company has changed. Since my favorite bus stops were already saved on my Nexus 5 I did not saw it coming. The time table page has changed. It now displays a PNG image instead of textual content… an image. They don’t provide any public API either, so there’s no way we can retrieve the information without using some OCR magic on the image. Even the PDF version embeds an image. Who’s got time for that? I do, I do have one hour of my life to lose. So let’s open IntelliJ and just do that. I replaced the old parsing code with an OCR version using Tesseract and Tesseract4J. It’s been time since I’ve used it, so it took me some time to refresh my memory and install the dependencies (namely I was […]

PopCorn Recall is an ionic application whose goal is to recall movies you wanted to see but didn’t. It searches for movies on IMDb via omdbapi.com It’s a one night dev project, it certainly misses some love to shine. How to use Clone the repository then: cd recall-popcorn ionic run android or ios Credits Splashscreen PopCorn image come from DeviantArt by natalia-factory: http://www.deviantar.com/art/Pop-Corn-84989054 Movie information comes from IMDb via the use of the REST API at omdbapi.com Screenshots Dashboard Search for The Godfather Search detail Dashboard updated after adding The Godfather Dashboard Action Call on The Godfather Dashboard detail on the Godfather   More to come, I’m working from time to time on an application to import the whole IMDB database into Neo4J, just for fun as always. Enjoy

So while browsing the web or twitter I don’t remember, I found a blog article “Five programming problems every Software Engineer should be able to solve in less than 1 hour“, where the author explains that he’s found five little programming riddles that a Software Engineer should be able to solve easily, otherwise he’s not .. that good! I wrote a solution in Python because it shines for such challenges, it took me approximately 40 minutes, so if I trust the internet, or just that random guy, I’m definitely a Software Engineer ! How cool is that !? Next step is to print that and show my boss what a privilege it is for him to have me in his team 😉 View the code on Gist.

JOhm JOhm is a blazingly fast Object-Hash Mapping library for Java inspired by the awesome Ohm. The JOhm OHM is a modern-day avatar of the old ORM’s like Hibernate with the difference being that we are not dealing with an RDBMS here but with a NoSQL rockstar. JOhm is a library for storing objects in Redis, a persistent key-value database. JOhm is designed to be minimally-invasive and relies wholly on reflection aided by annotation hooks for persistence. The fundamental idea is to allow large existing codebases to easily plug into Redis without the need to extend framework base classes or provide excessive configuration metadata. Durable data storage is available via the Redis Append-only file (AOF). The default persistence strategy is Snapshotting. About this fork The original JOhm is not maintained anymore, there’s a lot of useful pull requests that are not being merged and the author is not responding. I […]

This is a weekend project, I wanted to use ionic framework for a complete little project. I discovered that the Met (official bus company in Metz) official application is completely bloated, you can’t search easily for bus stations, the UI is SLOW, and you can’t save favorites, nor see easily the timetable. So here it is, a small weekend project using ionic, spring boot and redis. The code is available on Github. Big problem was that the official site does not provide an API to fetch the timetables, the bus stops and so on. MonMet MonMet is a free mobile application that let user saves the time tables of his favorite bus stops and have a quick look on them whenever he wants. The application is composed of: A mobile application using ionic framework. A backend using spring boot and redis. Screenshots Dependencies Java 7 Maven 3+ Redis ionic framework […]

Sermonis, an experimentation with Websockets For the past week I did some experimentations with some interesting technologies, and at the end I had some kind of real time webchat application platform where users could create chat rooms (with or without passwords) and share URLs to friends so that they could join the discussion. The Sermonis application was born. Its goal is to provide users an easy way to deploy a simple web application that let users talk with each other without the need to install an application like Skype. Sermonis supports Markdown and password protected rooms. It‘s not aimed to grow bigger than that for the moment. Get the code The code is on Github @agrison/sermonis and you can already download it and build it. First run In order to test Sermonis on your local machine all you need is Java, Maven and mongoDB. If you want to test rapidly […]

Learning Scala I‘m really learning Scala, in depth this time. Indeed, I‘ve been reading Programming in Scala these days. While learning it I discovered what are implicits, and how cool they are. I’ll let you discover what they are by reading the following article since they explain that way better than me. A cool use of implicits is that you can extend the Scala language with cool new syntaxes features, for example what if you like the Python’s in operator ? What if you would like to have it in Scala to check if a Map contains a specific key ? With implicits it is really easy to add that kind of feature. Let‘s see how we would do that. // Declare an helper class that contains the method(s) we would like to add to Map class MapHelper[T](o: T) { def in(map: Map[T, Any]) = map.contains(o) } // Declare our […]

Releasing Some Code I‘ve been holding on my New Year Resolutions lately. I have released some code to GitHub, more precisely jssg, legacy4j. JToml: TOML for Java Yesterday while reading Hacker News a thread about TOML appeared and since there were no parser available in Java for the moment, I decided to create one, so if it can be of any use sooner or later (personal and work), it would be already done. I have already commited the code to the JToml github repository, and it supports (as for now) the whole specification made by Tom Preston-Werner on the official TOML webpage. Don‘t hesitate to fork/pull/whatever the code and add more features, more tests, enhancements and correct bugs if you find some. I will update the repository as the TOML specification goes on. Peculium I have stopped my work on peculium for the moment (not released) as I‘m learning a […]