More removed functionality: UniqueNumbersService

It seems UniqueNumbersService was removed in Jmix, with no mention in the migration docs.

Any advice on how to replace its functionality? We have a lot of uses of it.

Use UniqueNumbersAPI in migrated projects or in new Jmix projects.


I’ll check that out. Consider adding this to the migration docs? :slight_smile:

1 Like

Not sure. UniqueNumbersAPI is a well known CUBA interface, and now in Jmix it has a Javadoc saying what to use instead. We cannot explain all possible use cases and replacements anyway.

But UniqueNumbersService simply doesn’t exist in Jmix and prevents compile obviously… And there’s no pointer as to what to replace it with.

That’s true. Still, this migration is not very smooth. I shudder to think what people with larger, finished apps, will go through.

Also, most of my uses are in entity classes where in CUBA, injection wasn’t possible and AppBeans.get() was used. This seems to be gone in Jmix, so… advice on how to get access to UniqueNumbersAPI in an entity class?

You can create your own AppBeans class in your project, see this topic: Is there any alternatives to AppBeans

5 posts were split to a new topic: Using sequences