Task #2217 Add incarnation id to the daemons

- Created an IDGenerator. It's used by the daemons to generate the IDs.
- The daemons are calling the IDGenerator.