I attempted to update onedev V11.5.1 to the latest (V12.0.4) following the online guide for updating a service type install but it failed. (Inluded log files) (OD-2516)
Brent Hitzeroth opened 5 months ago
C:\onedev-latest\onedev-latest_12_0_4\bin>upgrade.bat C:\onedev-latest\onedev-latest
--> Wrapper Started as Console
Java Service Wrapper Standard Edition 64-bit 3.5.51
  Copyright (C) 1999-2022 Tanuki Software, Ltd. All Rights Reserved.
    http://wrapper.tanukisoftware.com
  Licensed to OneDev for Service Wrapping

Launching a JVM...
WrapperManager: Initializing...
Detected that the Java process launched by the Wrapper (PID 3776) was redirected to C:\Program Files\Java\jdk-21\bin\java.exe (PID 8152).
 Switch to monitoring the Java process.
INFO  - Launching application from 'C:\onedev-latest\onedev-latest_12_0_4'...
INFO  - Cleaning temp directory...
INFO  - Starting application...
INFO  - Upgrading C:\onedev-latest\onedev-latest...
INFO  - >>> INFO  - Launching application from 'C:\onedev-latest\onedev-latest'...
INFO  - >>> INFO  - Cleaning temp directory...
INFO  - >>> INFO  - Starting application...
INFO  - >>> INFO  - Waiting for server to stop...
INFO  - >>> INFO  - Stopping application...
INFO  - Backing up old program files as C:\onedev-latest\onedev-latest\site\program-backup\2025-08-06_23-53-34...
INFO  - Backing up database as C:\onedev-latest\onedev-latest\site\db-backup\2025-08-06_23-53-34.zip...
INFO  - >>> INFO  - Launching application from 'C:\onedev-latest\onedev-latest'...
INFO  - >>> INFO  - Cleaning temp directory...
INFO  - >>> INFO  - Starting application...
INFO  - >>> INFO  - Waiting for server to stop...
INFO  - >>> INFO  - Backing up database to C:\onedev-latest\onedev-latest\site\db-backup\2025-08-06_23-53-34.zip...
INFO  - >>> INFO  - Exporting table 'BuildParam'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PackQueryPersonalization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'DashboardGroupShare'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'GpgKey'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'CommitQueryPersonalization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'ReviewedDiff'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'UserAuthorization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->100) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'UserAuthorizations.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'UnitTestMetric'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueLink'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Setting'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->25) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'Settings.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueQueryPersonalization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueVote'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->1) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'IssueVotes.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'JobCache'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'EmailAddress'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->3) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'EmailAddresss.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'BuildLabel'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->5) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'BuildLabels.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'CodeCommentStatusChange'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Alert'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'DashboardUserShare'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'GitLfsLock'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Membership'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->3) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'Memberships.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'CodeCommentMention'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'AccessTokenAuthorization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'AccessToken'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->1) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'AccessTokens.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequestChange'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'GroupAuthorization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->1) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'GroupAuthorizations.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Group'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->2) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'Groups.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'UserInvitation'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PackBlobAuthorization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueWatch'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->13) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'IssueWatchs.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequestMention'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'BuildDependence'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->38) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'BuildDependences.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'CoverageMetric'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueAuthorization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->11) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'IssueAuthorizations.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'ModelVersion'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->1) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'ModelVersions.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'BuildQueryPersonalization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->1) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'BuildQueryPersonalizations.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PackLabel'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'LinkAuthorization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'LinkSpec'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->2) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'LinkSpecs.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequestComment'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueTouch'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->12) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'IssueTouchs.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequestQueryPersonalization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueField'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->37) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'IssueFields.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequestReview'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'ProblemMetric'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequestLabel'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequestAssignment'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueMention'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueStateHistory'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->24) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'IssueStateHistorys.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueWork'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequestWatch'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueComment'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->9) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'IssueComments.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'DashboardVisit'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Dashboard'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'CodeCommentQueryPersonalization'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueSchedule'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->5) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'IssueSchedules.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Iteration'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->2) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'Iterations.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'CodeCommentReply'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'SshKey'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->1) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'SshKeys.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'AgentAttribute'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Stopwatch'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequestUpdate'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PackBlobReference'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PackBlob'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Pack'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Build'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->596) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'Builds.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Agent'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'AgentToken'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->1) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'AgentTokens.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'AgentLastUsedDate'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'IssueChange'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->17) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'IssueChanges.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Issue'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->12) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'Issues.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PendingSuggestionApply'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'PullRequest'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'CodeComment'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'User'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->5) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'Users.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'ProjectLabel'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Project'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->98) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'Projects.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'ProjectLastEventDate'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->98) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'ProjectLastEventDates.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'LabelSpec'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->5) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'LabelSpecs.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Exporting table 'Role'...
INFO  - >>> INFO  - Querying table ids...
INFO  - >>> INFO  - Loading table rows (1->6) from database...
INFO  - >>> INFO  - Converting table rows to XML...
INFO  - >>> INFO  - Writing resulting XML to file 'Roles.xml...
INFO  - >>> INFO  -
INFO  - >>> INFO  - Building zip: C:\onedev-latest\onedev-latest\site\db-backup\2025-08-06_23-53-34.zip
INFO  - >>> INFO  - Database is successfully backed up to C:\onedev-latest\onedev-latest\site\db-backup\2025-08-06_23-53-34.zip
INFO  - >>> INFO  - Stopping application...
INFO  - Cleaning database with old program...
INFO  - >>> INFO  - Launching application from 'C:\onedev-latest\onedev-latest'...
INFO  - >>> INFO  - Cleaning temp directory...
INFO  - >>> INFO  - Starting application...
INFO  - >>> INFO  - Waiting for server to stop...
INFO  - >>> INFO  - Database is cleaned successfully
INFO  - >>> INFO  - Stopping application...
INFO  - Updating program files...
INFO  - Restoring database with new program...
INFO  - >>> INFO  - Launching application from 'C:\onedev-latest\onedev-latest'...
INFO  - >>> INFO  - Cleaning temp directory...
INFO  - >>> INFO  - Starting application...
INFO  - >>> INFO  - Restoring database from C:\onedev-latest\onedev-latest\site\db-backup\2025-08-06_23-53-34.zip...
INFO  - >>> INFO  - Waiting for server to stop...
INFO  - >>> INFO  - Creating tables...
INFO  - >>> INFO  - Importing data into database...
INFO  - >>> INFO  - Importing from data file 'ModelVersions.xml'...
INFO  - >>> INFO  - Importing from data file 'LabelSpecs.xml'...
INFO  - >>> INFO  - Importing from data file 'ProjectLastActivityDates.xml'...
INFO  - >>> INFO  - Importing from data file 'Projects.xml'...
INFO  - >>> ERROR - Violation of UNIQUE KEY constraint 'UK_j7gpcee0lh0w4ock713lhv2rn'. Cannot insert duplicate key in object 'dbo.o_Project'. The duplicate key value is (<NULL>).
INFO  - >>> ERROR - Error booting application
INFO  - >>> javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not execute statement
INFO  - >>>     at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:154)
INFO  - >>>     at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:181)
INFO  - >>>     at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:188)
INFO  - >>>     at org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1366)
INFO  - >>>     at org.hibernate.internal.SessionImpl.flush(SessionImpl.java:1349)
INFO  - >>>     at io.onedev.server.data.DefaultDataManager.importData(DefaultDataManager.java:501)
INFO  - >>>     at io.onedev.server.persistence.SessionInterceptor$1.call(SessionInterceptor.java:23)
INFO  - >>>     at io.onedev.server.persistence.DefaultSessionManager.call(DefaultSessionManager.java:90)
INFO  - >>>     at io.onedev.server.persistence.SessionInterceptor.invoke(SessionInterceptor.java:18)
INFO  - >>>     at io.onedev.server.commandhandler.RestoreDatabase.doRestore(RestoreDatabase.java:121)
INFO  - >>>     at io.onedev.server.commandhandler.RestoreDatabase.lambda$start$0(RestoreDatabase.java:74)
INFO  - >>>     at io.onedev.server.commandhandler.CommandHandler.doMaintenance(CommandHandler.java:32)
INFO  - >>>     at io.onedev.server.commandhandler.RestoreDatabase.start(RestoreDatabase.java:67)
INFO  - >>>     at io.onedev.commons.loader.DefaultPluginManager.start(DefaultPluginManager.java:44)
INFO  - >>>     at io.onedev.commons.loader.AppLoader.start(AppLoader.java:74)
INFO  - >>>     at io.onedev.commons.bootstrap.Bootstrap.main(Bootstrap.java:200)
INFO  - >>> Caused by: org.hibernate.exception.ConstraintViolationException: could not execute statement
INFO  - >>>     at org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:109)
INFO  - >>>     at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:42)
INFO  - >>>     at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113)
INFO  - >>>     at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:99)
INFO  - >>>     at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:200)
INFO  - >>>     at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3301)
INFO  - >>>     at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3828)
INFO  - >>>     at org.hibernate.action.internal.EntityInsertAction.execute(EntityInsertAction.java:107)
INFO  - >>>     at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:604)
INFO  - >>>     at org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
INFO  - >>>     at java.base/java.util.LinkedHashMap.forEach(LinkedHashMap.java:986)
INFO  - >>>     at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
INFO  - >>>     at org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:348)
INFO  - >>>     at org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
INFO  - >>>     at org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:102)
INFO  - >>>     at org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1362)
INFO  - >>>     ... 12 common frames omitted
INFO  - >>> Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Violation of UNIQUE KEY constraint 'UK_j7gpcee0lh0w4ock713lhv2rn'. Cannot insert duplicate key in object 'dbo.o_Project'. The duplicate key value is (<NULL>).
INFO  - >>>     at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:262)
INFO  - >>>     at com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(SQLServerStatement.java:1624)
INFO  - >>>     at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.doExecutePreparedStatement(SQLServerPreparedStatement.java:594)
INFO  - >>>     at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement$PrepStmtExecCmd.doExecute(SQLServerPreparedStatement.java:524)
INFO  - >>>     at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:7194)
INFO  - >>>     at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:2979)
INFO  - >>>     at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(SQLServerStatement.java:248)
INFO  - >>>     at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(SQLServerStatement.java:223)
INFO  - >>>     at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.executeUpdate(SQLServerPreparedStatement.java:473)
INFO  - >>>     at com.zaxxer.hikari.pool.ProxyPreparedStatement.executeUpdate(ProxyPreparedStatement.java:61)
INFO  - >>>     at com.zaxxer.hikari.pool.HikariProxyPreparedStatement.executeUpdate(HikariProxyPreparedStatement.java)
INFO  - >>>     at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:197)
INFO  - >>>     ... 23 common frames omitted
INFO  - >>> INFO  - Stopping application...
ERROR - Failed to upgrade C:\onedev-latest\onedev-latest
INFO  - >>> INFO  - Launching application from 'C:\onedev-latest\onedev-latest'...
INFO  - >>> INFO  - Cleaning temp directory...
INFO  - >>> INFO  - Starting application...
INFO  - >>> INFO  - Waiting for server to stop...
INFO  - >>> INFO  - Stopping application...
INFO  - Cleaning database with new program...
INFO  - >>> INFO  - Launching application from 'C:\onedev-latest\onedev-latest'...
INFO  - >>> INFO  - Cleaning temp directory...
INFO  - >>> INFO  - Starting application...
INFO  - >>> INFO  - Waiting for server to stop...
INFO  - >>> WARN  - 'FKirj2pi2nr85rq82n5pl6ppcxe' is not a constraint.
INFO  - >>> WARN  - 'FK9stiqa0rbe2urq8vvsfwh1reb' is not a constraint.
INFO  - >>> WARN  - 'FKhpbluvkeyfgmlhkefpu46me8r' is not a constraint.
INFO  - >>> WARN  - 'FKitcp3nk07lt4iwt15o3t3f47t' is not a constraint.
INFO  - >>> WARN  - 'FKp1av15m2h3jddq9v38ccv3bmn' is not a constraint.
INFO  - >>> WARN  - 'FK43jr14fn5ujscxkr63ceg84cc' is not a constraint.
INFO  - >>> WARN  - 'FKh4f3muubcrbc18eeueij82qip' is not a constraint.
INFO  - >>> WARN  - 'FK6awlllv7yt75276ursd5bfto6' is not a constraint.
INFO  - >>> WARN  - 'FKt884njkc0q1civ9q1ky8aajqg' is not a constraint.
INFO  - >>> WARN  - 'FKhb5vtw5uwpa947qnbkqqfli4i' is not a constraint.
INFO  - >>> WARN  - 'FK7hjthut90ul18w1f5f0vc6n85' is not a constraint.
INFO  - >>> WARN  - 'FK4425ah37kkqql9afrxj3j9s01' is not a constraint.
INFO  - >>> WARN  - 'FKqj6v41bi61xemfb43bj265qxo' is not a constraint.
INFO  - >>> WARN  - 'FKcqt648wimygi8l5mlna7n9xfr' is not a constraint.
INFO  - >>> WARN  - 'FKbqwv7vanjiokgxqa3nn8h2aqu' is not a constraint.
INFO  - >>> WARN  - 'FK7du5v10cprnvk1n2h5e68tdy9' is not a constraint.
INFO  - >>> WARN  - 'FKku04d28cuxemv5a3ymqe79t98' is not a constraint.
INFO  - >>> WARN  - 'FK80p4s2syp4jyt201e0skxdwvn' is not a constraint.
INFO  - >>> WARN  - 'FKiv1176tcqp3r8l1lwbyhta01y' is not a constraint.
INFO  - >>> WARN  - 'FKnnif4ydigu70pwjkn7kw643m7' is not a constraint.
INFO  - >>> WARN  - 'FKqv458fx3dxqmqx86ucy6ii4ip' is not a constraint.
INFO  - >>> WARN  - 'FKj9qu741coo9m5afoqdtplwcv4' is not a constraint.
INFO  - >>> WARN  - 'FKc41frtef950hgqbw54vmmaxdp' is not a constraint.
INFO  - >>> WARN  - 'FKfl32vhsuif9357tnrhcsbt8sf' is not a constraint.
INFO  - >>> WARN  - 'FKnjkqmw5gfc3b2otd5ojw37bw1' is not a constraint.
INFO  - >>> WARN  - 'FK4dox4328vv5rftc06vtplv3pk' is not a constraint.
INFO  - >>> WARN  - 'FKapo41gkw1c0hbfe448218ty2h' is not a constraint.
INFO  - >>> WARN  - 'FK5myvwvgqa7b1qb94ri6rtjjh4' is not a constraint.
INFO  - >>> WARN  - 'FKn8gqligbsqfgjyo9sa1lurwl' is not a constraint.
INFO  - >>> WARN  - 'FKd1hwcfomofre977xh9lvasy2d' is not a constraint.
INFO  - >>> WARN  - 'FKstnpvfr1pijw5pitfkvhvqxjp' is not a constraint.
INFO  - >>> WARN  - 'FKpw081vlqghpxlxjmsdsrncsim' is not a constraint.
INFO  - >>> WARN  - 'FKdb4opg8ek20hye9hwoch1a6eu' is not a constraint.
INFO  - >>> WARN  - 'FKi6yo1l8df3t1rxg8073et0o21' is not a constraint.
INFO  - >>> WARN  - 'FKsiaso3u9qlrdf91rvg6522jd' is not a constraint.
INFO  - >>> WARN  - 'FK3xyobkvrynf1xh3jij83t8dhk' is not a constraint.
INFO  - >>> WARN  - 'FKb26hl668ik7d8oo2kk952gnp2' is not a constraint.
INFO  - >>> WARN  - 'FKlgh09m07y3kvvs7suyitg0f2q' is not a constraint.
INFO  - >>> WARN  - 'FKlhexfhqgr0vkhil19igdvllne' is not a constraint.
INFO  - >>> WARN  - 'FKo1jm0pkdvuse5grxi6x8ve07p' is not a constraint.
INFO  - >>> WARN  - 'FKt89t18nrrsln889d0p19umsav' is not a constraint.
INFO  - >>> WARN  - 'FK2spp35e7o8aoseucffsvwy0h7' is not a constraint.
INFO  - >>> WARN  - 'FKljcnlkk46exbn24rxwly1hg04' is not a constraint.
INFO  - >>> WARN  - 'FK91yul0vyu02bc9tsruc0bg1k' is not a constraint.
INFO  - >>> WARN  - 'FKk4dylqeeiqcuqmr7p91p974oi' is not a constraint.
INFO  - >>> WARN  - 'FKfob1t0js06frtkku3kugiqwy9' is not a constraint.
INFO  - >>> WARN  - 'FK9sfmrg307je3q7xq0m4095wks' is not a constraint.
INFO  - >>> WARN  - 'FK9g200ih6lckn497l5s0ttiv6t' is not a constraint.
INFO  - >>> WARN  - 'FK1t10e1h7b7h6c9whn0ngjbiys' is not a constraint.
INFO  - >>> WARN  - 'FK94u2jlewjpnipo80q0lyiog4t' is not a constraint.
INFO  - >>> WARN  - 'FKdarwh81ijupoxmpschgi2yiim' is not a constraint.
INFO  - >>> WARN  - 'FKbq0karoimb91ler1x9ttmtmfy' is not a constraint.
INFO  - >>> WARN  - 'FK8hqpoyi1t7w9so5r5g24tc5fl' is not a constraint.
INFO  - >>> WARN  - 'FK4dqkrgv236a01miilsi3vpc8v' is not a constraint.
INFO  - >>> WARN  - 'FKte7oyhw5yhpeclkjmkyh6e7d6' is not a constraint.
INFO  - >>> WARN  - 'FK8ckuber0qyn92lofpiuhucyf8' is not a constraint.
INFO  - >>> WARN  - 'FKq84aht0n933vkfe5rakncs84y' is not a constraint.
INFO  - >>> WARN  - 'FKth8nqer31rpt0vjy8csfgamba' is not a constraint.
INFO  - >>> WARN  - 'FKpwkgci0xwfog055s2p7k91f58' is not a constraint.
INFO  - >>> WARN  - 'FKc2gfh8klmuyq0nfndodqadn11' is not a constraint.
INFO  - >>> WARN  - 'FKqmsxsjty3xnbh3lpchasnyvap' is not a constraint.
INFO  - >>> WARN  - 'FKfv13wku3s18s6gn6k1x988in7' is not a constraint.
INFO  - >>> WARN  - 'FKmqqqb1s6b2s8q8g6hq1xa74rf' is not a constraint.
INFO  - >>> WARN  - 'FK8pu94leg2gyjm4qwek3unyg8c' is not a constraint.
INFO  - >>> WARN  - 'FK8eu1soplbd9ibiwsoi1sryksh' is not a constraint.
INFO  - >>> WARN  - 'FKma5ldnqqpueiu49d30kjgasc9' is not a constraint.
INFO  - >>> WARN  - 'FKqbayd938ivjsp6a0b2qxme25n' is not a constraint.
INFO  - >>> WARN  - 'FK1nx4vb8ep93xbkptamrtecl37' is not a constraint.
INFO  - >>> WARN  - 'FKs5bt3lav7cf1ysct28gcxlvt0' is not a constraint.
INFO  - >>> WARN  - 'FKkj72cef5cfnjhv245vkededai' is not a constraint.
INFO  - >>> WARN  - 'FKnwivg38xx359o9bts1e6bni7w' is not a constraint.
INFO  - >>> WARN  - 'FKoni6ik8i4tqsfqr4f93ycse46' is not a constraint.
INFO  - >>> WARN  - 'FKdeb3iqkibtjw3wf8eyypdjesc' is not a constraint.
INFO  - >>> WARN  - 'FKc4tyl3xejajwf5asykdgdpoxs' is not a constraint.
INFO  - >>> WARN  - 'FKob2g31qi7l6rxuymq6fj9exqq' is not a constraint.
INFO  - >>> WARN  - 'FKaxg3jrvygiqahiy67imfk8i80' is not a constraint.
INFO  - >>> WARN  - 'FK1uhhyo5p15pw61qi9cbsrfycn' is not a constraint.
INFO  - >>> WARN  - 'FK5wubeg1mbdkxrowgdqb87e6we' is not a constraint.
INFO  - >>> WARN  - 'FKndcvugfj5r1furl80tdoyrvle' is not a constraint.
INFO  - >>> WARN  - 'FKe3blnlhbaiks5xe16h4qt84l6' is not a constraint.
INFO  - >>> WARN  - 'FKsasi07qdswg3evsgqdmcaovbw' is not a constraint.
INFO  - >>> WARN  - 'FK8ok4dbno5hx2d3mun30wkrvlg' is not a constraint.
INFO  - >>> WARN  - 'FK4auyaify4lcydisfwxtwidkaw' is not a constraint.
INFO  - >>> WARN  - 'FKhx0n3i0491m3rn4gw2501nq0m' is not a constraint.
INFO  - >>> WARN  - 'FKccptwuyrfs8v9mxmmynt17aqr' is not a constraint.
INFO  - >>> WARN  - 'FK20wy9hju85ltpk6k9yl4xa51f' is not a constraint.
INFO  - >>> WARN  - 'FKt21n9jxi6pwylrtdst2dxonos' is not a constraint.
INFO  - >>> WARN  - 'FKg47qnlhcpgcabwd4qqha93ebi' is not a constraint.
INFO  - >>> WARN  - 'FKr19eofhbhn3j2usientdfxipi' is not a constraint.
INFO  - >>> WARN  - 'FKfrqwqw5m5lp4y1mdf8t1tc5dv' is not a constraint.
INFO  - >>> WARN  - 'FKm1mf1t3131f70b16v7ib3nkr2' is not a constraint.
INFO  - >>> WARN  - 'FKcvcaxl0dlnppq71miemo9fglu' is not a constraint.
INFO  - >>> WARN  - 'FKsowt2i1h8h85pbe5fkh1yh6jh' is not a constraint.
INFO  - >>> WARN  - 'FKa5mxo1uo7x3s32qkppmy2nne4' is not a constraint.
INFO  - >>> WARN  - 'FK9864fneyptficactc5kcepq7i' is not a constraint.
INFO  - >>> WARN  - 'FKjc6ln2jary4829pqbt2w32rpk' is not a constraint.
INFO  - >>> WARN  - 'FKmrj3ks5m177sx0ak9a7ypnmjd' is not a constraint.
INFO  - >>> WARN  - 'FKl17e7jpvtdc14enn4uhtlyhpm' is not a constraint.
INFO  - >>> WARN  - 'FKfgesnveoulp1yxpxfvelvgqp6' is not a constraint.
INFO  - >>> WARN  - 'FK4phpqap0206ordsviy1w4k40e' is not a constraint.
INFO  - >>> WARN  - 'FK1qy3e3jfs9d9syh9uc2h7c4ic' is not a constraint.
INFO  - >>> WARN  - 'FK36ruq099qjwquv3idhw4gs7t1' is not a constraint.
INFO  - >>> WARN  - 'FKeeamil8s8n9sx7yiv610ndmp2' is not a constraint.
INFO  - >>> WARN  - 'FKsjxk5f4hp3rgd6iexffsli3m9' is not a constraint.
INFO  - >>> WARN  - 'FKhfkf1ge384fevbxbhpj3lpkxl' is not a constraint.
INFO  - >>> WARN  - 'FKhdx61civqb5y1s4m6bnmupdiy' is not a constraint.
INFO  - >>> WARN  - 'FKteqx7e3699xgl7jjtkew3ekop' is not a constraint.
INFO  - >>> WARN  - 'FK82tpfdvke0jljy43ieuavnmhw' is not a constraint.
INFO  - >>> WARN  - 'FKj8xkwgd2xcfj7ocr9o3md411u' is not a constraint.
INFO  - >>> WARN  - 'FK3kk3kxbife0hrivvpttrabfuu' is not a constraint.
INFO  - >>> WARN  - 'FK34tfng1rjqinmshpoag2kj9iw' is not a constraint.
INFO  - >>> WARN  - 'FKi636xxruusjqqwloyucqt8fc4' is not a constraint.
INFO  - >>> WARN  - 'FKnwak65pwlrih9la3yxm6pfd8c' is not a constraint.
INFO  - >>> WARN  - 'FKmm06x2trd1br3lnw7h1cxt3ny' is not a constraint.
INFO  - >>> WARN  - 'FK7j5r9dednfxvmkc1473tdt7ic' is not a constraint.
INFO  - >>> WARN  - 'FKmhkx9kkd1aym7w5u04wvg2g4c' is not a constraint.
INFO  - >>> WARN  - 'FK779j2t2ebyg6rw766ryy1slp' is not a constraint.
INFO  - >>> WARN  - 'FKeljs4kqydwqt9oo09rig2b5bv' is not a constraint.
INFO  - >>> WARN  - 'FKb1vwok7r1p1h4xxfy12c3cgmy' is not a constraint.
INFO  - >>> WARN  - 'FKptwk3m4dekyqbog03r11cd6ex' is not a constraint.
INFO  - >>> WARN  - 'FKhd7yy8usy4ckubsh4qvtk9q1x' is not a constraint.
INFO  - >>> WARN  - 'FK60160xl29vugv04emh50a3cv' is not a constraint.
INFO  - >>> WARN  - 'FKeubvxhf7sx0q9evt5rmvnabxj' is not a constraint.
INFO  - >>> WARN  - 'FKk4c7vdtc35im5mdkdev7jjptx' is not a constraint.
INFO  - >>> WARN  - 'FKtlue2obqriktgesykdyv83jus' is not a constraint.
INFO  - >>> WARN  - 'FK4ehnxvuouhl18k9ceos99sk4n' is not a constraint.
INFO  - >>> WARN  - 'FK8l0r63jkkkqekr8t8qmp250uy' is not a constraint.
INFO  - >>> WARN  - 'FK3gcixbe5ypjdvowesjlk6c5o5' is not a constraint.
INFO  - >>> WARN  - 'FKgxcajqp8l0a5wao81h8r74b5o' is not a constraint.
INFO  - >>> WARN  - 'FK55r3h3w3hvjfk7my2sxehrlrm' is not a constraint.
INFO  - >>> WARN  - 'FK1njuk36hbw21usdknnnl2ayoj' is not a constraint.
INFO  - >>> WARN  - 'FKf907bxrbypl4mt9fewl9qg2vi' is not a constraint.
INFO  - >>> WARN  - 'FKa4yxlmni7k3u9gh7o1jjl9euj' is not a constraint.
INFO  - >>> WARN  - 'FKcb9vwo9sjwckdg83gbffdxbqm' is not a constraint.
INFO  - >>> WARN  - 'FK9n5npbjl3mxljrl43kooiite6' is not a constraint.
INFO  - >>> WARN  - 'FKa2o1pyy1e5rclmp0v4gboy44n' is not a constraint.
INFO  - >>> WARN  - 'FK2nngpvul6j14xn2uyq9rskljs' is not a constraint.
INFO  - >>> WARN  - 'FKif10nknj4pb4r0sdd9t0ufyp9' is not a constraint.
INFO  - >>> WARN  - 'FKbn0s10y9kps3g2jrx24498rhj' is not a constraint.
INFO  - >>> WARN  - 'FK47nc1l5eebdn0jfyyybkwt34l' is not a constraint.
INFO  - >>> WARN  - 'FKogh87b4r56efi0bqf80rirlbj' is not a constraint.
INFO  - >>> WARN  - 'FKmvb846t5fuqvpnyougbpwdpnu' is not a constraint.
INFO  - >>> WARN  - 'FKaahhaoocvd8drbxitx5kgmh3e' is not a constraint.
INFO  - >>> WARN  - 'FK437qqac29fs6efus0swrwnps6' is not a constraint.
INFO  - >>> WARN  - 'FKd0b9jjyhe7vxn73dlqfdn3v0j' is not a constraint.
INFO  - >>> WARN  - 'FKdsqfgte4rkhofk935gg2fw2by' is not a constraint.
INFO  - >>> WARN  - 'FKagoy30ssjrvn47q04ci0buw3h' is not a constraint.
INFO  - >>> WARN  - 'FKqj624bp9ktwcx4sq6cgu215mo' is not a constraint.
INFO  - >>> WARN  - 'FKqclmyk872u9ph2ekgfyl8q79a' is not a constraint.
INFO  - >>> WARN  - 'FKbwc0hech4vace79h0bhma4ujb' is not a constraint.
INFO  - >>> WARN  - 'FKhcybgc5rxadnhgjf53pw02erp' is not a constraint.
INFO  - >>> WARN  - 'FKeg3ghs1463qm9eddmnq04q0w1' is not a constraint.
INFO  - >>> WARN  - 'FKiehj0wl2a4p73ua1gvno69qyn' is not a constraint.
INFO  - >>> WARN  - 'FKd7oouyfdhy1v6pjqdh2ogofby' is not a constraint.
INFO  - >>> WARN  - 'FK59enyp88rmhgp5k1h6ls7eshh' is not a constraint.
INFO  - >>> WARN  - 'FKjno26eqa5mowa41xpme4rwjqq' is not a constraint.
INFO  - >>> WARN  - 'FKf5c832pvr1pe8omct8nq0uhd8' is not a constraint.
INFO  - >>> INFO  - Database is cleaned successfully
INFO  - >>> INFO  - Stopping application...
INFO  - Restoring old program files...
INFO  - Old program files restored
INFO  - Restoring old database...
INFO  - >>> INFO  - Launching application from 'C:\onedev-latest\onedev-latest'...
INFO  - >>> INFO  - Cleaning temp directory...
INFO  - >>> INFO  - Starting application...
INFO  - >>> INFO  - Restoring database from C:\onedev-latest\onedev-latest\site\db-backup\2025-08-06_23-53-34.zip...
INFO  - >>> INFO  - Waiting for server to stop...
INFO  - >>> INFO  - Creating tables...
INFO  - >>> INFO  - Importing data into database...
INFO  - >>> INFO  - Importing from data file 'ModelVersions.xml'...
INFO  - >>> INFO  - Importing from data file 'Roles.xml'...
INFO  - >>> INFO  - Importing from data file 'LabelSpecs.xml'...
INFO  - >>> INFO  - Importing from data file 'ProjectLastEventDates.xml'...
INFO  - >>> INFO  - Importing from data file 'Projects.xml'...
INFO  - >>> INFO  - Importing from data file 'Users.xml'...
INFO  - >>> INFO  - Importing from data file 'Issues.xml'...
INFO  - >>> INFO  - Importing from data file 'IssueChanges.xml'...
INFO  - >>> INFO  - Importing from data file 'AgentTokens.xml'...
INFO  - >>> INFO  - Importing from data file 'Builds.xml'...
INFO  - >>> INFO  - Importing from data file 'SshKeys.xml'...
INFO  - >>> INFO  - Importing from data file 'Iterations.xml'...
INFO  - >>> INFO  - Importing from data file 'IssueSchedules.xml'...
INFO  - >>> INFO  - Importing from data file 'IssueComments.xml'...
INFO  - >>> INFO  - Importing from data file 'IssueStateHistorys.xml'...
INFO  - >>> INFO  - Importing from data file 'IssueFields.xml'...
INFO  - >>> INFO  - Importing from data file 'IssueTouchs.xml'...
INFO  - >>> INFO  - Importing from data file 'LinkSpecs.xml'...
INFO  - >>> INFO  - Importing from data file 'BuildQueryPersonalizations.xml'...
INFO  - >>> INFO  - Importing from data file 'IssueAuthorizations.xml'...
INFO  - >>> INFO  - Importing from data file 'BuildDependences.xml'...
INFO  - >>> INFO  - Importing from data file 'IssueWatchs.xml'...
INFO  - >>> INFO  - Importing from data file 'Groups.xml'...
INFO  - >>> INFO  - Importing from data file 'GroupAuthorizations.xml'...
INFO  - >>> INFO  - Importing from data file 'AccessTokens.xml'...
INFO  - >>> INFO  - Importing from data file 'Memberships.xml'...
INFO  - >>> INFO  - Importing from data file 'BuildLabels.xml'...
INFO  - >>> INFO  - Importing from data file 'EmailAddresss.xml'...
INFO  - >>> INFO  - Importing from data file 'IssueVotes.xml'...
INFO  - >>> INFO  - Importing from data file 'Settings.xml'...
INFO  - >>> INFO  - Importing from data file 'UserAuthorizations.xml'...
INFO  - >>> INFO  - Applying foreign key constraints...
INFO  - >>> INFO  - Database is successfully restored from C:\onedev-latest\onedev-latest\site\db-backup\2025-08-06_23-53-34.zip
INFO  - >>> INFO  - Stopping application...
INFO  - Old database restored
ERROR - !! Failed to upgrade C:\onedev-latest\onedev-latest
INFO  - Stopping application...
<-- Wrapper Stopped
Press any key to continue . . .

