Playframework 2.0 重头戏2.1框架未检测到进化变化

Playframework 2.0 重头戏2.1框架未检测到进化变化,playframework-2.0,ebean,playframework-evolutions,Playframework 2.0,Ebean,Playframework Evolutions,将@ManyToMany联接表添加到两个模型(在本例中为用户和文章模型[1])时,Play会正确检测这些更改,并相应地修改1.sql[2]文件: [1] + @ManyToMany + public List<User> authors; + @ManyToMany(mappedBy="authors") + public List<Article> authoredArticles; [2] + create table article

将@ManyToMany联接表添加到两个模型(在本例中为用户和文章模型[1])时,Play会正确检测这些更改,并相应地修改1.sql[2]文件:

[1]
+    @ManyToMany
+    public List<User> authors;

+    @ManyToMany(mappedBy="authors")
+    public List<Article> authoredArticles;

[2]
+    create table articles_users (
+      articles_id                    bigint not null,
+      users_id                       bigint not null,
+      constraint pk_articles_users primary key (articles_id, users_id)
+    );

+    alter table articles_users add constraint fk_articles_users_articles_01 foreign key (articles_id) references articles (id);
+    alter table articles_users add constraint fk_articles_users_users_02 foreign key (users_id) references users (id);

# --- !Downs

+    drop table if exists articles_users cascade;

为什么Play没有检测到它对需要应用的数据库架构进行了更改?

检查Play\u evolutions表,如果已经有id为1的行,则必须将sql文件重命名为2.sql或手动删除这些表。

在生产或开发环境中是否存在此问题?开发,该应用程序当前未投入生产。
PersistenceException: Query threw SQLException:ERROR: relation "articles_users" does not exist