Problems to upgrade simple App from Cuba 6.2.8 to 6.3/6.5

I wrote a simple CUBA 6.2.8 app with only one entity and two screens (table and edit dialog). Nevertheless, migration to CUBA 6.3 or CUBA 6.5 fails.

The reason for the migration problems seem to be rooted in a special feature of the application: it encrypts the user’s data in the database with a hash of the user’s login password. In order to implement this feature, I implemented a custom subclass of the default Cuba LoginWindow which transmits the user’s login password hash to an encryption/decryption service in the persistence layer. The implementation overrides the method com.haulmont.cuba.web.DefaultApp#createAppWindow(AppUI). However, this method no longer exists in Cuba 6.3+.

Cuba 6.3+ differs from Cuba 6.2 a lot, so I am not sure how to migrate this functionality. In addition, even the JUnit test for my encryption service does no longer work because the required com.haulmont.cuba.core.Persistence bean can no longer be injected into it. Manually fixing the spring application context has proven to be difficult (several missing beans, strange spring error messages). Even worse, manually fixing the spring application context might prevent further work with Cuba Studio.

Are you aware of such migration problems? Given such big problems with such a small project, I can hardly recommend using Cuba to my customers for anything more than small, non-critical applications.

1 Like

Hi,

Unfortunately, extension of LoginWindow from 6.2 cannot be migrated automatically. As you can see it is mentioned in the release notes: CUBA Platform 6.3 Release Notes

We reworked LoginWindow completely and introduced it as usual CUBA window that can be easily extended from CUBA Studio. I’d recommend that you remove extended LoginWindow class from the project and then create LoginWindow screen extension from CUBA Studio, after that you can migrate your additional features from customized LoginWindow class to the new loginWindow screen controller.

Could you clarify your problem with com.haulmont.cuba.core.Persistence interface? We didn’t changed it and its usage, so we assume that you will be able to migrate your tests easily.