Switching from Essentials4J to Kotlin

At work we have a project that used Essentials4J, and its predecessor Rapidoid Fluent, to simplify some stream/collection APIs. We have been converting this project to Kotlin, and no longer need that library. The conversion was very simple. It highlights some of the things you can do with collections with Kotlin’s standard library. Do.group(…).by(…) Do.map(…).to(…) …

Switching from Essentials4J to Kotlin Read More »

No Credit Score and Renting a Car

I recently learned 1) I have zero credit score, and 2) some rental car companies won’t rent to you if you do not have a credit score. Read more…

The Dumbest Thing We Did With Money

Where I work, we have this concept of Stupid Tax – when someone does something stupid and it costs them money. My wife and I thankfully haven’t had too much stupid tax, but we did have one big expense that came down to me stupidly holding on to something that was “mine”.

Salesforce and Amazon SQS

One final post from the old company blog, from March, 2011. A couple of us are working on a new project that involves Salesforce CRM. We recently came upon a few technical challenges related to our need to keep a subset of the data stored in the cloud in-sync with our internal application servers. These include: …

Salesforce and Amazon SQS Read More »

3 Ways to Become a Digital Lumberjack

Restored using the Wayback machine from: https://www.developwithpurpose.com/digital-lumberjack/ When we had our development team blog, our content team would edit our posts. This one was very different before it went in to copy editing, I had embellished the lumberjack metaphor a lot more than this, and they cut it back. Also, I took out the clickbait title. …

3 Ways to Become a Digital Lumberjack Read More »

Optimizing a SQLite Database

TL:DR; takeaways: These seem very obvious, but with rushed deadlines, and “it works well enough”, these things are sometimes overlooked. Use the right data type for the job. If the documentation says VARCHAR when the values are always integers, maybe you should use INT. Generate a proper primary key when you can, skip indexes that …

Optimizing a SQLite Database Read More »

The Love of my Live

An excellent wife who can find? She is far more precious than jewels. The heart of her husband trusts in her, and he will have no lack of gain. She does him good, and not harm, all the days of her life. (Proverbs 31:10-12, ESV) A little over twelve years ago, I was a very nerdy, very much single guy …

The Love of my Live Read More »

Postal Code Voroni Diagram

The links in this article point to a free Heroku instance, which can shut down due to inactivity. It may take a few seconds for the instance to start up. I’ve uploaded a little experiment to Heroku, showing something I toyed around with a couple years ago. Would it be possible to approximate a map …

Postal Code Voroni Diagram Read More »

Using Consumer in Spring Validator to validate nested collections

In one of my projects I have a custom Spring Validator that validates a nested object structure, and adds per-field error messages. As an example, a field nested inside an array might produce an error like the following: array[0].field must be a valid value The Errors object works as a stack, so field names have to …

Using Consumer in Spring Validator to validate nested collections Read More »

Hibernate Logging Options

For years I have relied on a simple property “show-sql=true” to see Hibernate’s generated SQL. This option is fairly limited: it bypasses the logging framework in the rest of my apps (SLF4J) it doesnt show parameters, just question marks it doesn’t show any timing information Frustrated at these limitations, I set out to understand all …

Hibernate Logging Options Read More »

Sql Quickie: Find zipcodes near the center of a region

At work we have a copy of the zip-codes.com Business database, which I tend to reference somewhat frequently due to the nature of projects I work on. Today I needed a list of postal codes from major metro areas, which would be used to drive a test data generator. The data generator has access to …

Sql Quickie: Find zipcodes near the center of a region Read More »

Salesforce: Serializing Objects from a Managed Package

I’m currently working on a Salesforce project that utilizes a few home-built managed packages. There are lots of restrictions of what you can and can’t do with managed package, and most of those are documented fairly clearly. Some, however, are somewhat hidden. One such restriction is this: Only custom objects, which are sObject types, of …

Salesforce: Serializing Objects from a Managed Package Read More »

2015 Goals

Last year I wrote a series of posts about my goals for the year. With the start of a new year, it is time for a fresh set of goals. Goals, not Resolutions I was introduced to the concept of setting real, measurable goals a few years ago – goals that are supposed to be …

2015 Goals Read More »

Naming a class in Salesforce the same as a built in interface

I am currently working on a small managed package for a Salesforce project. One of the nice things you can do inside of managed packages is create post-install scripts, which are sort of like migrations in Rails. For some reason, I kept getting a compiler error when I created even the simples of install handlers: …

Naming a class in Salesforce the same as a built in interface Read More »

Troubleshooting a SQL Server Implicit Conversion Issue

Over the last couple of weeks, I have been spending some time troubleshooting performance issues in some of our Java-based RESTful services. This week I came across one that required some different steps to troubleshoot. First, the tl;dr – our JDBC driver (jTDS) converts CHAR to NCHAR, which causes an index SCAN on a CHAR …

