User Email Addresses with Go-GitHub

I’ve been working on a new web app lately and decided to allow users to sign up and log in with their GitHub account. I’m using go-github to interact with the GitHub API and with this library there are two different ways to get a user’s email address. If you want to get the current user’s primary email address, use the Users.ListEmails() method. This method returns all the emails associated with the GitHub user and indicates whether the email address is their Primary address....

June 8, 2015

Flush Async Output Events

The System.Diagnostics.Process class provides the options to retrieve all output from an external process after it has completed, or to retrieve events containing the output as the execution occurs. The option to receive asynchronous output events is useful in scenarios where you need to provide user feedback or log the output when timeouts occur. When receiving asynchronous output events, you must ensure that the external process has completed when you want to make sure that you get all the output....

May 19, 2015

KENS Structured Logging Slides

Last month I gave a presentation on using Serilog, Elasticsearch and Kibana for logging from an application. You can see the slides from that presentation below. I’ve had a lot of success with this trio lately. It has provided a lot of details about what is going on in my application that would have been more difficult to obtain before.

May 11, 2015

Good Habits for Structured Logging with Serilog

Below is a collection of good habits I’ve identified in my recent experiences with structured logging. The code examples are specific to Serilog, but the ideas can be applied to other structured logging tool sets (my stack of choice for .NET projects is Serilog, Elasticsearch and Kibana). Got your own structured logging practices to contribute? Share them on Twitter! EventID When you create you log events, include an EventID property to uniquely identify the event....

March 3, 2015

Structured Logging with Serilog and ELK

ThoughtWorks recently released their Technology Radar report for January 2015 and structured logging was among the techniques that they strongly suggested that the industry adopt. I’ve actually had some exposure to structured logging over the past year and have been very happy with the results. So, I thought I would share my experience. My first exposure to structured logging was in early 2014. I was creating a simple Python application to monitor the amount traffic through my modem throughout the day and I was logging events from my application to logentries....

February 23, 2015