Diary of a code trotter

Laurent Bugnion

I am really happy to welcome you here. This page displays the 10 most recent entries of my blog.

For older posts, please go to this page where you can browse the whole content.

For other content, please visit my main page at https://galasoft.ch

Thank you for your visit!!

Microsoft Ignite the Tour 2019 - 2020

Azure, Cloud Developer Advocate, Microsoft Ignite, Microsoft Ignite the Tour
See comments

In July 2019, I decided that this year again I wanted to spend most of my time in our fiscal year 2020 (July 2019 - July 2020) on our series of conferences titles Microsoft Ignite the Tour. I am very thankful to my back-then managers Bruno Borges and Tim Heuer for making this possible, and to my now-manager Scott Cate for welcoming me on the team. Scott and I have a long history and he is in fact the one who called me back then in 2017 and asked me if I wanted to interview for this brand new team called the Cloud Developer Advocates. (Since then we dropped the developer qualifier because the team has epanded to include DevOps, SRE and more.)

In July 2019 we started creating the content that we will present on the Tour. We premiered this content last week at Microsoft Ignite in Orlando, and while some adjustments are going to be applied, it's fair to say that our content was well received.

Going on the road

Starting on the 13th and 14th of November, we're taking the show on the road. We'll be there in a total of 30 locations (the bold ones are the ones where I will present):

  • Paris (13-14 Nov 2019)
  • Tokyo (5-6 Dec 2019)
  • Beijing (10-11 Dec 2019)
  • Sao Paulo (10-11 Dec 2019) TODO Check
  • Toronto (8-9 Jan 2020)
  • Shenzhen (13-14 Jan 2020)
  • London (16-17 Jan 2020)
  • Seoul (21-22 Jan 2020)
  • Osaka (23-24 Jan 2020)
  • Milan (27-28 Jan 2020)
  • Johannesburg (30-31 Jan 2020)
  • Washington DC (6-7 Feb 2020)
  • Dubai (10-11 Feb 2020)
  • Sydney (13-14 Feb 2020)
  • Taipei (17-18 Feb 2020)
  • Singapore (20-21 Feb 2020)
  • Prag (24-25 Feb 2020)
  • Copenhagen (27-28 Feb 2020)
  • Zurich (4-5 Mar 2020)
  • Amsterdam (11-12 Mar 2020)
  • Shanghai (18-19 Mar 2020)
  • Hong Kong (25-26 Mar 2020)
  • Madrid (25-26 Mar 2020)
  • Mexico City (30-31 Mar 2020)
  • Mumbai (2-3 Apr 2020)
  • Bangalore (8-9 Apr 2020)
  • Chicago (15-16 Apr 2020)
  • Tel Aviv (22-23 Apr 2020)
  • Berlin (29-30 Apr 2020)
  • Stockholm (5-6 May 2020)

I want to stress out that this is a free event and that you can take advantage of two full days of sessions, as well as meeting with hundreds of presenters from Microsoft and partners.

My sessions in Paris

Microsoft Ignite the Tour Paris

In Paris I will present three breakout sessions (45 minutes) and one theater session (20 minutes). You can find some details about these sessions and activities at the links below.

Other activities in Paris

In addition to the Tour, you will also be able to see me at two occasions in Paris.

These two events will be conducted in French.



I will have the immense pleasure to introduce Microsoft Azure to students of the "Ecole pour l'Informatique et les Techniques Avancées" in Le Kremlin-Bicêtre near Paris. There, I will present my Azure 101 session which gives an overview of some services of Azure, as well as demos on how to make these work. I am very happy to have this opportunity to speak to future software developers who will shape the future of our industry. Students will see me there on Tuesday, the 12th of November between 12PM and 1PM. This event is not public.

.NET Meetup DevTalks


Community is and will always be one on the major reasons for my team to exist. We try to connect to local user groups as often as we can when we travel. On the 12th of November, I will also be honored to speak at a local user group about .NET, and I will speak about Cognitive Services on Azure. We will also have the pleasure to hear my esteemed colleague Frank Boucher who will speak about Docker on Azure.

You can register for this free event here.

I am very much looking forward to see everyone in France!!

Happy coding


Meet me at Microsoft Ignite 2019

Cloud Developer Advocate, Microsoft Ignite, Microsoft Ignite the Tour, Work
See comments

Can you feel the excitement growing? Yes it's right, Microsoft Ignite and Microsoft Ignite the Tour are going to start soon.

Microsoft Ignite logo

Microsoft Ignite

Ignite is going to take place at the Orange County Convention Center in Orlando FL from November 4th to 8th. It is the largest Microsoft conference. It will also be the first time that I attend this show. It's also sold out, which means multiple tens of thousands of attendees will converge to Orlando soon...

To be honest I am a little worried to be overwhelmed by the sheer size of the event. But on the other hand it will be a great occasion to see all my friends and to make new ones :)

I will be quite active at Ignite and I am really excited about showing the sessions that we have been working on since, in some cases, August. It took a long time to prepare those sessions and polish them, and to prepare train-the-trainer packages (more about that later).

At Ignite, you will see me on stage at 3 occasions, and a whole lot of other occasions to connect with me:

MOD20 - Moving Your Database to Azure

CosmosDB, Azure SQL, Database Migration Service logos

In this session, I will show you how to migrate on-premises databses (MongoDB and SQL Server) to Azure (CosmosDB and Azure SQL Database). We will talk about our data offering, see how the Database Migratin Service assists you in the migration.

  • Agenda link
  • Date and time: Nov 6th, 11:45AM - 12:30PM

Here is the abstract:

Northwind kept the bulk of its data in an on-premises data center, which hosted servers running both SQL Server and MongoDB. After the acquisition, Tailwind Traders worked with the Northwind team to move their data center to Azure. In this session, you’ll see how to migrate an on-premises MongoDB database to Azure Cosmos DB and SQL Server database to an Azure SQL Server. From there, you’ll walk through performing the migration and ensuring minimal downtime while you switch over to the cloud-hosted providers.

MOD40 - Debugging and interacting with production applications

Azure Monitor logo

Here we will see multiple tools to monitor, debug and update web applications in production. This includes powerful tools like Azure Monitor, Application Insights, Log Analytics. We will also see how the Snapshot debugger can provide even more information about an issue. Finally we'll talk about one of my favorite features of App Services: Deployment slots. We'll see how these can be used to deploy new features safely, as well as perform A/B testing.

And for the abstract:

Now that Tailwind Traders is running fully on Azure, the developers must find ways to debug and interact with the production applications with minimal impact and maximal efficiency. Azure comes with a full set of tools and utilities that can be used to manage and monitor your applications. In this session, we will see how Streaming logs work to monitor the production application in live time. We will also talk about Deployment slots that enable easy A/B testing of new features and show how Snapshot Debugging can be used to live debug applications. We'll also see how other tools can be used to manage your websites and containers live.

MOD41 - Deploying and A/B testing without risks with Deployment Slots

Azure App Service logo

This session is a short 20 minutes theater session allowing us to deep dive into my favorite feature of the App Services on Azure, the Deployment slots. It's a deeper dive into one of the demos of MOD40 above. It will allow us to be more complete about safe feature deployment, where we use a staging slot as the target. Seeing how easily we can swap production and staging slots gives us great confidence, because in the worst case scenario, if an untested bug surfaces after the swap, we can easily swap back to the previous state, and take our time to fix the issue. We will also see how we can randomly redirect some of the traffic to a new slot for A/B testing. It means that some of the users will randomly see the new features, while others will still see the previous version of the site.

Here is the abstract for this theater session:

Who hasn’t been very scared when deploying a new feature to a website? Sometimes we feel that we will break everything, and the stress level is just not something we want to experience ever again. That's why the Deployment Slots feature of Azure App Services is such a nice experience. With Deployment Slots, you can deploy to a safe slot in the same conditions than your production environment. You can test in isolation, without risking breaking something. Then you can gradually route some of the traffic to the new features, for example to perform A/B testing. When you are satisfied with the results, you can simply switch the whole traffic to the new site. But don't fret, if something goes wrong, the old, safe site is just one mouse click away.

Debug bar

In addition to these sessions, I will often be available at the Debug bar. This is a place in the Development and Architecture Center where you can connect to Microsoft employees, MVPs and other partners, and talk about the topics that you love. I hope to be able to help for some issues but also to hear what you use our services for, and what you think can be improved (features, documentations, etc). Here is my schedule. I will make sure to update it if something changes, so make sure to bookmark this page!

  • Monday Nov 4th, 7:30AM - 11:00AM
  • Tuesday Nov 5th, 11AM - 1PM
  • Thursday Nov 7th, 3PM - 5:15PM

I am really looking forward to attend Ignite and to see you all there. Since I missed Build this year in Seattle, I didn't have my "fix" of first party conferences since Microsoft Ignite the Tour 2018 - 2019 ended in May. Ignite should be awesome :)

(and Ignite the Tour 2019 - 2020 starts soon, more in a future blog post soon :) )

Happy coding


My new role for fiscal year 2020

Microsoft, Microsoft Ignite the Tour, Work
See comments

At Microsoft, we are using a weird way to count the years: Our fiscal year goes from July to July for some historical reason, and so every mid-calendar year, we are faced with what other firms often do in December: Reorganizing the teams, doing accounting, finishing up the budgets...

The end of the fiscal year 2019 also marked the end of our Microsoft Ignite the Tour 2019, in which we tried quite a few new concepts. We took this tour on the road in 17 different locations, including more remote locations where Microsoft rarely has first party conferences. I've personally spoken at 9 of these locations, many of these for my first time, including Mexico City, Sao Paulo, Johannesburg, Hong Kong and more.

You can see the videos of Microsoft Ignite the Tour 2019 here.

And in 2020?

With 2020 coming up, we are already hard at work on the next edition of Microsoft Ignite the Tour. And for this edition, we go bigger and further: We will have 30 locations on 5 continents (still no edition in Antartica I am afraid :)

For me personally, this is also time for a change. I asked for and obtained a change in my activities: Starting in August (which coincidentally also marks my second anniversary at Microsoft), I will move in my good friend Scott Cate's team, and my main activity for fiscal year 2020 will be dedicated to the Tour.

Learning paths: A success that we will repeat

More specifically, I will lead one of the learning paths consisting of five breakout sessions and one theater session. It's still a bit early to reveal what this learning path will be about, but let's just say that we are building on last year's feedback, keeping what worked great and improving the few areas where we can be better. The teams are now assembled and hard at work to create the sessions.

Polymath: A polyvalent presenter

One of the things we had to deal with last year was emergency situations. One of my colleagues ended up in the hospital just a couple of days before he was supposed to be presenting (he is good now, no worries :). We managed to solve this issue thanks to a very professional team and extra work, but it was stressy.

This year we want to be better prepared. This is why in addition to leading one of the learning paths, I will also take the role of polymath. In Wikipedia, the article about polymath is illustrated by a picture of Leonardo da Vinci.

Leonardo da Vinci

Source: Wikipedia

This is of course very ambitious and none of us is seriously comparing ourselves to that great man. By extrapolation, our definition of a polymath on Microsoft Ignite the Tour is someone who learns 10 different sessions, and is able to deliver those, in case of emergency such as above, with minimal preparation and time. This is a really interesting challenge for us, which will lead us to learn even more about Azure than we would normally do.

A Cloud Advocate is (amongst other things) a professional presenter, and so it's not new for us to learn and give new sessions in a relatively short time. But a big part of the job is also to be a learner. We keep learning new technologies, new services, every day. More than ever, at 48 years old I am still learning ever day, and I just love it. The polymath role pushes me further in that activity and I just love it. Without revealing too much, I can say that the areas where I will be learning and presenting are artificial intelligence, web apps, databases, containers and more.

In the next few weeks, we will start being more precise about the content of Microsoft Ignite the Tour, and I will also detail the locations where you will be able to meet me in person. For now, you can already get ready for Microsoft Ignite the Tour and check all the locations. I am looking forward very much to meeting more people in person, and to deliver these new and updated sessions.

Happy coding! Laurent

DateTime.Now: No, no...

Azure, Technical stuff, Work
See comments

This post was cross-posted to Dev.To, an awesome community!

Recently my colleague and friend Donovan Brown was in Switzerland for customer visits and for the DotNet Day conference in Zurich. I took the occasion to spend some time with him and we got to talk (as you would expect) about geeky and "cloudy" stuff.

One topic of discussion (and that was also mentioned by one of the clients) is: What do you need to get ready for the cloud... and one topic was: Timezones!!

What time is it, really?

Because of all the regions we have, it means that your code suddenly has the potential to easily go global :) So here's a fun experiment you can do:

  1. Create a new web application. Here I use Visual Studio to create an ASP.NET Core web application with Razor pages.

  2. In the HTML code, display the local time and the UTC time. In ASP.NET, I can use the following code in the index.cshtml:

Local time: @DateTime.Now

UTC: @DateTime.UtcNow

In Razor pages, you can call C# code directly from the CSHTML markup, which is very convenient.

  1. Run the application locally. If like me you are based in Western Europe, you should see something like the below (notice the 2 hours difference between local time and UTC). If you are based somewhere else, it will vary, but there are very good chances that the Local time and the UTC time are going to be different (except of course if you happen to be in a timezone where the local time is the same as UTC).

Running the application locally

  1. Now deploy your application to Azure, into the West US region. You can do that from Visual Studio directly, or create an App Service in the Azure Portal and deploy there.

  2. Run the West US application. Now you should see the same time displayed for Local and for UTC.

Running the application in Azure


So that might be a surprise, and in fact I wasn't expecting that when I first did this experiment a few months ago.

