Migration V22__add_user_session_token_index.sql failed

win029 1月前 128

按教程修改了:

1.修改wildfirechat.conf文件中的server.ip为服务器ip地址,embed.db 0,

2.修改c3p0-config.xml文件中的root口令,其它都没有修改。

win8系统+mysql5.7,同样的环境运行之前的0.27版执行没有问题。具体错误信息如图

D:\webserver\im-server-release038>bin\wildfirechat.bat

Using JAVA_HOME: "C:\Program Files\Java\jdk1.8.0_201"

Using WILDFIRECHAT_HOME: "D:\webserver\im-server-release038"

Exception in thread "main" org.flywaydb.core.internal.command.DbMigrate$FlywayMigrateException:

Migration V22__add_user_session_token_index.sql failed

SQL State : 42000 Error Code : 1071 Message : Specified key was too long; max key length is 767 bytes Location : .\migrate\mysql\V22add_user_session_token_index.sql (D:\webserver\im-server-release038.\migrate\mysql\V22add_user_session_token_index.sql) Line : 1 Statement : alter table t_user_session ADD INDEX session_token_index ( _token ) at org.flywaydb.core.internal.command.DbMigrate.doMigrateGroup(DbMigrate.java:370) at org.flywaydb.core.internal.command.DbMigrate.access$200(DbMigrate.java:54) at org.flywaydb.core.internal.command.DbMigrate$3.call(DbMigrate.java:284) at org.flywaydb.core.internal.jdbc.TransactionTemplate.execute(TransactionTemplate.java:74) at org.flywaydb.core.internal.command.DbMigrate.applyMigrations(DbMigrate.java:281) at org.flywaydb.core.internal.command.DbMigrate.migrateGroup(DbMigrate.java:246) at org.flywaydb.core.internal.command.DbMigrate.access$100(DbMigrate.java:54) at org.flywaydb.core.internal.command.DbMigrate$2.call(DbMigrate.java:164) at org.flywaydb.core.internal.command.DbMigrate$2.call(DbMigrate.java:161) at org.flywaydb.core.internal.database.mysql.MySQLNamedLockTemplate.execute(MySQLNamedLockTemplate.java:60) at org.flywaydb.core.internal.database.mysql.MySQLConnection.lock(MySQLConnection.java:147) at org.flywaydb.core.internal.schemahistory.JdbcTableSchemaHistory.lock(JdbcTableSchemaHistory.java:155) at org.flywaydb.core.internal.command.DbMigrate.migrateAll(DbMigrate.java:161) at org.flywaydb.core.internal.command.DbMigrate.migrate(DbMigrate.java:139) at org.flywaydb.core.Flyway$1.execute(Flyway.java:1395) at org.flywaydb.core.Flyway$1.execute(Flyway.java:1356) at org.flywaydb.core.Flyway.execute(Flyway.java:1711) at org.flywaydb.core.Flyway.migrate(Flyway.java:1356) at win.liyufan.im.DBUtil.init(DBUtil.java:103) at io.moquette.server.Server.startServer(Server.java:223) at io.moquette.server.Server.startServer(Server.java:215) at io.moquette.server.Server.startServer(Server.java:199) at io.moquette.server.Server.start(Server.java:109) at cn.wildfirechat.server.Server.main(Server.java:15) Caused by: org.flywaydb.core.internal.sqlscript.FlywaySqlScriptException:

Migration V22__add_user_session_token_index.sql failed

上传的附件:
最新回复 (2)
  • x86 1月前
    引用 2
    你可以把你的 mysql升级一下,5.7.27没问题
  • win029 1月前
    引用 3
    非常感谢x86,升级数据库到5.7.27后一切运行正常!
返回