First post! Let's look at open source software packages.

Preface

Hello everyone! My name is John and this is my first blog post ever. I will be mainly blogging about the work I am doing in my software portability and optimization class. Without further ado let's begin. 

Introduction

Today we'll be taking a look at two open source software packages called Cups and Tcpdump and compare their respective approach to implementing a patch. Cups is a Linux-based software which allows the user to setup local and network printers while Tcpdump is a network monitoring tool used to sniff packets.

Cups

The process to submit a patch for Cups is fairly straightforward since it is using GitHub as a platform for contributors to submit their work via forking, modifying source code and submitting a pull request. After submitting a pull request, the creator of Cups may discuss and review whether they will implement the feature requested. The patch that we will be reviewing will be about adding AirPrint support to Cups. 

The request to add support for AirPrint was brought up in 2016 but was not in development until 2021. It simply wasn't a high priority back then and there were compatibility issues. 

It was announced on February 2021 that it was possible to implement AirPrint support to Cups and a month later development started. The creator outlined a plan of how the feature is going to implemented and where the development is happening. It took around 4 days for the feature to be implemented and it involved 4 people. The creator was the most involved in implementing, revising, fixing bugs and testing the feature. The other three were there to review, revise and test as well. When a bug came up, they were logged and fixed in the process. 

With a small team, it seems the implementation happened fairly quickly. There were rarely any discussions logged on GitHub but when they do talk, they were quick to reply. If you want to see the whole process you can look here.

Tcpdump

Submitting a patch for Tcpdump is fairly similar to Cups despite both having different licenses (Tcpdump uses BSD while Cups uses Apache V2). It may be because they both use GitHub. When submitting a patch to Tcpdump, the contributor will make a pull request and someone will review it. 

We will be taking a look at this pull request. It involves adding an option to parse and print every Nth packet. The patch took over a month of reviewing and revising before it was merged to the master repo. A total of four people were involved. The user who did the pull request was the one who developed the feature. All four of them were discussing the use case, what the formatting of the option will be, possible future applications, and necessary steps to include, such as including the option in the man page, before merging. In the end it was approved and merged without creating a separate fork for development because it was a much simpler feature compared to the feature I talked about for Cups.

Conclusion

Both Cups and Tcpdump use GitHub as their choice to manage code and follow a similar approach of asking the contributor to make a pull request, people review the request, discuss, and decide whether to merge or deny. There seems to be many more people involved in Tcpdump compared to Cups. In my opinion, using GitHub is rather straight forward since contributors can seamlessly create a fork, develop a feature or fix a bug and then submit a pull request. It would be my preferred platform to work on if it were up to me.

Comments