Day 5 of Coronavirus WFH

March 20th, 2020

Microbe

Things are really escalating now... the Governor of Illinois is talking about issuing a shelter-in-place order for the entire State. That's some serious stuff. We will still be able to go to the grocery store, and drive-thru food, etc. but the casual trips out, and the large collections of people are over for now.

This has been a little creepy for me, but I'm able to take care of things, get food, and while there is rationing happening at the grocery store: 1 gal of milk... 1 bread item... 1 paper product... it's not horrible, and the point is that it's just temporary, and as soon as the trucks and logistics get geared up, then we'll be able to see normal supply again.

But for now... it's stepped up to the next phase, and it'll be a while before things get back to normal.

Day 4 of Coronavirus WFH

March 19th, 2020

Microbe

Things are getting worse, as the numbers climb. At this point, things are getting out of hand, and the news is changing almost hourly. The markets have been up and down, but The Shop is asking people not to come into the office unless it's an emergency.

Pretty quick change for just three days. But that's what'll happen when you have something like this happen. It's certainly reminding me of all the viral outbreak movies you see - and while the mortality rate isn't like Ebola, it's bad enough, and that's reason enough to take this all very seriously.

Day 1 of Coronavirus WFH

March 16th, 2020

Microbe

The Coronavirus is spreading, and The Shop has said that if we aren't comfortable going into the office, it is acceptable to work from home (WFH) - after checking with your manager. Since I'd checked with my manager on just this issue last week, I was ready to start this week WFH for sure.

I don't believe the office is bad... but the Metro and Shuttle are going to be horrible - simply because many people will have the light version of the disease and spread it to many others. That's not their fault - they wouldn't necessarily know... but I could get it - and then unwittingly spread it to others. That's bad.

So I'm going to WFH and see how things play out. After all... I'm every bit as productive here as I am at the office.

Interesting Interoperability C++ to Java

March 9th, 2020

GraalVM

I have always hoped that GraalVM would be something that really launched Clojure, and Java, into something that would be fast - and like really fast. But then it was a licensing issue as GraalVM was licensed by Oracle, and so any production deployment was going to cost real money. But even then... for a company, that might not be bad - especially when you have to worry about performance, and you are looking at JNI, or a mixed-mode environment with C++.

So it was very interesting to me to see this article about calling Java from C++, with the GraalVM compiling Java to a shared library (and header), that could then be linked in with C++ like any other shared library.

The key is that this would completely avoid JNI, and it's complications - in coding, versioning, and execution speed. I can imagine having lots of Java code, built and tested in the normal Java way, and then compiled into a shared library for inclusion in a much more performant C++ system for those engines that had to run for long periods of time without restarts, and be very aware of resource management (memory, ports, etc.) and yet built with a simpler system than C++.

The article is interesting, but again... with the licensing, it's only really useful for organizations with revenue streams to support it.

Ordered Another Messenger Bag

February 25th, 2020

Chrome Bag

I've been noticing that my Chrome messenger bag hasn't been as full as it used to be. And while it's in great shape, I was hoping to get the slightly smaller Citizen Messenger Bag from Chrome

The closest thing they have now to what I typically carry is the Berlin, as it's big, but not in a horrible way. I can typically take my laptop, chargers, and everything - plus three days clothes - all in the big bag, and it's perfect for sailing through airports.

But I will admit, it's a touch big for under the seat, and so I wanted to see about going with the Citizen, and seeing if I could put everything in it, and not feel cramped. It should fit under the airline seat better, and as long as it's all there, I'm better off carrying that and my duffel bag, than one big bag.

We will see when it arrives! 🙂

Upgrading Postgres 11.1 to 12.1 Using Homebrew

February 4th, 2020

PostgreSQL.jpg

It's time to make sure that my laptop has the latest version of PostgreSQL, as I was reading that Heroku was moving to Postgres 12 as their default database. And since I don't do it that often, I decided to write it all down so that it's easier to do next time.

The process isn't bad... dump all the databases into one file, stop the server, update Homebrew, update postgres. This gets us to the point that we are ready to rebuild the new database:

  $ pg_dumpall > dump.sql
  $ brew services stop postgresql
  $ brew update
  $ brew upgrade postgres

Now we need to move out the old database data, create a new structure, and restart the service:

  $ cd /usr/local/var
  $ mv postgres postgres.old
  $ initdb -D /usr/local/var/postgres
  $ brew services start postgresql

You then need to go back to the directory of the first command - the one where you dumped the databases, and reload them all:

  $ psql -d postgres -f dump.sql

