ouyangshourui commented on pull request #1991:
URL: https://github.com/apache/hbase/pull/1991#issuecomment-650670742


   unsubscribe
   
   
   
   
   Best Regards 
   
   Ricky Yang
   
   
   
   
   
   
   
   
    
   
   
   
   
   ------------------ 原始邮件 ------------------
   发件人:&nbsp;"Toshihiro Suzuki"<[email protected]&gt;;
   发送时间:&nbsp;2020年6月28日(星期天) 上午10:01
   收件人:&nbsp;"apache/hbase"<[email protected]&gt;;
   抄送:&nbsp;"Subscribed"<[email protected]&gt;;
   主题:&nbsp;Re: [apache/hbase] HBASE-24650 Change the return types of the new 
CheckAndMutate methods… (#1991)
   
   
   
   
   
    
   @brfrn169 commented on this pull request.
    
   Thank you for taking a look at this!
    
   Yes, the old checkAndXXX methods are not effected. I'm going to add 
Increment/Append support to CheckAndMutate only for the new checkAndMutate 
methods.
   
    
   In 
hbase-client/src/main/java/org/apache/hadoop/hbase/client/CheckAndMutateResult.java:
    &gt; + * Unless required by applicable law or agreed to in writing, 
software + * distributed under the License is distributed on an "AS IS" BASIS, 
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + 
* See the License for the specific language governing permissions and + * 
limitations under the License. + */ +package org.apache.hadoop.hbase.client; + 
+import org.apache.yetus.audience.InterfaceAudience; +import 
org.apache.yetus.audience.InterfaceStability; + +/** + * Represents a result of 
a CheckAndMutate operation + */ [email protected] 
[email protected]  
   Okay. I will remove the IS annotation. Thanks.
    
    
   In 
hbase-client/src/main/java/org/apache/hadoop/hbase/client/RawAsyncTableImpl.java:
    &gt; @@ -349,7 +349,7 @@ private void preCheck() {            loc, stub, 
mutation,            (rn, rm) -&gt; RequestConverter.buildMutateRequest(rn, 
row, family, qualifier, op, value,              null, timeRange, rm), -         
 resp -&gt; resp.getExists())) +          resp -&gt; ((CheckAndMutateResult) 
resp).isSuccess()))  
   I will modify it to make use of generic type. Thanks.
    
    
   In 
hbase-client/src/main/java/org/apache/hadoop/hbase/client/RawAsyncTableImpl.java:
    &gt;    }      // We need the MultiRequest when constructing the 
org.apache.hadoop.hbase.client.MultiResponse,    // so here I write a new 
method as I do not want to change the abstraction of call method.    private 
<RESP&gt; CompletableFuture<RESP&gt; mutateRow(HBaseRpcController controller,   
     HRegionLocation loc, ClientService.Interface stub, RowMutations mutation,  
      Converter<MultiRequest, byte[], RowMutations&gt; reqConvert, -      
Function<Result, RESP&gt; respConverter) { +      Function<Object, RESP&gt; 
respConverter) {  
   The reason why I changed Result to Object here is that this method is used 
by both checkAndMutate() and mutateRow() and we need to use different types 
each case (respectively CheckAndMutateResult and Result). However as you 
mentioned, we can make use of generic type here. I will modify it. Thanks.
    
   —
   You are receiving this because you are subscribed to this thread.
   Reply to this email directly, view it on GitHub, or unsubscribe.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to