620c841dd42f5952040669d5c2c4a539e9156c37
Files Diff
- Added: 3
- Removed: 1
- Renamed: 0
- Modified: 11
Refactorings reported:
Refactoring Name | Occurences | ||
---|---|---|---|
Rename Method | 4 | ||
Rename Method public setClient(client int) : RegisterEntry renamed to public setMember(member int) : RegisterEntry in class net.kuujo.copycat.raft.log.RegisterEntry | From | To | |
Rename Method protected abstract heartbeat(request HeartbeatRequest) : CompletableFuture<HeartbeatResponse> renamed to protected abstract publish(request PublishRequest) : CompletableFuture<PublishResponse> in class net.kuujo.copycat.raft.state.AbstractState | From | To | |
Rename Method public getClient() : int renamed to public getMember() : int in class net.kuujo.copycat.raft.log.RegisterEntry | From | To | |
Rename Method protected heartbeat(request HeartbeatRequest) : CompletableFuture<HeartbeatResponse> renamed to protected publish(request PublishRequest) : CompletableFuture<PublishResponse> in class net.kuujo.copycat.raft.state.StartState | From | To | |
Push Down Method | 3 | ||
Push Down Method package setConnection(connection Connection) : ServerSession from class net.kuujo.copycat.raft.state.ServerSession to package setConnection(connection Connection) : ServerSession from class net.kuujo.copycat.raft.state.LocalServerSession | From | To | |
Push Down Method public publish(message Object) : CompletableFuture<Void> from class net.kuujo.copycat.raft.state.ServerSession to public publish(message Object) : CompletableFuture<Void> from class net.kuujo.copycat.raft.state.LocalServerSession | From | To | |
Push Down Method protected handlePublish(request PublishRequest) : CompletableFuture<PublishResponse> from class net.kuujo.copycat.raft.state.ServerSession to protected handlePublish(request PublishRequest) : CompletableFuture<PublishResponse> from class net.kuujo.copycat.raft.state.RemoteServerSession | From | To | |
Extract Subclass | 1 | ||
Extract Subclass net.kuujo.copycat.raft.state.LocalServerSession from class net.kuujo.copycat.raft.state.ServerSession | From | To | |
Change Parameter Type | 3 | ||
Change Parameter Type request : HeartbeatRequest to request : PublishRequest in method protected publish(request PublishRequest) : CompletableFuture<PublishResponse> in class net.kuujo.copycat.raft.state.StartState | From | To | |
Change Parameter Type memberId : int to sessionId : long in method private replicateCommits(sessionId long) : void in class net.kuujo.copycat.raft.state.FollowerState | From | To | |
Change Parameter Type request : HeartbeatRequest to request : PublishRequest in method protected abstract publish(request PublishRequest) : CompletableFuture<PublishResponse> in class net.kuujo.copycat.raft.state.AbstractState | From | To | |
Move Method | 1 | ||
Move Method public toString() : String from class net.kuujo.copycat.raft.log.HeartbeatEntry to public toString() : String from class net.kuujo.copycat.raft.log.RegisterEntry | From | To | |
Change Return Type | 2 | ||
Change Return Type CompletableFuture<HeartbeatResponse> to CompletableFuture<PublishResponse> in method protected abstract publish(request PublishRequest) : CompletableFuture<PublishResponse> in class net.kuujo.copycat.raft.state.AbstractState | From | To | |
Change Return Type CompletableFuture<HeartbeatResponse> to CompletableFuture<PublishResponse> in method protected publish(request PublishRequest) : CompletableFuture<PublishResponse> in class net.kuujo.copycat.raft.state.StartState | From | To | |
Push Down Attribute | 1 | ||
Push Down Attribute private connection : Connection from class net.kuujo.copycat.raft.state.ServerSession to private connection : Connection from class net.kuujo.copycat.raft.state.RemoteServerSession | From | To | |
Rename Attribute | 1 | ||
Rename Attribute client : int to member : int in class net.kuujo.copycat.raft.log.RegisterEntry | From | To | |
Change Attribute Type | 1 | ||
Change Attribute Type connections : Map<Integer,Connection> to connections : Map<UUID,Connection> in class net.kuujo.copycat.raft.state.SessionManager | From | To | |
Extract Method | 5 | ||
Extract Method public publish(message Object) : CompletableFuture<Void> extracted from public publish(message Object) : CompletableFuture<Void> in class net.kuujo.copycat.raft.state.LocalServerSession | From | To | |
Extract Method package unregisterSession(sessionId long) : SessionManager extracted from package unregisterSession(session ServerSession) : SessionManager in class net.kuujo.copycat.raft.state.SessionManager | From | To | |
Extract Method private expireSession(sessionId long) : void extracted from private query(index long, sessionId long, version long, timestamp long, query Query) : CompletableFuture<Object> in class net.kuujo.copycat.raft.state.RaftState | From | To | |
Extract Method private expireSession(sessionId long) : void extracted from private keepAlive(index long, timestamp long, sessionId long) : CompletableFuture<Void> in class net.kuujo.copycat.raft.state.RaftState | From | To | |
Extract Method private expireSession(sessionId long) : void extracted from private command(index long, sessionId long, request long, response long, timestamp long, command Command) : CompletableFuture<Object> in class net.kuujo.copycat.raft.state.RaftState | From | To | |
Rename Parameter | 3 | ||
Rename Parameter clientId : int to memberId : int in method private register(index long, memberId int, connectionId UUID, timestamp long) : CompletableFuture<Long> in class net.kuujo.copycat.raft.state.RaftState | From | To | |
Rename Parameter client : int to member : int in method public setMember(member int) : RegisterEntry in class net.kuujo.copycat.raft.log.RegisterEntry | From | To | |
Rename Parameter memberId : int to sessionId : long in method private replicateCommits(sessionId long) : void in class net.kuujo.copycat.raft.state.FollowerState | From | To |