and at this point, everything should be back and running:

  $ psql --version
  psql (PostgreSQL) 12.1
  $ psql -l
                                      List of databases
      Name     | Owner | Encoding  |    Collate     |     Ctype      |  Access privileges
  -------------+-------+-----------+----------------+----------------+---------------------
   health      | drbob | SQL_ASCII | en_US.US-ASCII | en_US.US-ASCII |
   inventory   | drbob | SQL_ASCII | en_US.US-ASCII | en_US.US-ASCII |
   northhollow | drbob | SQL_ASCII | en_US.US-ASCII | en_US.US-ASCII |
   postgres    | drbob | SQL_ASCII | en_US.US-ASCII | en_US.US-ASCII |
   template0   | drbob | SQL_ASCII | en_US.US-ASCII | en_US.US-ASCII | =c/drbob           +
               |       |           |                |                | drbob=CTc/drbob
   template1   | drbob | SQL_ASCII | en_US.US-ASCII | en_US.US-ASCII | drbob=CTc/drbob    +
               |       |           |                |                | =c/drbob           +
               |       |           |                |                | _postgres=CTc/drbob+
               |       |           |                |                | postgres=CTc/drbob
   test        | drbob | SQL_ASCII | en_US.US-ASCII | en_US.US-ASCII |
  (7 rows)

At this point you can remove the old data:

  $ rm -rf /usr/local/var/postgres.old
  $ rm dump.sql

and everything is updated. You can then use any of the normal tools, including the Apache/PHP/Postgres that Apple makes available, and Postico - a great GUI client.

UPDATE: a friend asked: "What's in 12?" and I had to say I really didn't know... so I looked it up. The big changes are all about under-the-hood performance, and so, as I suspected, it just "works better". Which is really the goal, right? 🙂

I know I will probably enjoy the JIT on by default, as there are plenty of times stored procedures are in my databases, and that makes them faster, which is always nice. But it's just a great database - getting greater.

Trying out a new Editor Font

January 21st, 2020

GeneralDev.jpg

A few days ago, I read about the new JetBrains Mono font that they had created for their IDEs, and it looks interesting with the increased hight of the lower-case letters, and the easily readable "1lI" combination... so I decided to give it a whirl on my editor, and in Xcode.

I have to say I like how Sublime Text and Xcode handles all the weights of the font, and the ligatures for common expressions makes it a lot easier to read the code - as if I'd written it on a chalkboard. Very nice indeed

JetBrains Mono for Clojure

I'm not sure how it'll play out, but it's pretty nice so far, and I'll play with it for a bit and see what I think. So far... nice. 🙂

Heading out to Seattle for Work

January 12th, 2020

cubeLifeView.gif

I'm all packed up and ready to head to O'Hare for my flight to Seattle. The Shop is having some off-site meetings, so I'm going to fly out today, have two full days of meetings and activities, and then a day there to visit with the teams in Seattle that I typically only get to see on Hangouts, and then fly back on Thursday. It's not bad at all... but the flight will be long, and I'll need to find my happy place and just relax for the 4+ hrs in the small seat.

For this trip, I put all my IMAP email accounts on my iPad so that I could take it with me for notes and essential emails, and it's not a lot more to carry in my bag. Yeah, I'll have to take it out at the security checkpoint, but that's worth it to be able to take everything it holds with me. I really think it'll work out well.

I've plotted the route to the O'Hare economy lot into my car, and should be able to just get things loaded up, and on the road. Just need to stay calm for the flight... 🙂

Finished Advent of Code 2019

January 7th, 2020

Christmas Tree

This morning I finally finished Advent of Code 2019. Most days weren't too bad - I think the ones that really caused me to work extra were Day 18 and Day 20 - both of which were the pathing problems that I had failed to really master in years past. Good or bad, I decided not to give up on these, and figured out how to solve these this year.

Dijkstra's Algorithm is interesting, but I really didn't see how to implement it in Clojure until I was walking home one day - and it hit me: the recursion really made it all so much easier. And that really helped me as I hammered on these problems this year to really get a solid understanding of how to work with Dijkstra's. I'm very glad I stuck with this.

Then when I had that understood, I ran into Day 20 where it wasn't the right approach, but I needed to understand a simple Breadth-First Search on the maze. This is much different than Dijkstra's in that it's a simple looping construct, and only finds the one shortest path - but that's OK... that's all that was asked for. But it's fast. Very.

I'm really glad that this year I didn't stop when the problems seemed to be too tough for me. I'm a better coder because of the new knowledge. 🙂

Welcome to the New Year!

January 1st, 2020

Path

Well... another year has arrived, and interestingly enough, I was awake when it arrived in Naperville. Not that I had stayed awake, but that I woke up in the night and saw the time, and then heard to festivities outside. It made me smile.

Tomorrow starts another year at The Shop, and there's plenty that's going on there, and I'm sure there will be lots and lots of things that will occupy my time. There's a big engineering meeting in Seattle in a week or so, and that will travel which isn't as bad as it used to be, but it's being away from home, and I do enjoy home.

I do hope that this year is a little more peaceful...