Articles Tagged ‘di’

Dependency Injection for Go with facebookgo-inject

Wednesday, November 9th, 2016

Setting up a larger application using dependency injection always requires us developers to set up our application’s object graph.

Programming in Go there is a library that eases this task for us, offering a reflect based injector to set up the graph in a few steps, named facebookgo-inject.

In the following article I’d like to demonstrate dependency injection using this library for a small sample application.

(more…)

Creating Microservices with Bootique

Sunday, September 18th, 2016

When it comes to writing microservices in Java, plenty of tools and frameworks exist. In the following tutorial, I’d like to demonstrate another minimalistic framework called Bootique by implementing a simple microservice exposing its functions either as a RESTful web-service or as a runnable command executed using the command line. (more…)

Java EE: Logging User Interaction the Aspect-Oriented Way using Interceptors

Monday, May 26th, 2014

Using dependency injection and aspect-oriented mechanisms like interceptors allow us to separate cross-cutting-concerns in our Java enterprise application, to control global aspects of our application and to avoid boilerplate code.

In the following short tutorial we’re going to create an aspect-oriented logger to protocol the initiating user, class and method called and the parameters passed to the method and finally we’re adding this interceptor to a sample RESTful web-service by adding a simple annotation.

(more…)

Search
Categories