[ 
https://issues.apache.org/jira/browse/IGNITE-18997?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Aleksandr Polovtcev updated IGNITE-18997:
-----------------------------------------
    Description: 
PartitionReplicaListener has a following pattern in its code:

{code:java}
 if (request instanceof ReplicaSafeTimeSyncRequest) {
     return processReplicaSafeTimeSyncRequest((ReplicaSafeTimeSyncRequest) 
request)
         .thenApply(Function.identity());
{code}

This {{thenApply(Function.identity())}} is only needed for code being able to 
compile. This makes little sense, as we can simply use generic wildcards and 
remove these transfomations.


  was:
PartitionReplicaListener has a following pattern in its code:

{code:java}
 if (request instanceof ReplicaSafeTimeSyncRequest) {
     return processReplicaSafeTimeSyncRequest((ReplicaSafeTimeSyncRequest) 
request)
                                .thenApply(Function.identity());
{code}

This {{thenApply(Function.identity())}} is only needed for code being able to 
compile. This makes little sense, as we can simply use generic wildcards and 
remove these transfomations.



> Remove redundant future transformations from PartitionReplicaListener
> ---------------------------------------------------------------------
>
>                 Key: IGNITE-18997
>                 URL: https://issues.apache.org/jira/browse/IGNITE-18997
>             Project: Ignite
>          Issue Type: Improvement
>            Reporter: Aleksandr Polovtcev
>            Assignee: Aleksandr Polovtcev
>            Priority: Trivial
>              Labels: ignite-3
>
> PartitionReplicaListener has a following pattern in its code:
> {code:java}
>  if (request instanceof ReplicaSafeTimeSyncRequest) {
>      return processReplicaSafeTimeSyncRequest((ReplicaSafeTimeSyncRequest) 
> request)
>          .thenApply(Function.identity());
> {code}
> This {{thenApply(Function.identity())}} is only needed for code being able to 
> compile. This makes little sense, as we can simply use generic wildcards and 
> remove these transfomations.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to