Showing posts with label open-source. Show all posts
Showing posts with label open-source. Show all posts

Friday, February 08, 2019

Fosdem 2019


This year I managed for the first time to attend Fosdem in Brussels. Since I started to be involved in open source software I always wanted to go, but somehow something else always came up. This time I made an early effort to book my vacation days, hotel and flight.
I stayed at the Bedford Hotel & Congress Center, which was the worst part of the whole trip. Just avoid it.


I never been to Brussels and for some reason thought it would be a bit of a dump with an European Government ghetto attached. But it is quite the opposite, a very charming town with lots of things to do. I checked out the Atomium, House of European History, Veloseum and the Natural History Museum.
There are many statues, parks and gratifies spread around the city to keep you busy. 
Most of the time I spend walking around the city and checking out the old buildings and cobblestone streets. I obviously also had fries and waffles.




Fosdem is a pretty big conference with many parallel tracks. Because it was my first time I took the easiest path and just stayed in the main room where all the keynotes were happening. Some were more attended than others, but the room was always pretty full. Here is a list of the talks I followed, with a link to the official website, some have the videos already attached. 

FLOSS, the Internet and the Future
https://fosdem.org/2019/schedule/event/floss_internet_future/

Blockchain: The Ethical Considerations
https://fosdem.org/2019/schedule/event/blockchain_ethics/ 
Very much a high level talk, but presented very well and entertaining.

Mattermost’s Approach to Layered Extensibility in Open Source
https://fosdem.org/2019/schedule/event/mattermost_layered_extensibility/ 
Mostly a commercial for Mattermost, not much about layering. 

Matrix in the French State
What happens when a government adopts open source & open standards for all its internal communication?
https://fosdem.org/2019/schedule/event/matrix_french_state/ 
I never heard of matrix before, it looks like a very interesting project and it is cool to see it adapted by the French government. I tried it out myself, but it is still pretty buggy - at least the registration process.

Solid: taking back the Web through decentralization
App development as we know it will radically change
https://fosdem.org/2019/schedule/event/solid_web_decentralization/
I read about this on lwn.net . To make this useful in any way it has to be widely adopted, which seems unlikely. Like the semantic web it is a developers dream, that always seems to be in the near future.

The Current and Future Tor Project
Updates from the Tor Project
https://fosdem.org/2019/schedule/event/tor_project/ 
Very cool to see how Tor is moving and adapting to allow more people to enjoy privacy. Certainly got me to install the Tor Browser on my mobile and thinking about running a Tor node.

Algorithmic Sovereignty and the state of community-driven open source development
Is there a radical interface pedagogy for algorithmic governementality?
https://fosdem.org/2019/schedule/event/algorithmic_sovereignty/

Open Source at DuckDuckGo
Raising the Standard of Trust Online
https://fosdem.org/2019/schedule/event/duckduckgo_open_source/ 
For me it still has to go a long way before it can replace Google in my daily life. But it is the default in the Tor Browser, so I’ll see how it goes. They also have some additional tools to help with privacy, which looked pretty useful. 

Crostini: A Linux Desktop on ChromeOS
https://fosdem.org/2019/schedule/event/crostini/ 
An infomercial from Google. 

Open Source C#, .NET, and Blazor - everywhere PLUS WebAssembly
https://fosdem.org/2019/schedule/event/open_source_microsoft/ 
I planned to use this slot to get some food, but I am glad I didn’t. Very entertaining talk about the portability of C# code all demoed live with use cases in CLI, Web, micro computer and micro controller. I just still have a deep seated mistrust in Microsoft, so I am not ready to look into C#. 

The Cloud is Just Another Sun
https://fosdem.org/2019/schedule/event/cloud_is_another_sun/ 
I am worried myself of using cloud services like AWS where I am locked in to some software, but some of the services are just so convenient and cheap that it makes sense for a business. 

2019 - Fifty years of Unix and Linux advances
https://fosdem.org/2019/schedule/event/keynote_fifty_years_unix/
Maddog giving a very long talk about the history of Unix, it made me feel old and young at the same time.


Saturday, May 18, 2013

A Code Review and Continuous Integration Workflow

As hopefully most people working on software projects nowadays we are writing unit tests and do code reviews.

Work-flow at Splendia

As our project is a large PHP site we are using PHPUnit for unit testing and various static code checking tools (checkstyle, phpmd, pdepend, phpcpd) to verify the quality of our code.

All of these are run on our integration branch, whenever a new feature is integrated.

Before this can happen the code will be reviewed by other people in the team and only if there is a consensus it will be merged into the integration branch.

For the code reviews we are using the pull request system of github. It works very similar to other code review tools, you see a diff view of the changes and are able to add comments to discuss the code.

In these comments we are using a convention of "+1", "-1" and "[B]" to give the pull request a thumbs up, down or mark it as blocked because a critical bug was found. Anyone in the team has a vote and is allowed to discuss any request.

In addition to this the unit tests and some smoke tests will be run on the code of the pull request to avoid merging broken builds.

Only if the tests are successful, there are three positive votes in total and no blocker the request will be merged.

In the beginning all of this was done manually. Developers had to run the tests before the created the pull request and only senior developers had the right to merge a pull request. Every couple of hours they would check the list of pull requests and verify that they had enough votes. It was a distraction and also prone to mistakes.

What gave us a big push in productivity was the introduction of two tools to the work-flow.

ghprb

First the GitHub pull request builder plugin, which enables Jenkins to automatically start a job for each pull request. It has additional features, like starting another build if more commits are added or recognising comments that instruct it to retest or white-list people who are allowed to create builds. It is similar to the pull request feature of Travis-CI only with the full possibilities of Jenkins to your disposal.
With this we are testing every pull request before it gets merged. We also run a limited set of static code analysis, because we want to keep this build fast to give quick feedback. Currently it takes around seven minutes.

PullRequester / plus-pull

The second tool is a simple script which was written by one of our developers and it was called PullRequester. It runs as a cron job and checks whether the pull requests satisfy the +1 and successful test rules. If all is OK it automatically merges it.
I have reimplemented this script to make it possible to publish it. You can find it under the name plus-pull on github. I have added some more features to make it also useful for open source projects.

Final Words

Even though these tools are not magic the increase of our productivity was visible. I account this mostly to way it enabled asynchronous working. No developer has to wait for a senior developer or poke someone to merge his code. As long as he can find three people who agree it will be merged automatically. And as everyone is interested in reviews themselves they tend to happen quickly.

In the screen-shot you can see how this works in practice.