Skip to content

Commit

Permalink
fix: Add indexes to event table
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielPalafox committed Oct 26, 2023
1 parent 33928a0 commit 0fc6b24
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
1 change: 1 addition & 0 deletions orcid-persistence/src/main/resources/db-master.xml
Original file line number Diff line number Diff line change
Expand Up @@ -376,4 +376,5 @@
<include file="/db/updates/create_email_domain_mapping_tables.xml" />
<include file="/db/updates/create_event_table.xml" />
<include file="/db/updates/dw_event.xml" />
<include file="/db/updates/create_event_indexes.xml" />
</databaseChangeLog>
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-2.0.xsd">

<changeSet id="EVENT-ORCID-INDEX" author="Daniel Palafox">
<preConditions onFail="MARK_RAN">
<not>
<indexExists indexName="event_orcid_index" tableName="event"/>
</not>
</preConditions>
<sql>create index event_orcid_index on event(orcid);</sql>
</changeSet>

<changeSet id="EVENT-CLIENT-ID-INDEX" author="Daniel Palafox">
<preConditions onFail="MARK_RAN">
<not>
<indexExists indexName="event_client_id_index" tableName="event"/>
</not>
</preConditions>
<sql>create index event_client_id_index on event(client_id);</sql>
</changeSet>

<changeSet id="EVENT-TYPE-INDEX" author="Daniel Palafox">
<preConditions onFail="MARK_RAN">
<not>
<indexExists indexName="event_type_index" tableName="event"/>
</not>
</preConditions>
<sql>create index event_type_index on event(event_type);</sql>
</changeSet>
</databaseChangeLog>

0 comments on commit 0fc6b24

Please sign in to comment.