Azure Webjobs, Application Insights, and You: A Vaguely Comprehensive Guide

When I was learning to code, it wasn’t hard to find out what was going on in my applications. Typically, especially in classes, I was sending output to a console–super easy, instant feedback. A few times I didn’t have a console to watch, I was writing things to a text file I could open immediately. Also easy. As things went on, and they had us actually playing with webapps and javascript and HTML, the feedback was again instant. I would know immediately if my program was behaving.

Then I get a few weeks into my internship, and there’s this new idea: a webjob. Essentially, a console app that runs on the cloud for background tasks. They’re awesome…until they start doing weird things while deployed. Azure gives you a couple hundred lines of debug console for free, but that’s just not a sustainable solution. This was the point my boss said some vague words about “App Insights” and pointed at an example the other developer had worked out a while back (modified from a guide neither of us were able to locate).

It took me quite a while to figure out how to even configure Application Insights in the webjob, and even longer to really zero in on how to use it intelligently. So I wanted to combine some of that hard-earned knowledge in a very long walk thru. We put together a toy app inside the webjob template, and configure it to run and send telemetry to an Application Insights resource.

The final code from this project is in a repo you’re more than welcome to.

Continue reading “Azure Webjobs, Application Insights, and You: A Vaguely Comprehensive Guide”

M*A*S*H and Single Responsibility

If you haven’t heard of the TV show M*A*S*H, it’s based on an equally excellent movie by the same name. It has exactly nothing to do with coding, software development, business, or anything else you might think is germane to this blog. Except that I watch a lot of it (may have even gotten a Hulu subscription JUST to take advantage of their recent acquisition of the show). Like most art you consume a boatload of it will eventually worm its way into the rest of your life.

Most recently, I had to use a Charles Winchester quote to remind myself of the Single Responsibility Principle.

“I do one thing at a time. I do it very well. And then I move on.”

— Major Charles Emerson Winchester, III

You see where this is going, right?

Continue reading “M*A*S*H and Single Responsibility”

Blog at WordPress.com.

Up ↑