-
Notifications
You must be signed in to change notification settings - Fork 994
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PHOENIX-6996 :- Provide an upgrade path for Phoenix tables with HBase TTL to move the… #1752
Conversation
…ir TTL spec to SYSTEM.CATALOG
@lokiore - what happens if I don't want to upgrade HBase TTLs to Phoenix TTLs at upgrade time, but I want to do it later? |
@gjacoby126 No I added this only at upgrade time but after upgrade phoenix.table.ttl.enabled if set true will expect that TTL defined in SYSCAT is the TTL to follow, won't that break functionality if we don't do this at upgrade time!? I was expecting to know at upgrade time if we want older tables to follow new TTL mechanism or not. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, one nit. Will do one more pass and some local testing.
@@ -360,6 +360,7 @@ public interface QueryServices extends SQLCloseable { | |||
public static final String PHOENIX_SERVER_PAGE_SIZE_MS = "phoenix.server.page.size.ms"; | |||
// Phoenix TTL implemented by CompactionScanner and TTLRegionScanner is enabled | |||
public static final String PHOENIX_TABLE_TTL_ENABLED = "phoenix.table.ttl.enabled"; | |||
public static final String PHOENIX_TABLE_TTL_ENABLED_FOR_UPGRADE = "phoenix.table.ttl.enabled.upgrade"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Should it be called PHOENIX_TABLE_TTL_ENABLED_IN_SYSCAT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple of nits. LGTM +1
ReadOnlyProps readOnlyProps = oldMetaConnection.getQueryServices().getProps(); | ||
TableName sysCat = SchemaUtil.getPhysicalTableName(SYSTEM_CATALOG_NAME, readOnlyProps); | ||
|
||
LOGGER.debug(String.format("SYSTEM CATALOG tabled use for copying TTL values: %s", sysCat.toString())); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: typo "table used'?
@@ -368,6 +368,8 @@ public SQLException newException(SQLExceptionInfo info) { | |||
|
|||
TTL_ALREADY_DEFINED_IN_HIERARCHY(10958, "44A40", TTL | |||
+ " property is already defined in hierarchy for this entity"), | |||
VIEW_TTL_NOT_ENABLED(10959,"44A41", TTL + | |||
" property can not be set on Views as phoenix.view.ttl.enabled is false"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: typo should be lowercase "views"
… TTL to move the… (apache#1752) * Provide an upgrade path for Phoenix tables with HBase TTL to move their TTL spec to SYSTEM.CATALOG * Adding a config to enable/disable ViewTTL feature
… TTL to move the… (apache#1752) * Provide an upgrade path for Phoenix tables with HBase TTL to move their TTL spec to SYSTEM.CATALOG * Adding a config to enable/disable ViewTTL feature
… TTL to move the… (apache#1752) * Provide an upgrade path for Phoenix tables with HBase TTL to move their TTL spec to SYSTEM.CATALOG * Adding a config to enable/disable ViewTTL feature
* PHOENIX-6979 Use HBase TTL as TTL for Tables only at Phoenix Level when phoenix.table.ttl.enabled is true (#1622) * PHOENIX-6979 (Addendum) Use HBase TTL as TTL for Tables only at Phoenix Level when phoenix.table.ttl.enabled is true (#1670) * PHOENIX-7022 :- Add new columns TTL and ROW_KEY_PREFIX (#1660) * PHOENIX-7022 :- Add TTL and ROWKEY_PREFIX Column and Use TTL instead of PHOENIX_TTL for storing TTL in SYSCAT Co-authored-by: Lokesh Khurana <lokesh.khurana@salesforce.com> * PHOENIX-7023 : Deprecate columns PHOENIX_TTL and PHOENIX_TTL_HWM and related code (#1688) * Deprecate columns PHOENIX_TTL and PHOENIX_TTL_HWM and related code Co-authored-by: Lokesh Khurana <lokesh.khurana@salesforce.com> * PHOENIX-7041 Populate ROW_KEY_PREFIX column when creating views (#1733) PHOENIX-7041 Populate ROW_KEY_PREFIX column when creating views --------- Co-authored-by: Jacob Isaac <jisaac@salesforce.com> * PHOENIX-7040 : Support TTL for views using the new column TTL in SYSTEM.CATALOG (#1710) PHOENIX-7040 Support TTL for views using the new column TTL in SYSTEM.CATALOG --------- Co-authored-by: Lokesh Khurana <lokesh.khurana@salesforce.com> * PHOENIX-7041 (ADDENDUM ): Populate ROW_KEY_PREFIX column when creating views (#1821) * Refactored ROW_KEY_PREFIX column name to ROW_KEY_MATCHER * PHOENIX-7040 (ADDENDUM): Support TTL for views using the new column TTL in SYSTEM.CATALOG (#1782) Co-authored-by: lokesh-khurana <lokesh.khurana@salesforce.com> * PHOENIX-6996 :- Provide an upgrade path for Phoenix tables with HBase TTL to move the… (#1752) * Provide an upgrade path for Phoenix tables with HBase TTL to move their TTL spec to SYSTEM.CATALOG * Adding a config to enable/disable ViewTTL feature * PHOENIX-7041 (ADDENDUM-2): ROW_KEY_MATCHER should support various tenantId data types (#1900) * PHOENIX-7329 Change TTL column type to VARCHAR in syscat (#1905) PHOENIX-7329 Changing syscat column to type VARCHAR Co-authored-by: Tanuj Khurana <tkhurana@apache.org> * PHOENIX-7108 Provide support for pruning expired rows of views using Phoenix level compactions (#1908) --------- Co-authored-by: Lokesh Khurana <khuranalokesh07@gmail.com> Co-authored-by: Lokesh Khurana <lokesh.khurana@salesforce.com> Co-authored-by: Jacob Isaac <jisaac@salesforce.com> Co-authored-by: tkhurana <khurana.tanuj@gmail.com>
…ir TTL spec to SYSTEM.CATALOG