[ https://issues.apache.org/jira/browse/HBASE-14998?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16164052#comment-16164052 ]
stack commented on HBASE-14998: ------------------------------- .001 incorporates 14998.txt but is based on a patch I got from [~balazs.meszaros]; he did all the work. His patch was more ambitious doing AsyncAdmin fixup and making Admin and AsyncAdmin match. I pulled out the Admin stuff only. I want to get this committed so can push an alpha-3. The AsyncAdmin mirroring can come in in a follow-up. Here is what is in .001... It has [~enis] stuff above on top of the [~balazs.meszaros]. HBASE-14998 Unify synchronous and asynchronous methods in Admin and cleanup This is based on patch sent me by Balazs Meszaros. The good stuff in here is from him. This patch does less than his ambition. It changes Admin class only. Can work on making AsyncAdmin cohere in a follow-on. * Deprecates getAlterStatus. Everywhere else we talk of 'modify' rather 'alter' and should use Future returned from async instead. * isTableAvailable(TableName, byte [][]) has been deprecated to be removed; use the overrie instead. This is a weird method. * Changed listTableDescriptor to getDescriptor. * Renamed other like methods to have same pattern (deprecating the old): balancer => balance setBalancerRunning => balancerSwitch setNormalizerRunning => normalizerSwitch enableCatalogJanitor => catalogJanitorSwitch setCleanerChoreRunning => cleanerChoreSwitch setSplitOrMergeEnabled => splitOrMergeEnabledSwitch * Renamed (with deprecation of old) runCatalogScan => runCatalogJanitor. * Reviewed generated javadoc and made some edits; purged reference to hbase issues from our API, fixed param names, etc. * Made all the enable services methods have same pattern. * Renamed takeSnapshotAsync as snapshotAsync (with deprecation of old) * Renamed execProcedureWithRet as execProcedureWithReturn (with deprecation) Can I get a review here since this is user-facing API, the probably final word for hbase2? Thanks. > Unify synchronous and asynchronous methods in Admin and cleanup > --------------------------------------------------------------- > > Key: HBASE-14998 > URL: https://issues.apache.org/jira/browse/HBASE-14998 > Project: HBase > Issue Type: Sub-task > Reporter: Enis Soztutar > Assignee: Balazs Meszaros > Priority: Blocker > Fix For: 2.0.0-alpha-3 > > Attachments: 14998.txt, HBASE-14998.master.001.patch > > > Admin has a bunch of methods, some are asnyc, some are sync. Needs some > unification in method naming, and method signatures. > - We use modify and alter interchangeably. Pick one and stick with it > (modifyTable(), versus getAlterStatus()). Shell uses {{alter}}. > - Remove getAlterStatus(), should not be needed. > - remove already deprecated methods > - isTableAvailable(TableName tableName, byte[][] splitKeys) should be > removed. > - Consistently use Aysnc as a prefix for all async methods. > - Other ideas? -- This message was sent by Atlassian JIRA (v6.4.14#64029)