Troubleshooting a SQL Server Implicit Conversion Issue Read More »

Researching Child Car Safety

My wife and I have an unwritten rule about how we raise our kids: Make decisions about how to raise our kids using the best information we can find, without being paranoid, second guessing, or spending every waking hour reading every opinion about how to parent. Ok, maybe that’s not really as concise as the …

Researching Child Car Safety Read More »

Java 8: Optional

A fellow developer today asked me a question about the Optional interface in Java 8. My team is still working on a Java 6 stack, but his team is blazing the trail to Java 8. I’ve used Optional a little bit in some side work, and I am a little more familiar with Guava’s version. His use case …

Java 8: Optional Read More »

Life Insurance: Why?

Let’s talk about a really fun topic today: life insurance. Before we get to that exciting topic, I want to excite you even more with a short meta-post. I sat down and started to write this really long post – what would have amounted to 5+ pages, complete with tables and numbers – and realized that I …

Life Insurance: Why? Read More »

A Cappella Worship Resources

Where my family worships we are a bit “weird”. We currently worship at a building bearing the name “Church of Christ” in Franklin, TN. What is strange, at least according to many followers of Christ in the United States, is our form of worship. We worship exclusively and collectively with our voices – no piano, no guitars, and no iPads. …

A Cappella Worship Resources Read More »

Mockito AdditionalAnswers

Sometimes you use a framework for years, and then discover something new that it can do. I had one of those moments today with Mockito. I have an API that I am mocking, where I need to capture the argument passed in for further testing, that had a line that ended up looking something like this: …

Mockito AdditionalAnswers Read More »

2014 Goal – Last Will

This should be the last in a series of posts about my family’s goals for the year 2014. Thank you for reading. I hope I haven’t been annoyingly personal. It has been my hope that maybe someone out there has struggled with goals, and might gain some ideas from me speaking about our thoughts that went into our …

2014 Goal – Last Will Read More »

2014 Goal – Run

This is the second in four posts about goals for 2014. Goal 1: Be An Encourager Goal 2: Run Goal 3: Mortgage Reduction Goal 4: Last Will Waiting for the end to come… Wishing I had strength to stand… This is not what I had planned… It’s out of my control…. Linkin Park – Waiting …

2014 Goal – Run Read More »

Welcome to the Future

I wish they could see this now The world they say is changing oh ‘Cause I was on a video chat this morning With a company in Tokyo Hey, everyday is a revolution Welcome to the future — “Welcome to the Future”, Brad Paisley Earlier this year I had one of those “wow, we are living in the future …

Welcome to the Future Read More »

Upgrading an Older Desktop

If you follow desktop computer trents, chances are you know that Solid State Disks, or SSD, are quickly replacing Hard Disk Drives as the storage medium of choice. SSDs are more expensive per GB of storage than their spinning relatives, but make up for the smaller space by being much faster. I’ve had an SSD for over …

Upgrading an Older Desktop Read More »

IE9 Print Stylesheet Issues

Over the past two years, I have had the pleasure of fixing two issues with printing from Internet Explorer 9. Both of the problems deal with IE-specific “filter” attributes in CSS. We have an application that is used by an audience that deals with a lot of paperwork. They like to print information from our application to add to …

IE9 Print Stylesheet Issues Read More »

Let Your Words Be Few

Don’t be rash with your mouth, and don’t let your heart be hasty to utter anything before God; for God is in heaven, and you on earth. Therefore let your words be few. For as a dream comes with a multitude of cares, so a fool’s speech with a multitude of words. — Ecclesiastes 5:2-3 …

Let Your Words Be Few Read More »

Private Insurance

It has been a long time since I have written anything of substance, so why not break the hiatus and write about a very exciting subject – health insurance. Maybe this is a bit personal, but I am not going to reveal how much my family earns, nor how much of our income as a percentage is …

Private Insurance Read More »

Writing

I have been going to old sites where I used to blog, and am trying to consolidate anything that may matter and bring it here before shutting down those services. I came across a site where I used to write, Pleonast, and realized I had not posted there in over 2 years, yet, I had …

Writing Read More »

Clearing Pleonast

It has been around 2 years since I last posted on Pleo. I am going to start taking the content down, and move it over to my personal blog at danwatt.org.

Full Spring 3.1 Config

Someone asked for my full Spring 3.1 annotation configuration. I’ve stripped all domain-specific information, but the overall structure is intact. SpringConfig.java – this is the top level class, is empty except for @ComponentScan and @Import statements. The web.xml references this. SpringMvcConfiguration – Any MVC related configuration DatabaseConfiguration @Configuration @ComponentScan(basePackageClasses = { SpringConfig.class}) @Import({ SpringMvcConfiguration.class, DatabaseConfiguration.class}) …

Full Spring 3.1 Config Read More »

Spring 3.1, No-XML, Hibernate, Cglib, and PermGen errors

Lately I have been maintaining several Spring-MVC applications written from the ground up with Spring 3.1. They use the purely Java based configuration scheme that comes in version 3.1, Hibernate. The apps do not have the pattern of “an interface for every class” that some Spring apps have, so it proxies concrete classes using Cglib. …

Spring 3.1, No-XML, Hibernate, Cglib, and PermGen errors Read More »

Making Java, Coldfusion, Tomcat and PayflowPro Play Nicely

One of the more odd parts of our architecture at work involves a cluster of Tomcat instances running ColdFusion and Java services side by side. We are porting our existing ColdFusion services over to Java/SpringMVC applications, and during the transition they are being served up by the same app servers. One of these services interacts …

Making Java, Coldfusion, Tomcat and PayflowPro Play Nicely Read More »

OpenSearch

At work we use several Atlassian products, including JIRA and Confluence. We recently upgraded to the latest version of both, and when that happened I noticed Chome starting to behave a little differently. One day I was typing in https://jira (the path to our internal instance), and all of a sudden Chrome's URL bar changed, …

OpenSearch Read More »

Server Migration, Once Again

It wasn't too long ago that I moved most of my sites over to Slicehost. It was a great service, and the price was far better than what I was paying before, and I got better service. But, new services come along, or at least we become aware of other services, and another move was …

Server Migration, Once Again Read More »

First Experience with EC2

A few days ago I had my first experience with Amazon EC2. I have been wanting to try it for some time, and had some really nice use cases for it at my previous job (had a program that would have been  awesome to rewrite as a map/reduce), but never got to use it. Well, …

First Experience with EC2 Read More »

New Job

So I promised to some that there would be some big news on Thursday, so here it is. Some people had to find this out first (mainly my boss) before I could post it publically. A few have known about this for a while, so thank you for holding your tongues. This post should only …

New Job Read More »

GMail, webmail, and HTML

While working on a project at work, I started to see some weird things coming across in an e-mail that the system is supposed to send out. There have been several other developers working in the code, and it had not quite reached the testing phase just yet. Since I had some time on my …

GMail, webmail, and HTML Read More »

GMail, webmail, and HTML

While working on a project at work, I started to see some weird things coming across in an e-mail that the system is supposed to send out. There have been several other developers working in the code, and it had not quite reached the testing phase just yet. Since I had some time on my …

GMail, webmail, and HTML Read More »

The move is finally over

It has been a very busy week / 10 days, and I finally have a free moment before going to be bed to reflect on what has happened. A week ago this last Thursday was my last day at CARFAX. It was hard to say goodbye to a company that has treated me and the …

The move is finally over Read More »

The Big Announcement

So I promised to some that there would be some big news on Thursday, so here it is. Some people had to find this out first (mainly my boss) before I could post it publicly. A few have known about this for a while, so thank you for holding your tongues. This post should only …

The Big Announcement Read More »

Weddings

Well, our last wedding before our child’s birth is over with (we do have one in 1 month, but that would put the baby at 43 weeks). It was actually tamer and more, oh, meaningful, dignified, reverent? There was very little drinking compared to previous weddings, the guests all had fun, stress levels were low, …

Weddings Read More »

Back Home

Well, we are back from our trip to Jackson, MS. We were down there for the wedding of our friends Shaun and Mary Frances. It was a beautiful ceremony and reception, and we got some great pictures, despite a few roadblocks. The trip down was fairly uneventful. We stayed with Summer’s parents Thursday night to …

Back Home Read More »

The Cheese, It Is A-Movin

We are safely down in Salem, MO, which will be our brief resting place before moving on down to Jackson, TN for a wedding that we are shooting for some good friends. It is nice to have some down time, which is why I am actually able to post twice in a 24 hour period. …

The Cheese, It Is A-Movin Read More »

Teaching

I had an interesting reminder today that I still have a pleonast account, and that sometimes completely strangers will occasionally read what I say here (hello to new readers Tom, Doug, and Eli). So, here I am, back for a quick installment. Tonight was an interesting night at our mid-week study. The teachers for the …

Teaching Read More »

Cloth Diaper Cost Study

Over the past few weeks, I have been working on a study of how much we spent on cloth diapers since Silas was born. I threw in some research on the costs of disposable diapers, to make sure that so far we have saved money. By my accounting, we will actually break even in February …

Cloth Diaper Cost Study Read More »

Google GSON and Thread Safety

At work we are using gson to do some soft serialization between some applications. Our production application started to throw some errors this afternoon, and after looking into the problem it would appear that gson has a static reference to SimpleDateFormat (or, more correctly, a static member that was constructed with DateFormat.getDateTimeInstance(), which returns a …

Google GSON and Thread Safety Read More »

No New Theft

Ecc 1:9-14: What has been is what will be, and what has been done is what will be done, and there is nothing new under the sun. Is there a thing of which it is said, “See, this is new”? It has been already in the ages before us. There is no remembrance of former …

No New Theft Read More »