[
https://issues.apache.org/jira/browse/HDFS-16713?focusedWorklogId=797285&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-797285
]
ASF GitHub Bot logged work on HDFS-16713:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 02/Aug/22 15:54
Start Date: 02/Aug/22 15:54
Worklog Time Spent: 10m
Work Description: ZanderXu commented on PR #4674:
URL: https://github.com/apache/hadoop/pull/4674#issuecomment-1202887668
@goiri @slfan1989 Sir, this pr is used to improve code with Lambada in
org.apache.hadoop.hdfs.server.namenode sub packages. Please help me review,
thanks.
Issue Time Tracking
-------------------
Worklog Id: (was: 797285)
Time Spent: 20m (was: 10m)
> Improve Code with Lambda in org.apahce.hadoop.hdfs.server.namenode sub
> packages
> -------------------------------------------------------------------------------
>
> Key: HDFS-16713
> URL: https://issues.apache.org/jira/browse/HDFS-16713
> Project: Hadoop HDFS
> Issue Type: Improvement
> Reporter: ZanderXu
> Assignee: ZanderXu
> Priority: Major
> Labels: pull-request-available
> Time Spent: 20m
> Remaining Estimate: 0h
>
> Improve Code with Lambda in org.apahce.hadoop.hdfs.server.namenode sub
> packages.
> For example:
> Current logic:
> {code:java}
> public ListenableFuture<GetJournaledEditsResponseProto> getJournaledEdits(
> long fromTxnId, int maxTransactions) {
> return parallelExecutor.submit(
> new Callable<GetJournaledEditsResponseProto>() {
> @Override
> public GetJournaledEditsResponseProto call() throws IOException {
> return getProxy().getJournaledEdits(journalId, nameServiceId,
> fromTxnId, maxTransactions);
> }
> });
> } {code}
> Improved Code with Lambda:
> {code:java}
> public ListenableFuture<GetJournaledEditsResponseProto> getJournaledEdits(
> long fromTxnId, int maxTransactions) {
> return parallelExecutor.submit(() -> getProxy().getJournaledEdits(
> journalId, nameServiceId, fromTxnId, maxTransactions));
> } {code}
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]