We should bring our will into harmony with whatever happens, so that nothing happens against our will and nothing that we wish for fails to happen. Epictetus

Keep Your Rational Soul

No one is crushed by fortune, unless they are first deceived by her…those who aren’t pompous in good times, don’t have their bubbles burst with change. Against either circumstance, the stable person keeps their rational soul invincible, for it’s precisely in the good times they prove their strength against adversity. Seneca

Make Your Own Good Fortune

You say, good fortune used to meet you at every corner. But the fortunate person is the one who gives themselves a good fortune. And good fortunes are a well timed soul, good impulses, and good actions. Marcus Aurelius

No One Can Impede Your Intention

While it’s true that someone can impede our actions, they cannot impede our intentions and our attitudes, which have the power of being conditional and adaptable. For the mind adapts and converts any obstacle to its action into a means of achieving it. That which is an impediment to action is turned to advance action. The obstacle on the path becomes the way. ~ Marcus Aurelius

The Obstacle is the Way

Today’s stoic quote and mediation is a basic one. Something I’ve been thinking of every few weeks for the past few years, and I think really shores up what this philosophy is about. The impediment to action advances action. What stands in the way becomes the way. ~Marcus Aurelius

Management Mondays

I wear many hats at work. Sometimes I’m a developer, sometimes I’m an architect, and there are times when I play manager. I don’t particuarly enjoy management as much as the other three roles, and it rightly so takes time to do. Recently, I have been having a hard time making time for these management tasks. As you can imagine, leading a team of developers while also writing code leaves little actionable time for management.

DotNet Core with Shibboleth

One of the more difficult and painful changes while migrating our enterprise applciations to DotNet Core has been supporting Shibboleth authentication and consequently, implementing our group based authorization system. There are a few main things we have to implement in our applications in order to leverage Shibboleth. Grab the current logged in users login name, in our case it is a custom username called eName Establish a local cookie based login scheme for the dot net app Additionally, we use a custom group based authorization system that accepts an eName and returns a list of groups associated with that user.

Foreign Key Dropdowns with .NET MVC 5

One of the more difficult form controls in web development is adding drop downs for foreign key relationships. .NET MVC gives you several different options for generating form markup from different types of models. However, the method for foreign keys and drop down lists is a bit more work than the rest. Given the following models: JobPosting.cs using System; using System.Collections.Generic; using System.Linq; using System.Web; namespace CMJobs.Models { public class JobPosting { public JobPosting() { this.

Global Template Objects with .NET MVC 5

In modern web applications it is often convienient to have certain content or database object available to all views throughout an application. Good examples of this are avatars, usernames, and user content such as first and last names, and email addresses. Most modern web frameworks have an easy way to accomplish this. For instance, Django has middleware which can fairly easily be added to the request/response stack in order to inject objects or content into the global view/template context.

Custom Authorize Attribute in .Net MVC

I’ve recently been doing most of my coding within the .Net space. As such I’ve found myself trying to repeat several of the patterns available within the Django Framework. One of those common patterns is authentication/authorization and easy ways to apply these to various controllers/views. It’s sometimes necessary to restrict access to certain views based upon more than a user role. For instance, you may only want to allow the owner of an object (or and Admin) to be able to remove or modify that object within the application.