console.log_2.zip

  • Robin Shen commented 5 months ago

    Seems you are using MS SQL Server? OneDev no longer supports it since v11.6.0 (https://code.onedev.io/~help/incompatibilities#1160). Please switch to either MySQL or PostgreSQL.

  • Brent Hitzeroth commented 5 months ago

    This comes as a bit of a shock as our whole environment is built on mssql? Its not like we can just change company standards, this is a mainstream DB? I see from the docs there are three supported DB's and a backup / restore procedure to migrate to a different DB will this work in my case from MSsql to PostgreSQL for example?

  • Brent Hitzeroth commented 5 months ago

    I upgraded to latest java and installed Postgresql 17 and followed upgrade instructions but still getting an error with no data being put in new db.

    Microsoft Windows [Version 10.0.14393]
    (c) 2016 Microsoft Corporation. All rights reserved.
    
    C:\Users\Administrator>cd\
    
    C:\>cd C:\onedev-latest\onedev-latest\bin
    
    C:\onedev-latest\onedev-latest\bin>restore-db.bat c:\onedevbackup25
    --> Wrapper Started as Console
    Java Service Wrapper Standard Edition 64-bit 3.5.51
      Copyright (C) 1999-2022 Tanuki Software, Ltd. All Rights Reserved.
        http://wrapper.tanukisoftware.com
      Licensed to OneDev for Service Wrapping
    
    Launching a JVM...
    WrapperManager: Initializing...
    WARNING: A restricted method in java.lang.System has been called
    WARNING: java.lang.System::loadLibrary has been called by org.tanukisoftware.wrapper.WrapperManager in an unnamed module (file:/C:/onedev-latest/onedev-latest/boot/wrapper.jar)
    WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for callers in this module
    WARNING: Restricted methods will be blocked in a future release unless native access is enabled
    
    Detected that the Java process launched by the Wrapper (PID 2972) was redirected to C:\Program Files\Java\jdk-24\bin\java.exe (PID 3404).
     Switch to monitoring the Java process.
    INFO  - Launching application from 'C:\onedev-latest\onedev-latest'...
    INFO  - Cleaning temp directory...
    INFO  - Starting application...
    WARNING: A terminally deprecated method in sun.misc.Unsafe has been called
    WARNING: sun.misc.Unsafe::objectFieldOffset has been called by com.google.common.util.concurrent.AbstractFuture$UnsafeAtomicHelper (file:/C:/onedev-latest/onedev-latest/lib/com.google.guava.guava-32.0.1-jre.jar)
    WARNING: Please consider reporting this to the maintainers of class com.google.common.util.concurrent.AbstractFuture$UnsafeAtomicHelper
    WARNING: sun.misc.Unsafe::objectFieldOffset will be removed in a future release
    INFO  - Restoring database from c:\onedevbackup25...
    ERROR - Error booting application
    java.lang.RuntimeException: java.lang.ClassNotFoundException: org.postgresql.driver
            at io.onedev.commons.bootstrap.Bootstrap.unchecked(Bootstrap.java:319)
            at io.onedev.commons.utils.ExceptionUtils.unchecked(ExceptionUtils.java:31)
            at io.onedev.server.persistence.PersistenceUtils.openConnection(PersistenceUtils.java:38)
            at io.onedev.server.commandhandler.CommandHandler.doMaintenance(CommandHandler.java:34)
            at io.onedev.server.commandhandler.RestoreDatabase.start(RestoreDatabase.java:67)
            at io.onedev.commons.loader.DefaultPluginManager.start(DefaultPluginManager.java:44)
            at io.onedev.commons.loader.AppLoader.start(AppLoader.java:60)
            at io.onedev.commons.bootstrap.Bootstrap.main(Bootstrap.java:200)
            at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
            at java.base/java.lang.reflect.Method.invoke(Method.java:565)
            at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:349)
            at java.base/java.lang.Thread.run(Thread.java:1447)
    Caused by: java.lang.ClassNotFoundException: org.postgresql.driver
            at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:349)
            at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:557)
            at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:490)
            at java.base/java.lang.Class.forName0(Native Method)
            at java.base/java.lang.Class.forName(Class.java:543)
            at io.onedev.server.persistence.PersistenceUtils.openConnection(PersistenceUtils.java:27)
            ... 9 common frames omitted
    INFO  - Stopping application...
    <-- Wrapper Stopped
    Press any key to continue . . .
    
    C:\onedev-latest\onedev-latest\bin>
    
  • Brent Hitzeroth commented 5 months ago

    My Postgresql config

    mstsc_kHMirfwWu5.png mstsc_wHPU6zJYUr.png

  • Brent Hitzeroth commented 5 months ago

    I do not know if it is relevant but in the error I see "org.postgresql.driver" when I think it is "org.postgresql.Driver". If case sensitive could cause an issue?

    I went ahead and changed the spelling and the error changed.

    restore-db.log

  • Brent Hitzeroth commented 5 months ago

    I changed the config as follows and now get data in the DB but in the wrong schema.

    changed as follows:

    hibernate.dialect=io.onedev.server.persistence.PostgreSQLDialect
    hibernate.connection.driver_class=org.postgresql.Driver hibernate.connection.url=jdbc:postgresql://localhost:5432/onedev?currentschema=onedev hibernate.connection.username=postgres hibernate.connection.password=Brent1969!

    restore-db_2.log

  • Brent Hitzeroth commented 5 months ago

    This is about as far as I got, the data pushes to the correct DB but does not seem to be able to start due to a "UNKNOWN" user issue. Everything seems good in Postgres, here is my last install log after I created a clean database and retried.

    log.txt

  • Robin Shen commented 5 months ago

    The user name unknown is reserved for other purposes. Please change to use another name.

  • Robin Shen commented 5 months ago

    Please disregard my previous comment. Please check your hibernate.properties to make sure property javax.persistence.validation.mode is set to none which is the default setting for OneDev.

  • Brent Hitzeroth commented 5 months ago

    Hi thank you, after setting validation mode the database upgrade worked fine. I then also upgraded to the latest Onedev version successfully however when testing I encountered an error with creating a new issue. I received the error below. I had this issue on a previous version and I had to revert to an older version of java, is this the same problem?

    HTTP ERROR 500 javax.servlet.ServletException: Filtered request failed. URI: /Form5/~issues/new STATUS: 500 MESSAGE: javax.servlet.ServletException: Filtered request failed. SERVLET: io.onedev.server.web.DefaultWicketServlet-6337a06d CAUSED BY: javax.servlet.ServletException: Filtered request failed. CAUSED BY: BUG! exception in phase 'semantic analysis' in source unit 'Script_6977fe0f2d6cd6a70bb5e589057f6f8c.groovy' Unsupported class file major version 68 CAUSED BY: java.lang.IllegalArgumentException: Unsupported class file major version 68 Caused by: javax.servlet.ServletException: Filtered request failed. at org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:392) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:154) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1626) at io.onedev.server.security.CorsFilter.doFilter(CorsFilter.java:47) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1626) at io.onedev.server.jetty.DisableTraceFilter.doFilter(DisableTraceFilter.java:28) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1626) at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:552) at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233) at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1624) at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233) at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1440) at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188) at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:505) at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1594) at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186) at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1355) at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) at org.eclipse.jetty.server.handler.gzip.GzipHandler.handle(GzipHandler.java:772) at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) at org.eclipse.jetty.server.Server.handle(Server.java:516) at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:487) at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:732) at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:479) at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277) at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105) at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131) at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:409) at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883) at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034) at java.base/java.lang.Thread.run(Thread.java:1447) Caused by: BUG! exception in phase 'semantic analysis' in source unit 'Script_6977fe0f2d6cd6a70bb5e589057f6f8c.groovy' Unsupported class file major version 68 at org.codehaus.groovy.control.CompilationUnit$ISourceUnitOperation.doPhaseOperation(CompilationUnit.java:906) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:628) at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:389) at groovy.lang.GroovyClassLoader.lambda$parseClass$3(GroovyClassLoader.java:332) at org.codehaus.groovy.runtime.memoize.StampedCommonCache.compute(StampedCommonCache.java:163) at org.codehaus.groovy.runtime.memoize.StampedCommonCache.getAndPut(StampedCommonCache.java:154) at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:330) at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:314) at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:257) at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:268) at io.onedev.server.util.GroovyUtils.compile(GroovyUtils.java:32) at io.onedev.server.util.GroovyUtils.evalScript(GroovyUtils.java:103) at io.onedev.server.buildspecmodel.inputspec.InputSpec.defineClass(InputSpec.java:261) at io.onedev.server.model.support.issue.field.FieldUtils.defineFieldBeanClass(FieldUtils.java:76) at io.onedev.server.model.support.issue.field.FieldUtils.getFieldBeanClass(FieldUtils.java:64) at io.onedev.server.web.component.issue.create.NewIssueEditor.onInitialize(NewIssueEditor.java:108) at org.apache.wicket.Component.fireInitialize(Component.java:883) at org.apache.wicket.MarkupContainer$3.component(MarkupContainer.java:1077) at org.apache.wicket.MarkupContainer$3.component(MarkupContainer.java:1073) at org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:144) at org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:123) at org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:192) at org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:984) at org.apache.wicket.MarkupContainer.internalInitialize(MarkupContainer.java:1072) at org.apache.wicket.MarkupContainer.addedComponent(MarkupContainer.java:1048) at org.apache.wicket.MarkupContainer.add(MarkupContainer.java:242) at io.onedev.server.web.page.project.issues.create.NewIssuePage.onInitialize(NewIssuePage.java:118) at org.apache.wicket.Component.fireInitialize(Component.java:883) at org.apache.wicket.MarkupContainer.internalInitialize(MarkupContainer.java:1071) at org.apache.wicket.Page.isPageStateless(Page.java:465) at org.apache.wicket.core.request.mapper.AbstractBookmarkableMapper.getPageInfo(AbstractBookmarkableMapper.java:498) at org.apache.wicket.core.request.mapper.AbstractBookmarkableMapper.mapHandler(AbstractBookmarkableMapper.java:443) at org.apache.wicket.core.request.mapper.MountedMapper.mapHandler(MountedMapper.java:160) at org.apache.wicket.request.mapper.CompoundRequestMapper.mapHandler(CompoundRequestMapper.java:210) at org.apache.wicket.request.mapper.CompoundRequestMapper.mapHandler(CompoundRequestMapper.java:210) at org.apache.wicket.request.cycle.RequestCycle.mapUrlFor(RequestCycle.java:418) at org.apache.wicket.request.handler.render.WebPageRenderer.respond(WebPageRenderer.java:233) at org.apache.wicket.core.request.handler.RenderPageRequestHandler.respond(RenderPageRequestHandler.java:175) at org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:892) at org.apache.wicket.request.RequestHandlerStack.execute(RequestHandlerStack.java:64) at org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:261) at org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:218) at org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:289) at org.apache.wicket.protocol.ws.AbstractUpgradeFilter.processRequestCycle(AbstractUpgradeFilter.java:70) at org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:203) at org.apache.wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:137) at javax.servlet.http.HttpServlet.service(HttpServlet.java:687) at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) at io.onedev.server.web.DefaultWicketServlet.lambda$service$0(DefaultWicketServlet.java:48) at io.onedev.server.persistence.DefaultSessionManager.lambda$run$0(DefaultSessionManager.java:108) at io.onedev.server.persistence.DefaultSessionManager.call(DefaultSessionManager.java:90) at io.onedev.server.persistence.DefaultSessionManager.run(DefaultSessionManager.java:107) at io.onedev.server.web.DefaultWicketServlet.service(DefaultWicketServlet.java:42) at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:799) at org.eclipse.jetty.servlet.ServletHandler$ChainEnd.doFilter(ServletHandler.java:1656) at com.google.inject.servlet.DefaultFilterPipeline.dispatch(DefaultFilterPipeline.java:47) at com.google.inject.servlet.GuiceFilter.doFilter(GuiceFilter.java:133) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1626) at io.onedev.server.git.GoGetFilter.doFilter(GoGetFilter.java:90) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1626) at io.onedev.server.git.GitLfsFilter.doFilter(GitLfsFilter.java:502) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1626) at io.onedev.server.git.GitFilter.doFilter(GitFilter.java:395) at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1626) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:61) at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108) at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:154) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66) at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108) at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:154) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66) at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108) at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:154) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66) at org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(AbstractShiroFilter.java:458) at org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiroFilter.java:373) at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90) at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83) at org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:387) at org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:370) ... 38 more Caused by: java.lang.IllegalArgumentException: Unsupported class file major version 68 at groovyjarjarasm.asm.ClassReader.(ClassReader.java:199) at groovyjarjarasm.asm.ClassReader.(ClassReader.java:180) at groovyjarjarasm.asm.ClassReader.(ClassReader.java:166) at groovyjarjarasm.asm.ClassReader.(ClassReader.java:287) at org.codehaus.groovy.ast.decompiled.AsmDecompiler.parseClass(AsmDecompiler.java:81) at org.codehaus.groovy.control.ClassNodeResolver.findDecompiled(ClassNodeResolver.java:251) at org.codehaus.groovy.control.ClassNodeResolver.tryAsLoaderClassOrScript(ClassNodeResolver.java:189) at org.codehaus.groovy.control.ClassNodeResolver.findClassNode(ClassNodeResolver.java:169) at org.codehaus.groovy.control.ClassNodeResolver.resolveName(ClassNodeResolver.java:125) at org.codehaus.groovy.control.ResolveVisitor.resolveToOuter(ResolveVisitor.java:869) at org.codehaus.groovy.control.ResolveVisitor.resolve(ResolveVisitor.java:506) at org.codehaus.groovy.control.ResolveVisitor.resolve(ResolveVisitor.java:467) at org.codehaus.groovy.control.ResolveVisitor.resolveOrFail(ResolveVisitor.java:337) at org.codehaus.groovy.control.ResolveVisitor.visitClass(ResolveVisitor.java:1456) at org.codehaus.groovy.control.ResolveVisitor.startResolving(ResolveVisitor.java:262) at org.codehaus.groovy.control.CompilationUnit.lambda$new$16(CompilationUnit.java:739) at org.codehaus.groovy.control.CompilationUnit$ISourceUnitOperation.doPhaseOperation(CompilationUnit.java:902) ... 124 more

  • Robin Shen commented 5 months ago

    OneDev only supports LTS versions, please use Java 21/17/11 instead.

  • Brent Hitzeroth commented 5 months ago

    Thank you all is working except a previously mentioned issue OD-2512 .

  • Brent Hitzeroth commented 5 months ago

    Successfully migrated from MSsql to PostreSQL and upgraded to latest Onedev.

  • Brent Hitzeroth changed state to 'Closed' 5 months ago
    Previous Value Current Value
    Open
    Closed
issue 1/1
Type
Bug
Priority
Critical
Assignee
Affected Versions
12.0.4
Labels
No labels
Issue Votes (0)
Watchers (4)
Reference
OD-2516
Please wait...
Connection lost or session expired, reload to recover
Page is in error, reload to recover