1

我只想询问有关推出 Java 桌面应用程序的最佳实践,包括嵌入式数据库(如 JavaDB)。

1.问题:

我使用嵌入式 JavaDB 创建了我的应用程序的 1.0 版以进行部署。我应该在我的推出包中提供数据库文件,还是应用程序应该在第一次启动时创建嵌入式数据库文件?

2.问题:

现在是发布 1.1 的时候了,数据库结构发生了变化。如何交付更新?发布策略是否有最佳实践?

谢谢,丹尼尔

4

1 回答 1

0
  1. Do whatever is easier for you. Personaly I think beeing able to create a new DB on the fly is more conventient for developers.
  2. You need an update script. If this happens more than once, put the version number 1.0, 1.1, ... into the db. This way you can check what update scripts have to run automatically and you can make sure your software and db do match.
于 2013-09-09T09:21:44.157 回答