この自己回答が投稿されているので、数か月後にもう一度それを壊すと、実際にはGoogleで答えが出ます。Proguardが飛行機データベースの移行を中断する
データベーススキーマの移行にFlyway APIが使用されるシンプルなJavaプロジェクト。 V1__init.sql、V2__updateCustomerTable.sqlの規則に従うSQLスクリプトのリソースディレクトリを使用して、schema_versionメタデータテーブルを確認し、必要に応じて移行します。
すべては、瓶が保護されるまでうまく動作します。 SQLスクリプトは、間違いなく、jarファイルにパックされているが、それらが発見されていません。
2017-04-10 17:17:13,612 [main] DEBUG (?:?) - Validating migrations ...
2017-04-10 17:17:13,884 [main] DEBUG (?:?) - Scanning for classpath resources at 'classpath:db/migration/postgres' (Prefix: '', Suffix: '.sql')
2017-04-10 17:17:13,885 [main] DEBUG (?:?) - Determining location urls for classpath:db/migration/postgres using ClassLoader [email protected] ...
2017-04-10 17:17:13,885 [main] WARN (?:?) - Unable to resolve location classpath:db/migration/postgres
2017-04-10 17:17:13,899 [main] DEBUG (?:?) - Scanning for classpath resources at 'classpath:db/migration/postgres' (Prefix: 'V', Suffix: '.sql')
2017-04-10 17:17:13,900 [main] DEBUG (?:?) - Scanning for classpath resources at 'classpath:db/migration/postgres' (Prefix: 'R', Suffix: '.sql')
非proguarded瓶は(それが今jarファイルに見えることに注意してください)次のログメッセージでそれらを見つける:
2017-04-10 17:07:16,612 [main] DEBUG (?:?) - Validating migrations ...
2017-04-10 17:07:16,613 [main] DEBUG (?:?) - Scanning for classpath resources at 'classpath:db/migration/postgres' (Prefix: 'V', Suffix: '.sql')
2017-04-10 17:07:16,614 [main] DEBUG (?:?) - Scanning URL: jar:file:/C:/Dev/Sanbox/myjar.jar!/db/migration/postgres
2017-04-10 17:07:16,614 [main] DEBUG (?:?) - JBoss VFS v2 available: false
2017-04-10 17:07:16,615 [main] DEBUG (?:?) - Filtering out resource: db/migration/postgres/ (filename:)
2017-04-10 17:07:16,615 [main] DEBUG (?:?) - Found resource: db/migration/postgres/V1__init.sql
2017-04-10 17:07:16,616 [main] DEBUG (?:?) - Found resource: db/migration/postgres/V2__updateCustomerTable.sql