title: Constant UUIDs for functional logging (design)
body: <p>I'm working on a issue regarding functional logging (log seen by non-developers). One requirement is adding a unique ID per log entry. This is such that the product managers can query on said ID and get all the associated log entries.
  A (pseudo) code example is shown below:</p>
  
  <pre><code>if (something starts or happens here){
      //arguments: container id, service name, message, message uuid
      functionalLogService.addLog(container.getId(), this.SERVICE_NAME, "this happened", "124e3314-ffad-4b5d-be76-fc6b0f82aeea");
  }
  </code></pre>
  
  <p>I have to do this quite often and I don't really like having random UUIDs hardcoded in loglines. The UUID is different for each log statement. One option is to leave it as is, which works, another is to create constants for each UUID, which seems overkill. </p>
  
  <p>My question: is there any kind of design or "nice" way to do this?</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>I've already had the idea of using:</p>
  
  <pre><code>UUID.nameUUIDFromBytes(message.getBytes()).toString();
  </code></pre>
  
  <p>But if at some point I want to change the message, the database will no longer be backwards compatible. So this option is out.</p>