Skip to content

Development

Base tools for bloggers

To follow up on my article about creating blog based on Jekyll, Bootstrap4, Grunt, Bower and hosted on GitHub pages, I'm adding ways of measuring and increasing the number of visitors.

This article is a quick tutorial to do the same, starting from the blog template:

  • Get to know how many visitors are caught in your blog using Google Analytics,
  • Generate a Sitemap.xml using Jekyll and feed it to Google,
  • Embed Twitter buttons,
  • And use Disqus to handle your articles comments.

How can you tell that a web developer is working?

You can hear him Grunting!

The problem

I want my blog (the one your’re reading) to be statically and freely served, using my own domain name. I want it to be maintainable and easy to update. And first of all, I really do not have much time for this, so it must be up and running in a few hours.

The solution

Bye bye WordPress, Welcome Jekyll. I can handle a couple lines of PHP but it's not my cup of tea. And WP breaks the static rule, so as the maintainable one. I previously used Jekyll to create the OctoPerf website. And as you may ask yourself why the bad joke about Grunt: I used it with Bower to create the frontend of our load testing solution.

Jekyll is a really handy tool. The kind of tool that you can use even without first reading the documentation (my preferred kind!). And when you face a problem, the solution is placed in the first 3 results of Google. The first one often being their manual that you didn't read.
But Jekyll doesn't come with dependencies management, and the couple Grunt/Bower is to JavaScript what Maven or Ant/Ivy is to Java: a nice build solution.

One year using Java 8 in production

We've been using Java8 since the beginning of our startup. Java8 was released on 18 March 2014. We started using Java in September 2014, when AWS made it available on ElasticBeanStalk. At this time, Java 8 was available for almost 6 months. It was mature enough to give it a try.

Frameworks compatible with Java 8 like Spring 4.0 started to be available. Java 8 is a huge step forward compared to Java 7 :

  • Lambdas: concise way to write Function and Predicate, a step toward functional programming,
  • New Apis: Optional, Streams, Dates,
  • Default Methods: define default method behavior in interfaces.

One year later, what did we really use? How did we use it? These are some of the questions we're going to answer.

What about Guava

Guava is a Google Utility API. Before Java 8, we were widely using Guava's features like Predicate, Function, Optional and more. We feel like Java 8 brings almost everything what Guava is providing. We gradually replace Guava features by their Java 8 equivalent.

The question whether to keep Guava or not is a good question. Java 8 picks a great number of features from Guava, and it's not a surprise. Guava is one of the most famous Java API, just behind JUnit.

Unit testing AngularJS directives

As we are currently working on marketing our load testing solution we don't get much time left for coding. We identified some issues that could spoil user experience. It could make us loose some prospects.

So I took one day off backlinking / mailing / phoning / marketing to return to my beloved IDE. One day of coding in six weeks, it feels like holidays! I took the opportunity to improve our frontend SonarQube metrics. We now have only 5 hours left of technical debt. Not as well as the backend code quality, but it is on the right track:

Technical debt

I fixed a large part of the issues and started to unit tests our AngularJS directives using Karma.

From Java to JavaScript

Our load testing platform, OctoPerf, has its frontend made using AngularJs. But it was not always the case, and this article describes the journey that led us to this choice.

Java was all I knew

When I graduated in 2007, all I wanted was to perfect my Java skills. I spent years as a consultant in several companies, chowing down Struts or JSF, Ant and Maven. I also created personal projects to learn JBoss Seam or GWT. Many of these previously trending technologies are outdated now.

Java and its ecosystem were all I knew, and all I wanted to know. The little prick I was, looked at PHP or JS developers with disdain. I was convinced that Java would be the best solution to any problem. I was convinced that I could create web applications without writing HTML or CSS.

You already know that i was wrong. silver bullet is a myth!