What's going on here is that the Azure architects decided to make it easy for people to migrate web applications (App Services) from region to region without changes in code used to calculate time and time differences. So they run all the Azure servers on UTC. On the other hand, this has the disadvantage that you might have to modify your code to take this in account when you migrate from on-premises to the cloud

For example, if I am based in Switzerland and deploy my application to Western Europe (which is based in the Netherlands), I would expect my application to have the exact same DateTime.Now in Azure than locally. And yet...

The morale of the story...

The big learning here is that if you are looking to migrate to the cloud, suddenly timezones become very relevant, but not necessarily in the way that you would imagine. It's not that you need to know where your code will be running. It is that you need to know that these regional questions will be abstracted.

It would be a great idea to prepare yourself to the migration by doing the right thing already now on premises: Do not use DateTime.Now in your code but use DateTime.UtcNow instead and do the conversions where needed. This way you are already abstracting the location of your code, and when you migrate to the cloud and the location becomes irrelevant or unpredictable, your code will continue to work without being affected.

Happy coding


Creating the simplest possible ASP.NET Core form with a POST method

.NET Core, .NET Standard, ASP.NET, Razor
See comments

Simple HTML form in ASP.NET Core

Recently I needed to create a simple page for someone to submit an HTML form. The rest of the Azure aplication is running on Azure serverless functions, Logic apps and Cognitive services, but for that last part I wanted something where the user can click on a link, open the page in a web browser (probably on a mobile device), enter a passphrase in a form and then submit through a POST to an SSL encrypted page. I thought of writing a small Xamarin app and submitting through POST to an Azure Function. Another option would be to use a static HTML page and to use Javascript to submit the Form through a POST to that Azure Function. I don't exclude these two options for the future.

But in the meantime I wanted to experiment with a simple Razor page (CSHTML) that would present an HTML Form to the user, and submit this Form to itself with a POST over HTTPS.

I noticed that the documentation is not great about how to do this in the simplest possible manner and so I created an example with source code and complete instructions.

I hope this is helpful to you!

Happy coding


2018 in review, planning for 2019

Azure, Cloud Developer Advocate, Conferences, Microsoft, Personal, Work
See comments

As 2019 is starting, I want to take a moment to reflect on 2018 and think about next year.

After joining Microsoft and the Azure Cloud Developer Advocates team in August 2017, 2018 was the first full year I spent in this team. I had decided to travel a lot and speak in places I had never spoken before, connecting with developers and communities that I had never met earlier. This meant a lot of travel, but I am happy to report that all went very well, I stayed (mostly) healthy (except for a small episode of the flu probably caught on a Singapore-Zurich flight), and I learned a lot of things, both about Azure and about myself :)

The conferences

I listed below all the conferences I spoke at in 2018. There was a total of 53 sessions, some of them online, most of them in person. I loved creating and giving these sessions, but most importantly I loved connecting with the attendees. If I had to pick my two favorite events of 2018, I would probably select two user group events :


Meetup in Sao Paulo, Brazil (December 11, 2018)

.NET, .NET Standard, Conferences, Work
See comments

I am super happy to announce that on December 11, 2018, I will be presenting my session .NET Standard, .NET Core, why and how? to the .NET Sao Paulo User group.

DotNet Standard DotNet Core

You can register for this talk today! It's a free event and Microsoft will be offering free food and drinks.


Where can you find me at NDC Sydney?

Cloud Developer Advocate, Conferences, MVVM, NDC, Xamarin
See comments

NDC Sydney

As I just arrived after a long trip from Zürich to Sydney, I thought it would be good to give an update on my activities down under.


Three new videos on my YouTube channel

.NET Standard, ASP.NET, Azure, Cloud Developer Advocate, Conferences, Website
See comments

I just published three new videos on my YouTube channel. These videos are the beginning of a 14-videos series recorded live at the Modern Web Tour this July in Zurich Switzerland. You can see a recap of this session (including slides and source code) on my Presentations site.

If you like what you see, please subscribe to my YouTube channel. The more subscribers I have, the more motivated I am to create new videos :)

Title slide


Where will you see me in September and October?

Cloud Developer Advocate, Conferences
See comments

Now that the summer break is over, I am preparing myself for quite a lot of travel in the coming months until Christmas. As you will see in this post, I went a little overboard with conferences, and will have the great pleasure to present in various location where I have never spoken before. This year was quite a busy year for me in terms of speaking engagements and travel, and I am so grateful that Microsoft has given me the opportunity to touch so many people and to share knowledge about the amazing services that Azure is offering. I also started recording myself during conferences and while the editing process is not as fast as I may wish, I have already put one such presentation about .NET Standard on my YouTube channel.