add optional hostname and PID components

We use these in our app so that we can quickly track down what rails process is misbehaving if we see a long running or locked up query.