public class SimpleIdGenerator extends PlainIdGenerator
The ID is generated from a combination of the current hostname, hashcode of the object, and current timestamp.
In the adapter configuration file this class is aliased as simple-id-generator which is the preferred alternative to the fully qualified classname when building your configuration.
Constructor and Description |
---|
SimpleIdGenerator() |
SimpleIdGenerator(java.lang.String separator) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
create(java.lang.Object msg)
Create a unique id based on the object.
|
getSeparator, setSeparator
public SimpleIdGenerator()
public SimpleIdGenerator(java.lang.String separator)
public java.lang.String create(java.lang.Object msg)
IdGenerator
create
in interface IdGenerator
create
in class PlainIdGenerator
msg
- the object to create an id around