Yet more Akka version numbers in deprecation warnings (#545)

* Yet more Akka version numbers in deprecation warnings

more

* more akka version numbers

Update ClusterMessageSerializer.scala

more changes
This commit is contained in:
PJ Fanning 2023-08-07 00:47:04 +01:00 committed by GitHub
parent 0e89e793aa
commit 4f570ea24c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
25 changed files with 72 additions and 168 deletions

View file

@ -144,9 +144,9 @@ pekko {
# CallingThreadDispatcher for a top-level actor.
unstarted-push-timeout = 10s
# TypedActor deprecated since 2.6.0.
# TypedActor deprecated since Akka 2.6.0.
typed {
# Default timeout for the deprecated TypedActor (not the new actor APIs in 2.6)
# Default timeout for the deprecated TypedActor (not the new actor APIs in Akka 2.6)
# methods with non-void return type.
timeout = 5s
}

View file

@ -153,7 +153,7 @@ private[pekko] class RepointableActorRef(
case _ => true
}
@deprecated("Use context.watch(actor) and receive Terminated(actor)", "2.2") def isTerminated: Boolean =
@deprecated("Use context.watch(actor) and receive Terminated(actor)", "Akka 2.2") def isTerminated: Boolean =
underlying.isTerminated
def provider: ActorRefProvider = system.provider

View file

@ -42,7 +42,7 @@ import pekko.util.Helpers
* @see org.apache.pekko.dispatch.BalancingDispatcher
* @see org.apache.pekko.dispatch.Dispatchers
*/
@deprecated("Use BalancingPool instead of BalancingDispatcher", "2.3")
@deprecated("Use BalancingPool instead of BalancingDispatcher", "Akka 2.3")
private[pekko] class BalancingDispatcher(
_configurator: MessageDispatcherConfigurator,
_id: String,

View file

@ -266,7 +266,7 @@ class Dispatchers @InternalApi private[pekko] (
cfg.getString("type") match {
case "Dispatcher" => new DispatcherConfigurator(cfg, prerequisites)
case "BalancingDispatcher" =>
// FIXME remove this case in 2.4
// FIXME remove this case in Akka 2.4
throw new IllegalArgumentException(
"BalancingDispatcher is deprecated, use a BalancingPool instead. " +
"During a migration period you can still use BalancingDispatcher by specifying the full class name: " +

View file

@ -227,7 +227,7 @@ object Futures {
* Internal use only.
*/
object japi {
@deprecated("Do not use this directly, use subclasses of this", "2.0")
@deprecated("Do not use this directly, use subclasses of this", "Akka 2.0")
class CallbackBridge[-T] extends AbstractPartialFunction[T, BoxedUnit] {
override final def isDefinedAt(t: T): Boolean = true
override final def apply(t: T): BoxedUnit = {
@ -237,20 +237,20 @@ object japi {
protected def internal(@unused result: T): Unit = ()
}
@deprecated("Do not use this directly, use 'Recover'", "2.0")
@deprecated("Do not use this directly, use 'Recover'", "Akka 2.0")
class RecoverBridge[+T] extends AbstractPartialFunction[Throwable, T] {
override final def isDefinedAt(t: Throwable): Boolean = true
override final def apply(t: Throwable): T = internal(t)
protected def internal(@unused result: Throwable): T = null.asInstanceOf[T]
}
@deprecated("Do not use this directly, use subclasses of this", "2.0")
@deprecated("Do not use this directly, use subclasses of this", "Akka 2.0")
class BooleanFunctionBridge[-T] extends scala.Function1[T, Boolean] {
override final def apply(t: T): Boolean = internal(t)
protected def internal(@unused result: T): Boolean = false
}
@deprecated("Do not use this directly, use subclasses of this", "2.0")
@deprecated("Do not use this directly, use subclasses of this", "Akka 2.0")
class UnitFunctionBridge[-T] extends (T => BoxedUnit) {
final def apply$mcLJ$sp(l: Long): BoxedUnit = { internal(l.asInstanceOf[T]); BoxedUnit.UNIT }
final def apply$mcLI$sp(i: Int): BoxedUnit = { internal(i.asInstanceOf[T]); BoxedUnit.UNIT }

View file

@ -169,7 +169,7 @@ private[pekko] class Mailboxes(
dispatcherConfig.hasPath("mailbox-type") &&
dispatcherConfig.getString("mailbox-type") != Deploy.NoMailboxGiven
// TODO remove in 2.3
// TODO remove in Akka 2.3
if (!hasMailboxType && !mailboxSizeWarningIssued && dispatcherConfig.hasPath("mailbox-size")) {
eventStream.publish(
Warning(

View file

@ -1222,7 +1222,7 @@ final class ClusterShardingSettings(
coordinatorSingletonSettings,
leaseSettings)
// bin compat for 2.5.23
// bin compat for Akka 2.5.23
@deprecated(
"Use the ClusterShardingSettings factory methods or the constructor including shardRegionQueryTimeout instead",
since = "Akka 2.6.0")
@ -1248,7 +1248,7 @@ final class ClusterShardingSettings(
coordinatorSingletonSettings,
leaseSettings)
// bin compat for 2.5.21
// bin compat for Akka 2.5.21
@deprecated(
"Use the ClusterShardingSettings factory methods or the constructor including shardRegionQueryTimeout instead",
since = "Akka 2.5.21")

View file

@ -62,7 +62,7 @@ final class ClusterSingletonSettings(
val bufferSize: Int,
val leaseSettings: Option[LeaseUsageSettings]) {
// bin compat for 2.6.14
// bin compat for Akka 2.6.14
@deprecated("Use constructor with leaseSettings", "Akka 2.6.15")
def this(
role: Option[String],
@ -303,7 +303,7 @@ final class ClusterSingletonManagerSettings(
val handOverRetryInterval: FiniteDuration,
val leaseSettings: Option[LeaseUsageSettings]) {
// bin compat for 2.6.14
// bin compat for Akka 2.6.14
@deprecated("Use constructor with leaseSettings", "Akka 2.6.15")
def this(
singletonName: String,

View file

@ -41,8 +41,8 @@ import pekko.util.ccompat.JavaConverters._
@InternalApi
@ccompatUsedUntil213
private[pekko] object ClusterMessageSerializer {
// Kept for one version iteration from 2.6.4 to allow rolling migration to short manifests
// can be removed in 2.6.6 or later.
// Kept for one version iteration from Akka 2.6.4 to allow rolling migration to short manifests
// can be removed in Akka 2.6.6 or later.
val OldJoinManifest = s"org.apache.pekko.cluster.InternalClusterAction$$Join"
val OldWelcomeManifest = s"org.apache.pekko.cluster.InternalClusterAction$$Welcome"
val OldLeaveManifest = s"org.apache.pekko.cluster.ClusterUserAction$$Leave"
@ -57,7 +57,7 @@ private[pekko] object ClusterMessageSerializer {
val OldGossipEnvelopeManifest = "org.apache.pekko.cluster.GossipEnvelope"
val OldClusterRouterPoolManifest = "org.apache.pekko.cluster.routing.ClusterRouterPool"
// is handled on the deserializing side in 2.6.2 and then on the serializing side in 2.6.3
// is handled on the deserializing side in Akka 2.6.2 and then on the serializing side in Akka 2.6.3
val JoinManifest = "J"
val WelcomeManifest = "W"
val LeaveManifest = "L"
@ -139,7 +139,7 @@ final class ClusterMessageSerializer(val system: ExtendedActorSystem)
case DownManifest => deserializeDown(bytes)
case ExitingConfirmedManifest => deserializeExitingConfirmed(bytes)
case ClusterRouterPoolManifest => deserializeClusterRouterPool(bytes)
// needs to stay in 2.6.5 to be able to talk to a 2.5.{3,4} node during rolling upgrade
// needs to stay in Akka 2.6.5 to be able to talk to an Akka 2.5.{3,4} node during rolling upgrade
case HeartBeatManifestPre2523 => deserializeHeartBeatAsAddress(bytes)
case HeartBeatRspManifest2523 => deserializeHeartBeatRspAsUniqueAddress(bytes)
case OldGossipStatusManifest => deserializeGossipStatus(bytes)
@ -417,7 +417,7 @@ final class ClusterMessageSerializer(val system: ExtendedActorSystem)
private def initJoinAckToByteArray(address: Address, configCheck: ConfigCheck): Array[Byte] = {
if (configCheck == ConfigCheckUnsupportedByJoiningNode)
addressToProtoByteArray(address) // plain Address in 2.5.9 or earlier
addressToProtoByteArray(address) // plain Address in Akka 2.5.9 or earlier
else
initJoinAckToProto(address, configCheck).toByteArray
}

View file

@ -131,8 +131,8 @@ class ClusterMessageSerializerSpec extends PekkoSpec("pekko.actor.provider = clu
checkSerialization(InternalClusterAction.Welcome(uniqueAddress, g2))
}
// can be removed in 2.6.3 only checks deserialization with new not yet in effect manifests for 2.6.2
"be de-serializable with class manifests from 2.6.4 and earlier nodes" in {
// can be removed in Akka 2.6.3 only checks deserialization with new not yet in effect manifests for Akka 2.6.2
"be de-serializable with class manifests from Akka 2.6.4 and earlier nodes" in {
val address = Address("pekko", "system", "some.host.org", 4711)
val uniqueAddress = UniqueAddress(address, 17L)
val address2 = Address("pekko", "system", "other.host.org", 4711)
@ -189,11 +189,11 @@ class ClusterMessageSerializerSpec extends PekkoSpec("pekko.actor.provider = clu
}
}
// support for deserializing a new format with a string based manifest was added in 2.5.23 but the next step
// support for deserializing a new format with a string based manifest was added in Akka 2.5.23 but the next step
// was never done, meaning that 2.6.4 still emits the old format
"Rolling upgrades for heart beat message changes in 2.5.23" must {
"Rolling upgrades for heart beat message changes in Akka 2.5.23" must {
"deserialize heart beats represented by just an address Address to support versions prior or 2.6.5" in {
"deserialize heart beats represented by just an address Address to support versions prior to Akka 2.6.5" in {
val serialized = serializer.addressToProto(a1.address).build().toByteArray
val deserialized = serializer.fromBinary(serialized, ClusterMessageSerializer.HeartBeatManifestPre2523)
deserialized should ===(ClusterHeartbeatSender.Heartbeat(a1.address, -1, -1))

View file

@ -76,7 +76,7 @@ public final class MessageFormats {
/**
* <pre>
* not used in new records from 2.4
* not used in new records from Akka 2.4
* </pre>
*
* <code>optional bool deleted = 4;</code>
@ -85,7 +85,7 @@ public final class MessageFormats {
boolean hasDeleted();
/**
* <pre>
* not used in new records from 2.4
* not used in new records from Akka 2.4
* </pre>
*
* <code>optional bool deleted = 4;</code>
@ -94,40 +94,16 @@ public final class MessageFormats {
boolean getDeleted();
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return Whether the sender field is set.
*/
boolean hasSender();
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return The sender.
*/
java.lang.String getSender();
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return The bytes for sender.
*/
@ -431,7 +407,7 @@ public final class MessageFormats {
private boolean deleted_;
/**
* <pre>
* not used in new records from 2.4
* not used in new records from Akka 2.4
* </pre>
*
* <code>optional bool deleted = 4;</code>
@ -442,7 +418,7 @@ public final class MessageFormats {
}
/**
* <pre>
* not used in new records from 2.4
* not used in new records from Akka 2.4
* </pre>
*
* <code>optional bool deleted = 4;</code>
@ -455,14 +431,6 @@ public final class MessageFormats {
public static final int SENDER_FIELD_NUMBER = 11;
private volatile java.lang.Object sender_;
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return Whether the sender field is set.
*/
@ -470,14 +438,6 @@ public final class MessageFormats {
return ((bitField0_ & 0x00000010) != 0);
}
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return The sender.
*/
@ -496,14 +456,6 @@ public final class MessageFormats {
}
}
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return The bytes for sender.
*/
@ -1456,7 +1408,7 @@ public final class MessageFormats {
private boolean deleted_ ;
/**
* <pre>
* not used in new records from 2.4
* not used in new records from Akka 2.4
* </pre>
*
* <code>optional bool deleted = 4;</code>
@ -1467,7 +1419,7 @@ public final class MessageFormats {
}
/**
* <pre>
* not used in new records from 2.4
* not used in new records from Akka 2.4
* </pre>
*
* <code>optional bool deleted = 4;</code>
@ -1478,7 +1430,7 @@ public final class MessageFormats {
}
/**
* <pre>
* not used in new records from 2.4
* not used in new records from Akka 2.4
* </pre>
*
* <code>optional bool deleted = 4;</code>
@ -1493,7 +1445,7 @@ public final class MessageFormats {
}
/**
* <pre>
* not used in new records from 2.4
* not used in new records from Akka 2.4
* </pre>
*
* <code>optional bool deleted = 4;</code>
@ -1508,14 +1460,6 @@ public final class MessageFormats {
private java.lang.Object sender_ = "";
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return Whether the sender field is set.
*/
@ -1523,14 +1467,6 @@ public final class MessageFormats {
return ((bitField0_ & 0x00000010) != 0);
}
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return The sender.
*/
@ -1549,14 +1485,6 @@ public final class MessageFormats {
}
}
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return The bytes for sender.
*/
@ -1574,14 +1502,6 @@ public final class MessageFormats {
}
}
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @param value The sender to set.
* @return This builder for chaining.
@ -1597,14 +1517,6 @@ public final class MessageFormats {
return this;
}
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @return This builder for chaining.
*/
@ -1615,14 +1527,6 @@ public final class MessageFormats {
return this;
}
/**
* <pre>
* optional int32 redeliveries = 6; // Removed in 2.4
* repeated string confirms = 7; // Removed in 2.4
* optional bool confirmable = 8; // Removed in 2.4
* optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
* optional string confirmTarget = 10; // Removed in 2.4
* </pre>
*
* <code>optional string sender = 11;</code>
* @param value The bytes for sender to set.
* @return This builder for chaining.
@ -5405,7 +5309,7 @@ public final class MessageFormats {
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -5414,7 +5318,7 @@ public final class MessageFormats {
boolean hasTimeout();
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -5423,7 +5327,7 @@ public final class MessageFormats {
java.lang.String getTimeout();
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -5590,7 +5494,7 @@ public final class MessageFormats {
private volatile java.lang.Object timeout_;
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -5601,7 +5505,7 @@ public final class MessageFormats {
}
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -5623,7 +5527,7 @@ public final class MessageFormats {
}
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -6121,7 +6025,7 @@ public final class MessageFormats {
private java.lang.Object timeout_ = "";
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -6132,7 +6036,7 @@ public final class MessageFormats {
}
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -6154,7 +6058,7 @@ public final class MessageFormats {
}
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -6175,7 +6079,7 @@ public final class MessageFormats {
}
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -6194,7 +6098,7 @@ public final class MessageFormats {
}
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>
@ -6208,7 +6112,7 @@ public final class MessageFormats {
}
/**
* <pre>
*not used in new records from 2.4.5
*not used in new records from Akka 2.4.5
* </pre>
*
* <code>optional string timeout = 2;</code>

View file

@ -20,12 +20,12 @@ message PersistentMessage {
optional PersistentPayload payload = 1;
optional int64 sequenceNr = 2;
optional string persistenceId = 3;
optional bool deleted = 4; // not used in new records from 2.4
// optional int32 redeliveries = 6; // Removed in 2.4
// repeated string confirms = 7; // Removed in 2.4
// optional bool confirmable = 8; // Removed in 2.4
// optional DeliveredMessage confirmMessage = 9; // Removed in 2.4
// optional string confirmTarget = 10; // Removed in 2.4
optional bool deleted = 4; // not used in new records from Akka 2.4
// optional int32 redeliveries = 6; // Removed in Akka 2.4
// repeated string confirms = 7; // Removed in Akka 2.4
// optional bool confirmable = 8; // Removed in Akka 2.4
// optional DeliveredMessage confirmMessage = 9; // Removed in Akka 2.4
// optional string confirmTarget = 10; // Removed in Akka 2.4
optional string sender = 11; // not stored in journal, needed for remote serialization
optional string manifest = 12;
optional string writerUuid = 13;
@ -56,7 +56,7 @@ message AtLeastOnceDeliverySnapshot {
message PersistentStateChangeEvent {
required string stateIdentifier = 1;
optional string timeout = 2; //not used in new records from 2.4.5
optional string timeout = 2; //not used in new records from Akka 2.4.5
optional int64 timeoutNanos = 3;
}

View file

@ -392,7 +392,7 @@ trait PersistentFSMBase[S, D, E] extends Actor with Listeners with ActorLogging
*
* @see [[pekko.persistence.fsm.PersistentFSM#receiveRecover]]
*/
@deprecated("Removed from API, called internally", "2.4.5")
@deprecated("Removed from API, called internally", "Akka 2.4.5")
private[pekko] final def initialize(): Unit =
if (currentState != null) makeTransition(currentState)
else throw new IllegalStateException("You must call `startWith` before calling `initialize`")

View file

@ -174,7 +174,7 @@ trait AsyncWriteJournal extends Actor with WriteJournalBase with AsyncRecovery {
// to resequence replayed messages relative to written and looped messages.
// not possible to use circuit breaker here
asyncReplayMessages(persistenceId, fromSequenceNr, toSeqNr, max) { p =>
if (!p.deleted) // old records from 2.3 may still have the deleted flag
if (!p.deleted) // old records from Akka 2.3 may still have the deleted flag
adaptFromJournal(p).foreach { adaptedPersistentRepr =>
replyTo.tell(ReplayedMessage(adaptedPersistentRepr), Actor.noSender)
}

View file

@ -82,7 +82,7 @@ class SharedLeveldbStore(cfg: Config) extends LeveldbStore {
else {
val toSeqNr = math.min(toSequenceNr, highSeqNr)
asyncReplayMessages(persistenceId, fromSequenceNr, toSeqNr, max) { p =>
if (!p.deleted) // old records from 2.3 may still have the deleted flag
if (!p.deleted) // old records from Akka 2.3 may still have the deleted flag
adaptFromJournal(p).foreach(replyTo ! _)
}.map(_ => highSeqNr)
}

View file

@ -181,7 +181,7 @@ class MessageSerializer(val system: ExtendedActorSystem) extends BaseSerializer
}
builder.setSequenceNr(persistent.sequenceNr)
// deleted is not used in new records from 2.4
// deleted is not used in new records from Akka 2.4
if (persistent.writerUuid != Undefined) builder.setWriterUuid(persistent.writerUuid)
if (persistent.timestamp > 0L) builder.setTimestamp(persistent.timestamp)
builder

View file

@ -57,6 +57,6 @@ class AddressUidExtension(val system: ExtendedActorSystem) extends Extension {
}
// used by old remoting and part of public api
@deprecated("Use longAddressUid instead", "2.4.x")
@deprecated("Use longAddressUid instead", "Akka 2.4.x")
def addressUid: Int = _addressUid
}

View file

@ -701,7 +701,7 @@ private[pekko] class RemoteActorRef private[pekko] (
}
}
@deprecated("Use context.watch(actor) and receive Terminated(actor)", "2.2")
@deprecated("Use context.watch(actor) and receive Terminated(actor)", "Akka 2.2")
override private[pekko] def isTerminated: Boolean = false
private def handleException(message: Any, sender: ActorRef): Catcher[Unit] = {

View file

@ -103,7 +103,7 @@ final case class RemotingErrorEvent(cause: Throwable) extends RemotingLifecycleE
@deprecated("Classic remoting is deprecated, use Artery", "Akka 2.6.0")
object QuarantinedEvent extends AbstractFunction2[Address, Int, QuarantinedEvent] {
@deprecated("Use long uid apply", "2.4.x")
@deprecated("Use long uid apply", "Akka 2.4.x")
def apply(address: Address, uid: Int) = new QuarantinedEvent(address, uid)
}
@ -119,10 +119,10 @@ final case class QuarantinedEvent(address: Address, longUid: Long) extends Remot
// For binary compatibility
@deprecated("Use long uid constructor", "2.4.x")
@deprecated("Use long uid constructor", "Akka 2.4.x")
def this(address: Address, uid: Int) = this(address, uid.toLong)
@deprecated("Use long uid", "2.4.x")
@deprecated("Use long uid", "Akka 2.4.x")
def uid: Int = longUid.toInt
}

View file

@ -174,10 +174,10 @@ class NettyTransportSettings(config: Config) {
case value => value
}
@deprecated("WARNING: This should only be used by professionals.", "2.0")
@deprecated("WARNING: This should only be used by professionals.", "Akka 2.0")
val PortSelector: Int = getInt("port")
@deprecated("WARNING: This should only be used by professionals.", "2.4")
@deprecated("WARNING: This should only be used by professionals.", "Akka 2.4")
@nowarn("msg=deprecated")
val BindPortSelector: Int = getString("bind-port") match {
case "" => PortSelector

View file

@ -120,7 +120,7 @@ class CancellationStrategySpec extends StreamSpec("""pekko.loglevel = DEBUG
// this asserts the previous broken behavior (which can still be seen with CompleteStage strategy)
fromStream.expectComplete()
}
"be prevented by PropagateFailure strategy (default in 2.6)" in new RaceTestSetup(
"be prevented by PropagateFailure strategy (default in Akka 2.6)" in new RaceTestSetup(
CancellationStrategy.PropagateFailure) {
val theError = TE("Duck meowed")
killSwitch.abort(theError)

View file

@ -33,7 +33,7 @@ trait GraphApply {
*
* Deprecated: this method signature does not work with Scala 3 type inference, kept for binary compatibility. Use createGraph instead.
*/
@deprecated("Use createGraph instead", "2.6.16")
@deprecated("Use createGraph instead", "Akka 2.6.16")
def create[S <: Shape, Mat](g1: Graph[Shape, Mat])(buildBlock: GraphDSL.Builder[Mat] => (g1.Shape) => S): Graph[S, Mat] = {
val builder = new GraphDSL.Builder
val s1 = builder.add(g1, Keep.right)
@ -63,7 +63,7 @@ trait GraphApply {
*
* Deprecated: this method signature does not work with Scala 3 type inference, kept for binary compatibility. Use createGraph instead.
*/
@deprecated("Use createGraph instead", "2.6.16")
@deprecated("Use createGraph instead", "Akka 2.6.16")
def create[S <: Shape, Mat, [#M1#]]([#g1: Graph[Shape, M1]#])(combineMat: ([#M1#]) => Mat)(buildBlock: GraphDSL.Builder[Mat] => ([#g1.Shape#]) => S): Graph[S, Mat] = {
val builder = new GraphDSL.Builder
val curried = combineMat.curried

View file

@ -19,7 +19,7 @@ class StreamTcpException(msg: String) extends RuntimeException(msg) with NoStack
class BindFailedException extends StreamTcpException("bind failed")
@deprecated("BindFailedException object will never be thrown. Match on the class instead.", "2.4.19")
@deprecated("BindFailedException object will never be thrown. Match on the class instead.", "Akka 2.4.19")
case object BindFailedException extends BindFailedException
class ConnectionException(msg: String) extends StreamTcpException(msg)

View file

@ -43,7 +43,7 @@ object FileIO {
*
* @param f The file to write to
*/
@deprecated("Use `toPath` instead.", "2.4.5")
@deprecated("Use `toPath` instead.", "Akka 2.4.5")
def toFile(f: File): javadsl.Sink[ByteString, CompletionStage[IOResult]] = toPath(f.toPath)
/**
@ -80,7 +80,7 @@ object FileIO {
* @param f The file to write to
* @param options File open options, see [[java.nio.file.StandardOpenOption]]
*/
@deprecated("Use `toPath` instead.", "2.4.5")
@deprecated("Use `toPath` instead.", "Akka 2.4.5")
def toFile[Opt <: OpenOption](f: File, options: util.Set[Opt]): javadsl.Sink[ByteString, CompletionStage[IOResult]] =
toPath(f.toPath)
@ -144,7 +144,7 @@ object FileIO {
*
* @param f the file to read from
*/
@deprecated("Use `fromPath` instead.", "2.4.5")
@deprecated("Use `fromPath` instead.", "Akka 2.4.5")
def fromFile(f: File): javadsl.Source[ByteString, CompletionStage[IOResult]] = fromPath(f.toPath)
/**
@ -178,7 +178,7 @@ object FileIO {
* @param f the file to read from
* @param chunkSize the size of each read operation
*/
@deprecated("Use `fromPath` instead.", "2.4.5")
@deprecated("Use `fromPath` instead.", "Akka 2.4.5")
def fromFile(f: File, chunkSize: Int): javadsl.Source[ByteString, CompletionStage[IOResult]] =
fromPath(f.toPath, chunkSize)

View file

@ -45,7 +45,7 @@ object FileIO {
* @param f the file to read from
* @param chunkSize the size of each read operation, defaults to 8192
*/
@deprecated("Use `fromPath` instead", "2.4.5")
@deprecated("Use `fromPath` instead", "Akka 2.4.5")
def fromFile(f: File, chunkSize: Int = 8192): Source[ByteString, Future[IOResult]] =
fromPath(f.toPath, chunkSize)
@ -99,7 +99,7 @@ object FileIO {
* @param f the file to write to
* @param options File open options, see [[java.nio.file.StandardOpenOption]], defaults to Set(WRITE, TRUNCATE_EXISTING, CREATE)
*/
@deprecated("Use `toPath` instead", "2.4.5")
@deprecated("Use `toPath` instead", "Akka 2.4.5")
def toFile(
f: File,
options: Set[OpenOption] = Set(WRITE, TRUNCATE_EXISTING, CREATE)): Sink[ByteString, Future[IOResult]] =