This recent post, How to use Evolutions in Play Framework 2.0?, says that evolutions will automatically be applied when running Play 2.0. I've tried the play-2.0-beta download and latest git code, and I'm not seeing this behavior. In fact, I can't find any way to apply the evolutions in production mode. Am I missing something?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Adding applyEvolutions.default=true
to your application.conf will enable evolutions by default in your application.
回答2:
Please try one of the Play 20 sample applications and you will be prompted to apply evolutions upon application startup - the request appears in the application browser the first time you start the app.
回答3:
As of RC-3, the new location of the evolutions scripts is in conf/evolutions/[dbname]/1.sql. Otherwise, the information above is all still accurate.