Skip to content

Commit c1ec826

Browse files
authored
IGNITE-28308 Remove Serializable from discovery custom messages (#13001)
1 parent 887955c commit c1ec826

File tree

51 files changed

+54
-249
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+54
-249
lines changed

modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/SecurityAwareCustomMessageWrapper.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,6 @@
3030

3131
/** Custom message wrapper with ID of security subject that initiated the current message. */
3232
public class SecurityAwareCustomMessageWrapper implements DiscoverySpiCustomMessage, MarshallableMessage {
33-
/** */
34-
private static final long serialVersionUID = 0L;
35-
3633
/** Security subject ID. */
3734
@Order(0)
3835
UUID secSubjId;
@@ -93,7 +90,6 @@ public DiscoveryCustomMessage delegate() {
9390
return ack == null ? null : new SecurityAwareCustomMessageWrapper(ack, secSubjId);
9491
}
9592

96-
9793
/** {@inheritDoc} */
9894
@Override public void prepareMarshal(Marshaller marsh) throws IgniteCheckedException {
9995
if (!(delegate instanceof Message))

modules/core/src/main/java/org/apache/ignite/internal/processors/authentication/UserAcceptedMessage.java

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,13 @@
2323
import org.apache.ignite.internal.util.tostring.GridToStringInclude;
2424
import org.apache.ignite.internal.util.typedef.internal.S;
2525
import org.apache.ignite.lang.IgniteUuid;
26-
import org.apache.ignite.plugin.extensions.communication.Message;
2726
import org.jetbrains.annotations.Nullable;
2827

2928
/**
3029
* Is sent as an acknowledgement for end (with success or error) of user management operation on the cluster
3130
* (see {@link UserProposedMessage} and {@link UserManagementOperation}).
3231
*/
33-
public class UserAcceptedMessage implements DiscoveryCustomMessage, Message {
34-
/** */
35-
private static final long serialVersionUID = 0L;
36-
32+
public class UserAcceptedMessage implements DiscoveryCustomMessage {
3733
/** */
3834
@Order(0)
3935
IgniteUuid id;
@@ -95,5 +91,4 @@ Throwable error() {
9591
@Override public String toString() {
9692
return S.toString(UserAcceptedMessage.class, this);
9793
}
98-
9994
}

modules/core/src/main/java/org/apache/ignite/internal/processors/authentication/UserProposedMessage.java

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@
2323
import org.apache.ignite.internal.util.tostring.GridToStringInclude;
2424
import org.apache.ignite.internal.util.typedef.internal.S;
2525
import org.apache.ignite.lang.IgniteUuid;
26-
import org.apache.ignite.plugin.extensions.communication.Message;
2726
import org.jetbrains.annotations.Nullable;
2827

2928
/**
@@ -33,10 +32,7 @@
3332
* <p>
3433
* {@link UserAcceptedMessage} is sent as an acknowledgement that operation is finished on the all nodes of the cluster.
3534
*/
36-
public class UserProposedMessage implements DiscoveryServerOnlyCustomMessage, Message {
37-
/** */
38-
private static final long serialVersionUID = 0L;
39-
35+
public class UserProposedMessage implements DiscoveryServerOnlyCustomMessage {
4036
/** */
4137
@Order(0)
4238
IgniteUuid id;
@@ -84,5 +80,4 @@ UserManagementOperation operation() {
8480
@Override public String toString() {
8581
return S.toString(UserProposedMessage.class, this);
8682
}
87-
8883
}

modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinityChangeMessage.java

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,18 +29,14 @@
2929
import org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionsFullMessage;
3030
import org.apache.ignite.internal.util.typedef.internal.S;
3131
import org.apache.ignite.lang.IgniteUuid;
32-
import org.apache.ignite.plugin.extensions.communication.Message;
3332
import org.apache.ignite.spi.discovery.DiscoverySpiMutableCustomMessageSupport;
3433
import org.jetbrains.annotations.Nullable;
3534

3635
/**
3736
* CacheAffinityChangeMessage represent a message that switches to a new affinity assignmentafter rebalance is finished.
3837
* This message should not be mutated in any way outside the "disco-notifier-worker" thread.
3938
*/
40-
public class CacheAffinityChangeMessage implements DiscoveryCustomMessage, Message {
41-
/** */
42-
private static final long serialVersionUID = 0L;
43-
39+
public class CacheAffinityChangeMessage implements DiscoveryCustomMessage {
4440
/** */
4541
@Order(0)
4642
IgniteUuid id;

modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheStatisticsClearMessage.java

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,12 @@
2323
import org.apache.ignite.internal.managers.discovery.DiscoveryCustomMessage;
2424
import org.apache.ignite.internal.util.typedef.internal.S;
2525
import org.apache.ignite.lang.IgniteUuid;
26-
import org.apache.ignite.plugin.extensions.communication.Message;
2726
import org.jetbrains.annotations.Nullable;
2827

2928
/**
3029
* Cache statistics clear discovery message.
3130
*/
32-
public class CacheStatisticsClearMessage implements DiscoveryCustomMessage, Message {
33-
/** */
34-
private static final long serialVersionUID = 0L;
35-
31+
public class CacheStatisticsClearMessage implements DiscoveryCustomMessage {
3632
/** Initial message flag mask. */
3733
private static final byte INITIAL_MSG_MASK = 0x01;
3834

modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheStatisticsModeChangeMessage.java

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,17 +24,13 @@
2424
import org.apache.ignite.internal.managers.discovery.DiscoveryCustomMessage;
2525
import org.apache.ignite.internal.util.typedef.internal.S;
2626
import org.apache.ignite.lang.IgniteUuid;
27-
import org.apache.ignite.plugin.extensions.communication.Message;
2827
import org.apache.ignite.plugin.extensions.communication.MessageFactory;
2928
import org.jetbrains.annotations.Nullable;
3029

3130
/**
3231
* Cache statistics mode change discovery message.
3332
*/
34-
public class CacheStatisticsModeChangeMessage implements DiscoveryCustomMessage, Message {
35-
/** */
36-
private static final long serialVersionUID = 0L;
37-
33+
public class CacheStatisticsModeChangeMessage implements DiscoveryCustomMessage {
3834
/** Initial message flag mask. */
3935
private static final byte INITIAL_MSG_MASK = 0x01;
4036

@@ -140,5 +136,4 @@ public UUID requestId() {
140136
@Override public String toString() {
141137
return S.toString(CacheStatisticsModeChangeMessage.class, this);
142138
}
143-
144139
}

modules/core/src/main/java/org/apache/ignite/internal/processors/cache/ClientCacheChangeDiscoveryMessage.java

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,16 +28,12 @@
2828
import org.apache.ignite.internal.util.typedef.F;
2929
import org.apache.ignite.internal.util.typedef.internal.S;
3030
import org.apache.ignite.lang.IgniteUuid;
31-
import org.apache.ignite.plugin.extensions.communication.Message;
3231
import org.jetbrains.annotations.Nullable;
3332

3433
/**
3534
* Sent from cache client node to asynchronously notify about started.closed client caches.
3635
*/
37-
public class ClientCacheChangeDiscoveryMessage implements DiscoveryCustomMessage, Message {
38-
/** */
39-
private static final long serialVersionUID = 0L;
40-
36+
public class ClientCacheChangeDiscoveryMessage implements DiscoveryCustomMessage {
4137
/** */
4238
@Order(0)
4339
IgniteUuid id;
@@ -173,7 +169,6 @@ public void updateTimeoutObject(ClientCacheUpdateTimeout updateTimeoutObj) {
173169
return null;
174170
}
175171

176-
177172
/** {@inheritDoc} */
178173
@Override public String toString() {
179174
return S.toString(ClientCacheChangeDiscoveryMessage.class, this);

modules/core/src/main/java/org/apache/ignite/internal/processors/cache/ClientCacheChangeDummyDiscoveryMessage.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,6 @@
3737
*/
3838
public class ClientCacheChangeDummyDiscoveryMessage extends AbstractCachePartitionExchangeWorkerTask
3939
implements DiscoveryCustomMessage, MarshallableMessage {
40-
/** */
41-
private static final long serialVersionUID = 0L;
42-
4340
/** */
4441
@Order(0)
4542
UUID reqId;
@@ -131,7 +128,6 @@ Set<String> cachesToClose() {
131128
startReqs = U.unmarshal(marsh, startRequestsBytes, clsLdr);
132129
}
133130

134-
135131
/** {@inheritDoc} */
136132
@Override public String toString() {
137133
return S.toString(ClientCacheChangeDummyDiscoveryMessage.class, this,

modules/core/src/main/java/org/apache/ignite/internal/processors/cache/DynamicCacheChangeBatch.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,6 @@
4040
* Cache change batch.
4141
*/
4242
public class DynamicCacheChangeBatch implements DiscoveryCustomMessage, MarshallableMessage {
43-
/** */
44-
private static final long serialVersionUID = 0L;
45-
4643
/** Discovery custom message ID. */
4744
@Order(0)
4845
IgniteUuid id;
@@ -187,7 +184,6 @@ public void startCaches(boolean startCaches) {
187184
reqs = U.unmarshal(marsh, requestsBytes, clsLdr);
188185
}
189186

190-
191187
/** {@inheritDoc} */
192188
@Override public String toString() {
193189
return S.toString(DynamicCacheChangeBatch.class, this);

modules/core/src/main/java/org/apache/ignite/internal/processors/cache/ExchangeFailureMessage.java

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,17 +36,13 @@
3636
import org.apache.ignite.internal.util.typedef.internal.S;
3737
import org.apache.ignite.internal.util.typedef.internal.U;
3838
import org.apache.ignite.lang.IgniteUuid;
39-
import org.apache.ignite.plugin.extensions.communication.Message;
4039
import org.apache.ignite.plugin.extensions.communication.MessageFactory;
4140
import org.jetbrains.annotations.Nullable;
4241

4342
/**
4443
* This class represents discovery message that is used to provide information about dynamic cache start failure.
4544
*/
46-
public class ExchangeFailureMessage implements DiscoveryCustomMessage, Message {
47-
/** */
48-
private static final long serialVersionUID = 0L;
49-
45+
public class ExchangeFailureMessage implements DiscoveryCustomMessage {
5046
/** Cache names. */
5147
@GridToStringInclude
5248
@Order(0)
@@ -66,7 +62,7 @@ public class ExchangeFailureMessage implements DiscoveryCustomMessage, Message {
6662
Map<UUID, ErrorMessage> exchangeErrors;
6763

6864
/** Actions to be done to rollback changes done before the exchange failure. */
69-
private transient ExchangeActions exchangeRollbackActions;
65+
private ExchangeActions exchangeRollbackActions;
7066

7167
/** Default constructor for {@link MessageFactory}. */
7268
public ExchangeFailureMessage() {

0 commit comments

Comments
 (0)