If Iris does propose to create keys following a sequence, how can we obtain a sequential number in another context?
In my case, I automatically create care centers, and I want to set them a number like:
APP-DD-999
APP = Name of the application used by the center
DD = center department number
999: sequential number in the department
It is of course possible that centers will be created in competition, so this possible competition must be managed.
My first approach was to use a persistent class and create a new object to retrieve its id, but this involves creating as many classes as departments.

.png)
.png)