mirror of
https://github.com/google/nomulus.git
synced 2025-07-09 04:33:28 +02:00
Alt entity model for fast JPA bulk query (#1398)
* Alt entity model for fast JPA bulk query Defined an alternative JPA entity model that allows fast bulk loading of multi-level entities, DomainBase and DomainHistory. The idea is to bulk the base table as well as the child tables separately, and assemble them into the target entity in memory in a pipeline. For DomainBase: - Defined a DomainBaseLite class that models the "Domain" table only. - Defined a DomainHost class that models the "DomainHost" table (nsHosts field). - Exposed ID fields in GracePeriod so that they can be mapped to domains after being loaded into memory. For DomainHistory: - Defined a DomainHistoryLite class that models the "DomainHistory" table only. - Defined a DomainHistoryHost class that models its namesake table. - Exposed ID fields in GracePeriodHistory and DomainDsDataHistory classes so that they can be mapped to DomainHistory after being loaded into memory. In PersistenceModule, provisioned a JpaTransactionManager that uses the alternative entity model. Also added a pipeline option that specifies which JpaTransactionManager to use in a pipeline.
This commit is contained in:
parent
8a4ac6511b
commit
9f08e8624b
25 changed files with 1208 additions and 68 deletions
|
@ -412,12 +412,12 @@
|
|||
|
||||
create table "DomainTransactionRecord" (
|
||||
id bigserial not null,
|
||||
domain_repo_id text,
|
||||
history_revision_id int8,
|
||||
report_amount int4 not null,
|
||||
report_field text not null,
|
||||
reporting_time timestamptz not null,
|
||||
tld text not null,
|
||||
domain_repo_id text,
|
||||
history_revision_id int8,
|
||||
primary key (id)
|
||||
);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue