我有一个工作的游戏框架应用程序。我试图在应用程序上启用数据库演化支持。我通过添加以下设置更改了application.conf文件]
db.default.driver=org.postgresql.Driver db.default.url="jdbc:postgresql://localhost:5432/scaladb" db.default.username=scalauser db.default.password=****** db.default.poolInitialSize=1 db.default.poolMaxSize=5 db.default.ConnectionTimeoutMillis=1000 play.evolutions.autoApply=true
该数据库已存在,我可以使用类似
sql -U scalauser -d scaladb
的命令连接到它>我将以下行添加到我的AppLoader类中,以设置数据库并运行迁移
val onStart = { applicationEvolutions DBs.setupAll() } applicationLifecycle.addStopHook{() => DBs.closeAll() Future.successful(Unit) }
但是现在当我用
set run
运行我的应用程序时,我得到了这个神秘的错误消息,它实际上没有任何意义。我什至不确定这是试图告诉我的框架akka.http.impl.util.One2OneBidiFlow$OutputTruncationException: Inner flow was completed without producing result elements for 1 outstanding elements at akka.http.impl.util.One2OneBidiFlow$OutputTruncationException$.apply(One2OneBidiFlow.scala:22) at akka.http.impl.util.One2OneBidiFlow$OutputTruncationException$.apply(One2OneBidiFlow.scala:22) at akka.http.impl.util.One2OneBidiFlow$One2OneBidi$$anon$1$$anon$4.onUpstreamFinish(One2OneBidiFlow.scala:97) at akka.stream.impl.fusing.GraphInterpreter.processEvent(GraphInterpreter.scala:504) at akka.stream.impl.fusing.GraphInterpreter.execute(GraphInterpreter.scala:378) at akka.stream.impl.fusing.GraphInterpreterShell.runBatch(ActorGraphInterpreter.scala:588) at akka.stream.impl.fusing.GraphInterpreterShell$AsyncInput.execute(ActorGraphInterpreter.scala:472) at akka.stream.impl.fusing.GraphInterpreterShell.processEvent(ActorGraphInterpreter.scala:563) at akka.stream.impl.fusing.ActorGraphInterpreter.akka$stream$impl$fusing$ActorGraphInterpreter$$processEvent(ActorGraphInterpreter.scala:
我有一个工作的游戏框架应用程序。我试图在应用程序上启用数据库演化支持。我通过添加以下设置更改了application.conf文件:db.default.driver = org ....
确定。我想到了。问题是配置文件格式错误。线
db.default.driver=org.postgresql.Driver
db.default.username=scalauser
db.default.password=******