guilhebl

Philosophical writings about programming and technology

Testing Scala Play application using Mock and GuiceApplicationBuilder

In this example the controller class Product Controller fetches data from an external service called DataService. Since we can't call real APIs during Test we need to mock these 3rd Party services and return a...
Read more...
12 July 2017

Finding K(th) Max or Min element of a collection

Frequently in software development projects there's a need for programmers to find the Kth smallest or largest element in a designated collection, in these use cases many are the approaces to fetch the Kth element...
Read more...
30 June 2017

Finding minimum size distance of a group of keywords in a document

An interesting problem that happens to be very common in search engine realms is to find the shortest snippet of text containing a certain group of keywords in a document. The solution for the problem...
Read more...
22 June 2017

Scala Url Shortener

Url Shortener Built Scala Url Shortener based on existing github java version.
Read more...
08 May 2017

Offer web v1 Angular1 code released on Github

Offer web Angular1 front-end webapp Search Prod Angular1 front-end app is now available on Github as an open-source project. Frontend github project link Previous Angular1 Frontend app code can be found at project github page...
Read more...
08 May 2017

Full-stack end-to-end reactive webapp - React/Redux and Spring 5 Reactive Streams

Item Shop - Fullstack end-to-end Reactive webapp Built an end-to-end sample reactive webapp that utilizes reactive streams in order to enable asynchronous stream processing with non-blocking back pressure, offering better scalability and capacity than traditional...
Read more...
03 April 2017

Print current path in Java

Printing current path When coding in Java I found myself having to print the current path of the executing JVM program in order to troubleshoot File not Found exceptions and other file-system related issues. There...
Read more...
06 March 2017

Unit Test generation tool

Automatic Unit test generation There are some tools for generating unit tests based on source files. Some tools come handy with an error revealing test mechanism, so it basically generates error revealing tests on top...
Read more...
13 February 2017