I’ve got a few Cuba 7.2 applications running. One is an old-style application module that is used in all the other applications. As I understand it, once I migrate that application module to Jmix 1.5, I then have to change it into an add-on to be included in my other projects. Everything is still using Classic UI.
I am not clear on exactly how to change a project into an add-on. I’ve seen the information about @JmixModule, but I can’t quite grasp what changes need to be made.
Do I change the @SpringBootApplication to be @JmixModule and create a corresponding Configuration module? How does the starter module fit in?
In a perfect world, there would be a Studio function “Convert Project to Add-On” or something similar, but a recipe in the docs would suffice.
The default add-on project structure is different from the application project.
I would suggest creating a new project using “Add-on (Java)” template and enter the same base package as in original application, as well as appropriate Project ID.
Then copy relevant sources from the application project to the add-on. Perhaps you won’t copy User entity and its screens, main and login screens.
You don’t need to move class with this annotation.
The addon project has a similar class instead, but it has a @JmixModule annotation and some additional annotations.