I have an application which is generated with jhipster version 5 (JHipster 5.0.0-beta.1). Now I have to upgrade the application to the latest jhipster version 6 and Java 11. In the documentation I was not able to find hints to do this... (and auto upgrade does not work)
e.g. there was significant changes like setting the default timezone to "UTC". When I have an existing app with an database: what must be done to restore this change to its original state so that our application does not have an impact? (Server runs with timezone Europe/Vienna)
And so on...
@maku : Here's the page that highlights the update process.
https://www.jhipster.tech/upgrading-an-application/#-upgrading-an-application
Did you follow this? You might have merge conflicts in which case you have to manually merge them. As for some helpful strategies on mitigating these merge conflicts and stuff; you will find some suggessions from the community; such as the following talk.
https://www.youtube.com/watch?v=Gg5CYoBdpVo&list=PL6IFaLdAcgE3aSgmRyhi6eULdlrwjA5sm&index=13&t=0s
As for Java 11 you will have to manually do the upgrade. I think we've discussed this before in your previous thread; https://github.com/jhipster/generator-jhipster/issues/10479
@SudharakaP Yes I tried but on running
jhipster upgrade
I got:
ERROR! Error: Current directory does not contain a JHipster project.
So I started to upgrade manually. Now the app runs with java 11 and the newest dependencies. But I'd like to be halfway sure I've taken everything into account.
And of course the timezone topic seems rather important to me (jhipster default to "UTC") -> What do I have to do to maintain current behavior? -> Server runs with timezone Europe/Vienna
@maku : Could you please post your full error? I kindly suggest filing up a bug report completing all relevant sections (especially the .yo-rc.json configurations) of the template, because if the upgrade is failing we need to take a look at it first and that way we could try to recreate you scenario.
I am not quite familiar with the timezone change you are talking about, however I think you are referring to https://github.com/jhipster/generator-jhipster/issues/8284; and @avdev4j probably could chip in. :smile:
However if we could track down the problem with your upgrade process, I believe you might be in a better situation to handle the timezone and other issues on your own, during the merge step. :smile:
cc: @avdev4j
@SudharakaP it seems the project has no file ".yo-rc.json" Which explains why the update is not working.... This file disappeared a long time ago. and the project was managed manually...
@maku : That's interesting and explains the problem :smile: I am not sure what to suggest except the fact that the application now probably no longer can be called a Jhipster application since there's no association with any jhipster command without a .yo-rc.json file.
Maybe try to construct the .yo-rc.json file back given that you know you have a 5.0.0-beta.1 version and modify it as closely as possible to tally with whatever configuration you've added (if you've run other generators over this original .yo-rc.json) is what I could think of. Maybe others can chip in with better suggestions. :thinking: :thinking:
@SudharakaP At least it still uses the dependecy "jhipster-framework" (and also uses versions managed by jhipster -> dependencyManagement)
The current status is: I updated the app to the latest versions and Java 11. And it seems to work. But I would like to make sure that the timezone change makes us no problems....
But I really must thank you for your help...
Maybe @avdev4j can give a short comment what the necessary steps would be to stay on the level of jhipster 5 regarding the timezone conversion
@maku :
There are a lot of changes between JHipster 5 and JHipster 6. The jhipster upgrade can't work as there are some breaking changes.
JHipster helps you to generate a new project. Once it is generated, the code belongs to you as you added your own code.
It would be easier if you upgrade your application each patch / minor version.
The best thing I can suggest is to look the related PR, then try to apply the diff.
Have a look at:
Not sure we can help more here...
@pascalgrimaud : I've added two points to our update page about Jhispter Side-by-Side method as well as the recommendation to update between minor/patch versions rather than trying to update from a very old version. Let me know if there's any changes necessary. :smile:
I think it's good, so we can close this.
Thanks @SudharakaP
@pascalgrimaud : You are welcome. :smile: