Recent Posts

Slow Carb Diet and Book Review

general

Shortly after Epiphany I started doing the slow carb diet as outlined in the Tim Ferriss book The four Hour body. Basically slow carb is a high protein low carb diet. It seems friendly to fat in general, but I would say not as fat friendly as Paleo is. In the past I did paleo (the Primal version by Mark Sissan) and successfully lost a lot of weight, but I wanted something that I thought was a little more flexible. In the month and a half of slow carb I have lost 20 pounds. I think the rate of weight loss is slightly slower than doing paleo for me, but I think it is sustainable longer term. One interesting aspect of the diet is you can eat whatever you want on one day of the week (your cheat day). On my cheat day (Saturday) I tend to gain a pound or 2 but the weight loss the rest of the week eats this away and still leaves you with gains. I think it is an interesting aspect of the diet because now instead of saying I can’t eat X, it becomes I need to wait till Saturday to have this. Waiting a few days is much easier on the will power than saying I can’t eat this as eventually people tend to cheat. The other thing to note is even though I have been doing this diet on the weekend of my Wife’s birthday I ate whatever she wanted and we had Valentines where we ate fondue so I haven’t been entirely faithful to the diet like I was with Primal. Given how well it is working with all those aspects I will keep going with it, I would like to lose at least another 30 pounds so I am almost halfway to where I want to be.

Read more →

TIL: default hashCode() in Java

java

I came across this blog post today which I thought was really good. It is a deep dive into the default hashCode() implementation in java. To me the most amazing outcome of the piece is that if a given class is going to be accessed by multiple threads you really need to override hashCode otherwise biased locking is disabled. All in all it is an interesting look in the guts of the JVM and worth a read: default hashCode

Read more →

Sorry for the lack of updates

general

Sorry for the lack of updates. We have been busy working on a game changing micro service for our business. It has been a blast but a couple of crazy sprints. I hope to get back to more writing in the near future.

Read more →

Themes for 2017

general

Introduction

As is my tradition on this blog this is my annual post for my Themes for the year. Why themes and not goals? I feel like if you don’t hit your goals that feels like a failure, but as witnessed by my recap of last year I did a poor job of hitting my themes and was still very happy with how the year turned out. Themes are designed to be open ended and the idea is just an accountability tool for myself to make sure I am working on personal and professional growth. In the case of last year my life changes resulted in many of the themes not making sense anymore, but I still felt like there was a ton of growth so I call it a successful year.

Read more →

Recap for 2016

general

End of year recap

It’s that time again. Time to reflect on my themes for the year and see how I did on them. This is an annual tradition of mine to see how I am doing in general. I find it is a useful accountability tool for myself to make sure I am not wasting too much time on unimportant things and am spending the time that I would like on personal development.

Read more →

Upgrading from Ubuntu 14.04 -> 16.04.1 under Amazon EC2

general

The Upgrade Process

I finally got around to upgrading my web server from Ubuntu 14.04 to Ubuntu 16.04.1. I decided to jot down my experiences in case anyone else runs into these issues.

Preparation

The first thing I did prior to doing the upgrade was to run updraft plus to backup the Blog’s database and files. After that finished I logged into the Amazon EC2 console and created an image of my AMI. This way in the worst case scenario that I trashed my image I could just boot the backup image and be where I was before I began.

Read more →

MacOS Sierra Slowdown update

java , spring-boot , spring-framework

I have an update on my slowdown issues on Sierra. It appears the real problem lies in the AWS Java SDK. After talking to the spring boot people via github they were able to narrow it down to an Amazon issue. I opened an issue on github with Amazon and they responded that the version of the SDK that ships in the current spring cloud has this issue in it, and it has been fixed in a newer version of the SDK. One of the big value propositions of Spring Boot to me and the release train concept of Spring Cloud or Spring Data is that it is a collection of dependencies that have all been tested together, which lowers my risk of using them together. So I opened a request with Spring Cloud AWS to upgrade their SDK. Unfortunately they don’t seem very timely in responding to issues as I notice it looks like there are no responses on any of the issues raised in the last 2 weeks.

Read more →

AWS Lambda or should I call them nano services?

java

Recently at work I worked on a project using Amazon AWS Lambda. This is a cool concept. Amazon calls it serverless computing, but really what it is, is abstracting the server so that you can just focus on a small task that needs to run.

In this case we had a rest endpoint that just stores some data in a database.  If we think about a traditional Spring Boot Microservice we would probably do Spring Data JPA, point it at a mysql DB, and then have some rest controllers that talk to a service tier which persists the data. With Spring Boot this isn’t much code, but you still have some embedded Tomcat Server and a fair amount of ceremony for doing something very simple. After building the app you will need to deploy it to Elastic Beanstalk instance or else an EC2 Nano Instance or something similar. That is a lot of DevOps overhead to do something very simple. With Lamdba we can create a simple class that takes a pojo java object (Jackson style). With Lambda you don’t have Hibernate, you are just dealing with raw JDBC but when you are just inserting 1 Row into a Database you don’t really need am object relational mapping. You then use Amazon’s API gateway to send any requests to an endpoint to the lambda function and you are all good to go.

Read more →

TIL: debugger Javascript statement

general

Today I learned is just going to be me making a note of something interesting that I learned that might be useful for other people. I actually learned this two days ago from a coworker, but it is something I don’t want to forget.

Apparently modern browsers (at least Firefox and Chrome which is what I tested on) support putting a statement anywhere in your javascript file that is just:

Read more →

MacOS Sierra massive slowdown in Java networking

general

I upgraded to MacOS Sierra, and have really been enjoying the shared clipboard. I haven’t really noticed any other new features that impact my day to day development, however I would advise Java developers to avoid it for the near future. I have searched and searched and I wasn’t coming up with any results. Then I found this blog post. This is definitely part of the problem. I made the host file changes and got a slight boost, but not enough to explain the whole thing.

Read more →