daml/libs-scala
Samir Talwar c81cc2ab2a ledger-on-sql: Migrate tables using Flyway. (#4232)
* ledger-on-sql: Pull out a superclass for the various integration tests.

* ledger-on-sql: Use Flyway to migrate tables in an idempotent manner.

CHANGELOG_BEGIN
CHANGELOG_END

* ledger-on-sql: Make it easy to run it with Bazel for experimentation.

* ledger-on-sql: Test that migrations will never change in the future.

* ledger-on-sql: Add a prefix of "ledger_" to the tables.

This is so we don't accidentally conflict with the index when the
schemas are shared.

I am letting myself modify the migrations because the existing
migrations haven't been merged into `master` yet.

* ledger-on-sql: Explain why we change the pool size after migration.

* ledger-api-test-tool: Tests now specify a timeout scale, not a timeout.

Makes it easier to change the default timeout in one place.

* ledger-api-test-tool: Increase timeouts on slow tests.

These tests produce a lot of volume and can make CI flaky.

* ledger-on-sql: Only tear down PostgreSQL in tests.

For other databases, we just create a new file for each test case.

* ledger-on-sql: Reduce the log output in tests.

* ledger-on-sql: Use a separate connection pool for Flyway when possible.

Apparently `setMaximumPoolSize` doesn't really have the desired effect
after the connection pool has already been used. The new test case will
be flaky if we process more than one commit in parallel.

For SQLite, it seems to be OK.

* ledger-on-sql: Use a separate connection pool for Flyway with SQLite.

Except in memory.

* ledger-on-sql: Use a separate PostgreSQL database for each test.

Because performance, innit. Don't have to tear them down.

* ledger-on-sql: Move the `Queries` values inside the `RDBMS` objects.

* ledger-on-sql: Go into even more detail about pool size hijinks.

Co-authored-by: Samir Talwar <samir.talwar@digitalasset.com>
2020-01-28 16:16:23 +00:00
..
auth-utils update copyright notices to 2020 (#3939) 2020-01-02 21:21:13 +01:00
contextualized-logging Add logging context information to ledger services (#4205) 2020-01-24 18:28:08 +00:00
direct-execution-context Replace NamedLoggerFactory (#4097) 2020-01-21 10:57:28 +01:00
grpc-utils update copyright notices to 2020 (#3939) 2020-01-02 21:21:13 +01:00
postgresql-testing ledger-on-sql: Migrate tables using Flyway. (#4232) 2020-01-28 16:16:23 +00:00
resources kvutils: Use resources in KeyValueParticipantState, not AutoClo… (#4177) 2020-01-23 16:59:01 +01:00
resources-akka libs-scala/resources: Move Resource and friends to their own package. (#4066) 2020-01-16 14:13:18 +00:00
timer-utils ledger-on-posix-filesystem: Fix the tests on CI. (#4166) 2020-01-22 18:02:23 +01:00