This is an automated email from the ASF dual-hosted git repository.
pjfanning pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/pekko-connectors.git
The following commit(s) were added to refs/heads/main by this push:
new ac97749ec remove deprecated methods from google related settings
(#1730)
ac97749ec is described below
commit ac97749ec8e13feece160283c8463add4cc5b527
Author: PJ Fanning <[email protected]>
AuthorDate: Sat Jun 27 02:56:01 2026 +0100
remove deprecated methods from google related settings (#1730)
* remove deprecated methods from google related settings
* Update FcmSettings.scala
* remove StorageSettings
* remove more deprecated code
* Update remove-deprecated-methods.backwards.excludes
* config
* Update remove-deprecated-methods.backwards.excludes
---
.../remove-deprecated-methods.backwards.excludes | 12 +
.../src/main/resources/reference.conf | 15 -
.../googlecloud/storage/GCStorageAttributes.scala | 71 -----
.../googlecloud/storage/GCStorageExt.scala | 51 ----
.../googlecloud/storage/GCStorageSettings.scala | 203 -------------
.../googlecloud/storage/StorageSettings.scala | 48 ----
.../googlecloud/storage/impl/GCStorageStream.scala | 49 +---
.../googlecloud/storage/GCStorageExtSpec.scala | 57 ----
.../storage/GCStorageSettingsSpec.scala | 56 ----
.../storage/scaladsl/GCStorageWiremockBase.scala | 31 +-
.../remove-deprecated-methods.backwards.excludes | 7 +
.../google/firebase/fcm/FcmSettings.scala | 315 +--------------------
12 files changed, 36 insertions(+), 879 deletions(-)
diff --git
a/google-cloud-storage/src/main/mima-filters/2.0.x.backward.excludes/remove-deprecated-methods.backwards.excludes
b/google-cloud-storage/src/main/mima-filters/2.0.x.backward.excludes/remove-deprecated-methods.backwards.excludes
index 343054cc4..b93dd7d24 100644
---
a/google-cloud-storage/src/main/mima-filters/2.0.x.backward.excludes/remove-deprecated-methods.backwards.excludes
+++
b/google-cloud-storage/src/main/mima-filters/2.0.x.backward.excludes/remove-deprecated-methods.backwards.excludes
@@ -16,6 +16,18 @@
# under the License.
# remove deprecated methods
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageAttributes")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageAttributes$")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageExt")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageExt$")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageSettings")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageSettings$")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageSettingsPath")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageSettingsPath$")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageSettingsValue")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.GCStorageSettingsValue$")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.StorageSettings")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.StorageSettings$")
ProblemFilters.exclude[DirectMissingMethodProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.javadsl.GCStorage.createBucket")
ProblemFilters.exclude[DirectMissingMethodProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.javadsl.GCStorage.deleteBucket")
ProblemFilters.exclude[DirectMissingMethodProblem]("org.apache.pekko.stream.connectors.googlecloud.storage.javadsl.GCStorage.getBucket")
diff --git a/google-cloud-storage/src/main/resources/reference.conf
b/google-cloud-storage/src/main/resources/reference.conf
index 96e6fef22..78dda8700 100644
--- a/google-cloud-storage/src/main/resources/reference.conf
+++ b/google-cloud-storage/src/main/resources/reference.conf
@@ -6,21 +6,6 @@ pekko.connectors.google {
default-scopes = ${?pekko.connectors.google.credentials.default-scopes}
["https://www.googleapis.com/auth/devstorage.read_write"]
}
- cloud.storage {
-
- # Deprecated, use config path pekko.connectors.google.credentials
- project-id = deprecated
- client-email = deprecated
- private-key = deprecated
-
- # No longer supported, use config path
pekko.connectors.google.forward-proxy
- base-url = unsupported // "https://www.googleapis.com/" // default
- base-path = unsupported // "/storage/v1" // default
- token-url = unsupported // "https://www.googleapis.com/oauth2/v4/token" //
default
-
- # Deprecated, use config path
pekko.connectors.google.credentials.service-account.scopes
- token-scope = deprecated //
"https://www.googleapis.com/auth/devstorage.read_write" // default
- }
}
pekko.connectors.google {
diff --git
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageAttributes.scala
b/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageAttributes.scala
deleted file mode 100644
index 4602f0854..000000000
---
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageAttributes.scala
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * license agreements; and to You under the Apache License, version 2.0:
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * This file is part of the Apache Pekko project, which was derived from Akka.
- */
-
-/*
- * Copyright (C) since 2016 Lightbend Inc. <https://www.lightbend.com>
- */
-
-package org.apache.pekko.stream.connectors.googlecloud.storage
-
-import org.apache.pekko
-import pekko.stream.Attributes
-import pekko.stream.Attributes.Attribute
-
-/**
- * Pekko Stream attributes that are used when materializing GCStorage stream
blueprints.
- * @deprecated Use [[pekko.stream.connectors.google.GoogleAttributes]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleAttributes",
"Alpakka 3.0.0")
-@Deprecated
-object GCStorageAttributes {
-
- /**
- * Settings to use for the GCStorage stream
- */
- def settings(settings: GCStorageSettings): Attributes =
Attributes(GCStorageSettingsValue(settings))
-
- /**
- * Config path which will be used to resolve required GCStorage settings
- */
- def settingsPath(path: String): Attributes =
Attributes(GCStorageSettingsPath(path))
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleAttributes]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleAttributes",
"Alpakka 3.0.0")
-@Deprecated
-final class GCStorageSettingsPath private (val path: String) extends Attribute
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleAttributes]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleAttributes",
"Alpakka 3.0.0")
-@Deprecated
-object GCStorageSettingsPath {
- val Default = GCStorageSettingsPath(GCStorageSettings.ConfigPath)
-
- def apply(path: String) = new GCStorageSettingsPath(path)
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleAttributes]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleAttributes",
"Alpakka 3.0.0")
-@Deprecated
-final class GCStorageSettingsValue private (val settings: GCStorageSettings)
extends Attribute
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleAttributes]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleAttributes",
"Alpakka 3.0.0")
-@Deprecated
-object GCStorageSettingsValue {
- def apply(settings: GCStorageSettings) = new GCStorageSettingsValue(settings)
-}
diff --git
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageExt.scala
b/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageExt.scala
deleted file mode 100644
index cd366a64d..000000000
---
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageExt.scala
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * license agreements; and to You under the Apache License, version 2.0:
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * This file is part of the Apache Pekko project, which was derived from Akka.
- */
-
-/*
- * Copyright (C) since 2016 Lightbend Inc. <https://www.lightbend.com>
- */
-
-package org.apache.pekko.stream.connectors.googlecloud.storage
-
-import org.apache.pekko
-import pekko.actor.{ ClassicActorSystemProvider, ExtendedActorSystem,
Extension, ExtensionId, ExtensionIdProvider }
-
-/**
- * Manages one [[GCStorageSettings]] per `ActorSystem`.
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]].
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
-@Deprecated
-final class GCStorageExt private (sys: ExtendedActorSystem) extends Extension {
- val settings: GCStorageSettings = settings(GCStorageSettings.ConfigPath)
-
- def settings(prefix: String): GCStorageSettings =
GCStorageSettings(sys.settings.config.getConfig(prefix))
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
-@Deprecated
-object GCStorageExt extends ExtensionId[GCStorageExt] with ExtensionIdProvider
{
- override def lookup = GCStorageExt
- override def createExtension(system: ExtendedActorSystem) = new
GCStorageExt(system)
-
- /**
- * Java API.
- * Get the GCS extension with the classic actors API.
- */
- override def get(system: pekko.actor.ActorSystem): GCStorageExt =
super.apply(system)
-
- /**
- * Java API.
- * Get the GCS extension with the new actors API.
- */
- override def get(system: ClassicActorSystemProvider): GCStorageExt =
super.apply(system)
-}
diff --git
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageSettings.scala
b/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageSettings.scala
deleted file mode 100644
index 5f15718e6..000000000
---
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageSettings.scala
+++ /dev/null
@@ -1,203 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * license agreements; and to You under the Apache License, version 2.0:
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * This file is part of the Apache Pekko project, which was derived from Akka.
- */
-
-/*
- * Copyright (C) since 2016 Lightbend Inc. <https://www.lightbend.com>
- */
-
-package org.apache.pekko.stream.connectors.googlecloud.storage
-
-import org.apache.pekko
-import pekko.actor.{ ActorSystem, ClassicActorSystemProvider }
-import com.typesafe.config.Config
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
-@Deprecated
-final class GCStorageSettings private (
- val projectId: String,
- val clientEmail: String,
- val privateKey: String,
- val baseUrl: String,
- val basePath: String,
- val tokenUrl: String,
- val tokenScope: String) {
-
- /** Java API */
- def getProjectId: String = projectId
-
- /** Java API */
- def getClientEmail: String = clientEmail
-
- /** Java API */
- def getPrivateKey: String = privateKey
-
- /** Java API */
- def getBaseUrl: String = baseUrl
-
- /** Java API */
- def getBasePath: String = basePath
-
- /** Java API */
- def getTokenUrl: String = tokenUrl
-
- /** Java API */
- def getTokenScope: String = tokenScope
-
- def withProjectId(value: String): GCStorageSettings = copy(projectId = value)
- def withClientEmail(value: String): GCStorageSettings = copy(clientEmail =
value)
- def withPrivateKey(value: String): GCStorageSettings = copy(privateKey =
value)
- def withBaseUrl(value: String): GCStorageSettings = copy(baseUrl = value)
- def withBasePath(value: String): GCStorageSettings = copy(basePath = value)
- def withTokenUrl(value: String): GCStorageSettings = copy(tokenUrl = value)
- def withTokenScope(value: String): GCStorageSettings = copy(tokenScope =
value)
-
- private def copy(
- projectId: String = projectId,
- clientEmail: String = clientEmail,
- privateKey: String = privateKey,
- baseUrl: String = baseUrl,
- basePath: String = basePath,
- tokenUrl: String = tokenUrl,
- tokenScope: String = tokenScope): GCStorageSettings = new
GCStorageSettings(
- projectId = projectId,
- clientEmail = clientEmail,
- privateKey = privateKey,
- baseUrl = baseUrl,
- basePath = basePath,
- tokenUrl = tokenUrl,
- tokenScope = tokenScope)
-
- override def toString =
- "GCStorageSettings(" +
- s"projectId=$projectId," +
- s"clientEmail=$clientEmail," +
- s"privateKey=$privateKey," +
- s"baseUrl=$baseUrl," +
- s"basePath=$basePath," +
- s"tokenUrl=$tokenUrl," +
- s"tokenScope=$tokenScope" +
- ")"
-
- override def equals(other: Any): Boolean = other match {
- case that: GCStorageSettings =>
- java.util.Objects.equals(this.projectId, that.projectId) &&
- java.util.Objects.equals(this.clientEmail, that.clientEmail) &&
- java.util.Objects.equals(this.privateKey, that.privateKey) &&
- java.util.Objects.equals(this.baseUrl, that.baseUrl) &&
- java.util.Objects.equals(this.basePath, that.basePath) &&
- java.util.Objects.equals(this.tokenUrl, that.tokenUrl) &&
- java.util.Objects.equals(this.tokenScope, that.tokenScope)
- case _ => false
- }
-
- override def hashCode(): Int =
- java.util.Objects.hash(projectId, clientEmail, privateKey, baseUrl,
basePath, tokenUrl, tokenScope)
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
-@Deprecated
-object GCStorageSettings {
- val ConfigPath = "pekko.connectors.google.cloud.storage"
-
- private val defaultBaseUrl = "https://www.googleapis.com/"
- private val defaultBasePath = "/storage/v1"
- private val defaultTokenUrl = "https://www.googleapis.com/oauth2/v4/token"
- private val defaultTokenScope =
"https://www.googleapis.com/auth/devstorage.read_write"
-
- /**
- * Reads from the given config.
- */
- def apply(c: Config): GCStorageSettings = {
- val projectId = c.getString("project-id")
- val clientEmail = c.getString("client-email")
- val privateKey = c.getString("private-key")
- val baseUrl = c.getString("base-url")
- val basePath = c.getString("base-path")
- val tokenUrl = c.getString("token-url")
- val tokenScope = c.getString("token-scope")
-
- new GCStorageSettings(
- projectId,
- clientEmail,
- privateKey,
- baseUrl,
- basePath,
- tokenUrl,
- tokenScope)
- }
-
- /**
- * Java API: Reads from the given config.
- */
- def create(c: Config): GCStorageSettings = apply(c)
-
- /* sample config section
- -g-c-storage-settings {
- project-id = "some text"
- client-email = "some text"
- private-key = "some text"
- base-url = "some text"
- base-path = "some text"
- token-url = "some text"
- token-scope = "some text"
- }
- */
-
- /** Scala API */
- def apply(
- projectId: String,
- clientEmail: String,
- privateKey: String): GCStorageSettings = new GCStorageSettings(
- projectId,
- clientEmail,
- privateKey,
- defaultBaseUrl,
- defaultBasePath,
- defaultTokenUrl,
- defaultTokenScope)
-
- /** Java API */
- def create(
- projectId: String,
- clientEmail: String,
- privateKey: String): GCStorageSettings = new GCStorageSettings(
- projectId,
- clientEmail,
- privateKey,
- defaultBaseUrl,
- defaultBasePath,
- defaultTokenUrl,
- defaultTokenScope)
-
- /**
- * Scala API: Creates [[GCStorageSettings]] from the
[[com.typesafe.config.Config Config]] attached to an actor system.
- */
- def apply()(implicit system: ClassicActorSystemProvider): GCStorageSettings
= apply(system.classicSystem)
-
- /**
- * Scala API: Creates [[GCStorageSettings]] from the
[[com.typesafe.config.Config Config]] attached to an
[[pekko.actor.ActorSystem]].
- */
- def apply(system: ActorSystem): GCStorageSettings =
apply(system.settings.config.getConfig(ConfigPath))
-
- /**
- * Java API: Creates [[S3Settings]] from the [[com.typesafe.config.Config
Config]] attached to an actor system.
- */
- def create(system: ClassicActorSystemProvider): GCStorageSettings =
apply(system.classicSystem)
-
- /**
- * Java API: Creates [[S3Settings]] from the [[com.typesafe.config.Config
Config]] attached to an [[pekko.actor.ActorSystem]].
- */
- def create(system: ActorSystem): GCStorageSettings = apply(system)
-}
diff --git
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/StorageSettings.scala
b/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/StorageSettings.scala
deleted file mode 100644
index ad516b884..000000000
---
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/StorageSettings.scala
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * license agreements; and to You under the Apache License, version 2.0:
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * This file is part of the Apache Pekko project, which was derived from Akka.
- */
-
-/*
- * Copyright (C) since 2016 Lightbend Inc. <https://www.lightbend.com>
- */
-
-package org.apache.pekko.stream.connectors.googlecloud.storage
-
-/**
- * @deprecated Use [[org.apache.pekko.stream.connectors.google.GoogleSettings]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
-@Deprecated
-final class StorageSettings private (val projectId: String, val clientEmail:
String, val privateKey: String) {
- def withProjectId(projectId: String): StorageSettings = copy(projectId =
projectId)
-
- def withClientEmail(clientEmail: String): StorageSettings = copy(clientEmail
= clientEmail)
-
- def withPrivateKey(privateKey: String): StorageSettings = copy(privateKey =
privateKey)
-
- private def copy(projectId: String = projectId,
- clientEmail: String = clientEmail,
- privateKey: String = privateKey): StorageSettings =
- new StorageSettings(projectId, clientEmail, privateKey)
-
- override def toString: String =
- s"StorageSettings(projectId=$projectId, clientEmail=$clientEmail,
privateKey=**)"
-}
-
-/**
- * @deprecated Use [[org.apache.pekko.stream.connectors.google.GoogleSettings]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
-@Deprecated
-object StorageSettings {
- def apply(projectId: String, clientEmail: String, privateKey: String):
StorageSettings =
- new StorageSettings(projectId, clientEmail, privateKey)
-
- def create(projectId: String, clientEmail: String, privateKey: String):
StorageSettings =
- new StorageSettings(projectId, clientEmail, privateKey)
-}
diff --git
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/impl/GCStorageStream.scala
b/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/impl/GCStorageStream.scala
index 7a9669e0e..d44b04622 100644
---
a/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/impl/GCStorageStream.scala
+++
b/google-cloud-storage/src/main/scala/org/apache/pekko/stream/connectors/googlecloud/storage/impl/GCStorageStream.scala
@@ -23,7 +23,6 @@ import pekko.http.scaladsl.model.Uri.{ Path, Query }
import pekko.http.scaladsl.model._
import pekko.http.scaladsl.unmarshalling.{ FromEntityUnmarshaller,
FromResponseUnmarshaller, Unmarshal, Unmarshaller }
import pekko.stream.connectors.google._
-import pekko.stream.connectors.google.auth.{ Credentials,
ServiceAccountCredentials }
import pekko.stream.connectors.google.http.GoogleHttp
import pekko.stream.connectors.google.implicits._
import pekko.stream.connectors.google.scaladsl.{ `X-Upload-Content-Type`,
Paginated }
@@ -35,7 +34,6 @@ import pekko.util.ByteString
import pekko.{ Done, NotUsed }
import spray.json._
-import scala.annotation.nowarn
import scala.concurrent.{ ExecutionContext, Future }
import scala.concurrent.ExecutionContext.parasitic
@@ -288,51 +286,8 @@ import scala.concurrent.ExecutionContext.parasitic
}
.mapMaterializedValue(_ => NotUsed)
- @nowarn("msg=deprecated")
- private def resolveSettings(mat: Materializer, attr: Attributes) = {
- implicit val sys: ActorSystem = mat.system
- val legacySettings = attr
- .get[GCStorageSettingsValue]
- .map(_.settings)
- .getOrElse {
- val configPath =
attr.get[GCStorageSettingsPath](GCStorageSettingsPath.Default).path
- GCStorageExt(sys).settings(configPath)
- }
-
- val settings = GoogleAttributes.resolveSettings(mat, attr)
-
- if (legacySettings.privateKey == "deprecated")
- GoogleAttributes.resolveSettings(mat, attr)
- else {
- sys.log.warning("Configuration via pekko.connectors.google.cloud.storage
is deprecated")
-
- require(
- (legacySettings.baseUrl.contains("googleapis.com") ||
legacySettings.baseUrl == "unsupported")
- && (legacySettings.basePath.contains("storage/v1") ||
legacySettings.basePath == "unsupported")
- && (legacySettings.tokenUrl.contains("googleapis.com") ||
legacySettings.tokenUrl == "unsupported"),
- "Non-default base-url/base-path/token-url no longer supported, use
config path pekko.connectors.google.forward-proxy")
-
- val legacyScopes = legacySettings.tokenScope.split(" ").toSet
- val credentials = Credentials.cache(
- (
- legacySettings.projectId,
- legacySettings.clientEmail,
- legacySettings.privateKey,
- legacyScopes,
- mat.system.name)) {
- ServiceAccountCredentials(
- legacySettings.projectId,
- legacySettings.clientEmail,
- legacySettings.privateKey,
- legacyScopes)
- }
-
- GoogleSettings(
- legacySettings.projectId,
- credentials,
- settings.requestSettings)
- }
- }
+ private def resolveSettings(mat: Materializer, attr: Attributes) =
+ GoogleAttributes.resolveSettings(mat, attr)
private def resolveGCSSettings(mat: Materializer, attr: Attributes):
GCSSettings = {
implicit val sys: ActorSystem = mat.system
diff --git
a/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageExtSpec.scala
b/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageExtSpec.scala
deleted file mode 100644
index 8f75700f3..000000000
---
a/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageExtSpec.scala
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * license agreements; and to You under the Apache License, version 2.0:
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * This file is part of the Apache Pekko project, which was derived from Akka.
- */
-
-/*
- * Copyright (C) since 2016 Lightbend Inc. <https://www.lightbend.com>
- */
-
-package org.apache.pekko.stream.connectors.googlecloud.storage
-
-import org.apache.pekko
-import pekko.actor.ActorSystem
-import pekko.stream.connectors.testkit.scaladsl.LogCapturing
-import com.typesafe.config.ConfigFactory
-import org.scalatest.flatspec.AnyFlatSpec
-import org.scalatest.matchers.should.Matchers
-
-import scala.annotation.nowarn
-import scala.jdk.CollectionConverters._
-
-class GCStorageExtSpec extends AnyFlatSpec with Matchers with LogCapturing {
- "GCStorageExt" should "reuse application config from actor system" in {
- val projectId = "projectId"
- val clientEmail = "clientEmail"
- val privateKey = "privateKey"
- val baseUrl = "http://base"
- val basePath = "/path"
- val tokenUrl = "http://token"
- val tokenScope = "everything"
-
- val config = ConfigFactory.parseMap(
- Map(
- "pekko.connectors.google.cloud.storage.project-id" -> projectId,
- "pekko.connectors.google.cloud.storage.client-email" -> clientEmail,
- "pekko.connectors.google.cloud.storage.private-key" -> privateKey,
- "pekko.connectors.google.cloud.storage.base-url" -> baseUrl,
- "pekko.connectors.google.cloud.storage.base-path" -> basePath,
- "pekko.connectors.google.cloud.storage.token-url" -> tokenUrl,
- "pekko.connectors.google.cloud.storage.token-scope" ->
tokenScope).asJava)
- implicit val system: ActorSystem = ActorSystem.create("gcStorage", config)
- @nowarn("msg=deprecated")
- val ext = GCStorageExt(system)
-
- ext.settings.projectId shouldBe projectId
- ext.settings.clientEmail shouldBe clientEmail
- ext.settings.privateKey shouldBe privateKey
- ext.settings.baseUrl shouldBe baseUrl
- ext.settings.basePath shouldBe basePath
- ext.settings.tokenUrl shouldBe tokenUrl
- ext.settings.tokenScope shouldBe tokenScope
- }
-}
diff --git
a/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageSettingsSpec.scala
b/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageSettingsSpec.scala
deleted file mode 100644
index c21dedb8c..000000000
---
a/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/GCStorageSettingsSpec.scala
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * license agreements; and to You under the Apache License, version 2.0:
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * This file is part of the Apache Pekko project, which was derived from Akka.
- */
-
-/*
- * Copyright (C) since 2016 Lightbend Inc. <https://www.lightbend.com>
- */
-
-package org.apache.pekko.stream.connectors.googlecloud.storage
-
-import org.apache.pekko
-import pekko.stream.connectors.testkit.scaladsl.LogCapturing
-import com.typesafe.config.ConfigFactory
-import org.scalatest.flatspec.AnyFlatSpec
-import org.scalatest.matchers.should.Matchers
-
-import scala.annotation.nowarn
-import scala.jdk.CollectionConverters._
-
-class GCStorageSettingsSpec extends AnyFlatSpec with Matchers with
LogCapturing {
- "GCStorageSettings" should "create settings from application config" in {
- val projectId = "projectId"
- val clientEmail = "clientEmail"
- val privateKey = "privateKey"
- val baseUrl = "http://base"
- val basePath = "/path"
- val tokenUrl = "http://token"
- val tokenScope = "everything"
-
- val config = ConfigFactory.parseMap(
- Map(
- "project-id" -> projectId,
- "client-email" -> clientEmail,
- "private-key" -> privateKey,
- "base-url" -> baseUrl,
- "base-path" -> basePath,
- "token-url" -> tokenUrl,
- "token-scope" -> tokenScope).asJava)
-
- @nowarn("msg=deprecated")
- val settings = GCStorageSettings(config)
-
- settings.projectId shouldBe projectId
- settings.clientEmail shouldBe clientEmail
- settings.privateKey shouldBe privateKey
- settings.baseUrl shouldBe baseUrl
- settings.basePath shouldBe basePath
- settings.tokenUrl shouldBe tokenUrl
- settings.tokenScope shouldBe tokenScope
- }
-}
diff --git
a/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/scaladsl/GCStorageWiremockBase.scala
b/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/scaladsl/GCStorageWiremockBase.scala
index ceecd79e8..a454a8fae 100644
---
a/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/scaladsl/GCStorageWiremockBase.scala
+++
b/google-cloud-storage/src/test/scala/org/apache/pekko/stream/connectors/googlecloud/storage/scaladsl/GCStorageWiremockBase.scala
@@ -16,7 +16,6 @@ package
org.apache.pekko.stream.connectors.googlecloud.storage.scaladsl
import org.apache.pekko
import pekko.actor.ActorSystem
import pekko.stream.connectors.google.GoogleSettings
-import pekko.stream.connectors.googlecloud.storage.GCStorageSettings
import
pekko.stream.connectors.googlecloud.storage.scaladsl.GCStorageWiremockBase._
import pekko.testkit.TestKit
import com.typesafe.config.ConfigFactory
@@ -27,7 +26,6 @@ import
io.specto.hoverfly.junit.dsl.matchers.HoverflyMatchers.equalsToJson
import spray.json.DefaultJsonProtocol.{ mapFormat, StringJsonFormat }
import spray.json.{ enrichAny, JsObject }
-import scala.annotation.nowarn
import scala.util.Random
abstract class GCStorageWiremockBase(_system: ActorSystem, _wireMockServer:
Hoverfly) extends TestKit(_system) {
@@ -852,29 +850,14 @@ object GCStorageWiremockBase {
private def config(proxyPort: Int) =
ConfigFactory.parseString(s"""
- |${(GCStorageSettings: @nowarn("msg=deprecated")).ConfigPath} {
- | project-id = ""testX-XXXXX""
- | client-email = "[email protected]"
- | private-key = \"\"\"
- |-----BEGIN PRIVATE KEY-----
- |MIICeAIBADANBgkqhkiG9w0BAQEFAASCAmIwggJeAgEAAoGBAMwkmdwrWp+LLlsf
- |bVE+neFjZtUNuaD4/tpQ2UIh2u+qU6sr4bG8PPuqSdrt5b0/0vfMZA11mQWmKpg5
- |PK98kEkhbSvC08fG0TtpR9+vflghOuuvcw6kCniwNbHlOXnE8DwtKQp1DbTUPzMD
- |hhsIjJaUtv19Xk7gh4MqYgANTm6lAgMBAAECgYEAwBXIeHSKxwiNS8ycbg//Oq7v
- |eZV6j077bq0YYLO+cDjSlYOq0DSRJTSsXcXvoE1H00aM9mUq4TfjaGyi/3SzxYsr
- |rSzu/qpYC58MJsnprIjlLgFZmZGe5MOSoul/u6JsBTJGkYPV0xGrtXJY103aSYzC
- |xthpY0BHy9eO9I/pNlkCQQD/64g4INAiBdM4R5iONQvh8LLvqbb8Bw4vVwVFFnAr
- |YHcomxtT9TunMad6KPgbOCd/fTttDADrv54htBrFGXeXAkEAzDTtisPKXPByJnUd
- |jKO2oOg0Fs9IjGeWbnkrsN9j0134ldARE+WbT5S8G5EFo+bQi4ffU3+Y/4ly6Amm
- |OAAzIwJBANV2GAD5HaHDShK/ZTf4dxjWM+pDnSVKnUJPS039EUKdC8cK2RiGjGNA
- |v3jdg1Tw2cE1K8QhJwN8qOFj4JBWVbECQQCwcntej9bnf4vi1wd1YnCHkJyRqQIS
- |7974DhNGfYAQPv5w1JwtCRSuKuJvH1w0R1ijd//scjCNfQKgpNXPRbzpAkAQ8MFA
- |MLpOLGqezUQthJWmVtnXEXaAlb3yFSRTZQVEselObiIc6EvYzNXv780IDT4pyKjg
- |8DS9i5jJDIVWr7mA
- |-----END PRIVATE KEY-----
- |\"\"\"
- |}
|${GoogleSettings.ConfigPath} {
+ | credentials {
+ | type = "service_account"
+ | service-account {
+ | project-id = ""testX-XXXXX""
+ | client-email = "[email protected]"
+ | }
+ | }
| retry-settings {
| max-retries = 1
| max-backoff = 1s
diff --git
a/google-fcm/src/main/mima-filters/2.0.x.backwards.excludes/remove-deprecated-methods.backwards.excludes
b/google-fcm/src/main/mima-filters/2.0.x.backwards.excludes/remove-deprecated-methods.backwards.excludes
index 2eedd19ba..44403ad33 100644
---
a/google-fcm/src/main/mima-filters/2.0.x.backwards.excludes/remove-deprecated-methods.backwards.excludes
+++
b/google-fcm/src/main/mima-filters/2.0.x.backwards.excludes/remove-deprecated-methods.backwards.excludes
@@ -26,6 +26,13 @@
ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.
ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.FcmResponse")
ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.FcmSuccessResponse")
ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.FcmSuccessResponse$")
+ProblemFilters.exclude[DirectMissingMethodProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.FcmSettings.*")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.ForwardProxy")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.ForwardProxy$")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.ForwardProxyCredentials")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.ForwardProxyCredentials$")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.ForwardProxyTrustPem")
+ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.ForwardProxyTrustPem$")
ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.javadsl.GoogleFcm")
ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.javadsl.GoogleFcm$")
ProblemFilters.exclude[MissingClassProblem]("org.apache.pekko.stream.connectors.google.firebase.fcm.scaladsl.GoogleFcm")
diff --git
a/google-fcm/src/main/scala/org/apache/pekko/stream/connectors/google/firebase/fcm/FcmSettings.scala
b/google-fcm/src/main/scala/org/apache/pekko/stream/connectors/google/firebase/fcm/FcmSettings.scala
index 0fa3f3280..3883936bc 100644
---
a/google-fcm/src/main/scala/org/apache/pekko/stream/connectors/google/firebase/fcm/FcmSettings.scala
+++
b/google-fcm/src/main/scala/org/apache/pekko/stream/connectors/google/firebase/fcm/FcmSettings.scala
@@ -14,335 +14,36 @@
package org.apache.pekko.stream.connectors.google.firebase.fcm
import org.apache.pekko
-import pekko.actor.ClassicActorSystemProvider
-import pekko.http.scaladsl.model.headers.BasicHttpCredentials
-import pekko.stream.connectors.google.{ ForwardProxy => CommonForwardProxy }
import java.util.Objects
import scala.annotation.nowarn
-import scala.jdk.OptionConverters._
@nowarn("msg=deprecated")
final class FcmSettings private (
- /** Use [[pekko.stream.connectors.google.GoogleSettings]] */
- @deprecated(
- "Use org.apache.pekko.stream.connectors.google.GoogleSettings",
- "Alpakka 3.0.0") @Deprecated val clientEmail: String,
- /** Use [[pekko.stream.connectors.google.GoogleSettings]] */
- @deprecated(
- "Use org.apache.pekko.stream.connectors.google.GoogleSettings",
- "Alpakka 3.0.0") @Deprecated val privateKey: String,
- /** Use [[pekko.stream.connectors.google.GoogleSettings]] */
- @deprecated(
- "Use org.apache.pekko.stream.connectors.google.GoogleSettings",
- "Alpakka 3.0.0") @Deprecated val projectId: String,
val isTest: Boolean,
- val maxConcurrentConnections: Int,
- /** Use [[pekko.stream.connectors.google.GoogleSettings]] */
- @deprecated(
- "Use org.apache.pekko.stream.connectors.google.GoogleSettings",
- "Alpakka 3.0.0") @Deprecated val forwardProxy: Option[ForwardProxy] =
Option.empty) {
-
- /**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
- @deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
- @Deprecated
- def withClientEmail(value: String): FcmSettings = copy(clientEmail = value)
-
- /**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
- @deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
- @Deprecated
- def withPrivateKey(value: String): FcmSettings = copy(privateKey = value)
-
- /**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
- @deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
- @Deprecated
- def withProjectId(value: String): FcmSettings = copy(projectId = value)
+ val maxConcurrentConnections: Int) {
def withIsTest(value: Boolean): FcmSettings = if (isTest == value) this else
copy(isTest = value)
def withMaxConcurrentConnections(value: Int): FcmSettings =
copy(maxConcurrentConnections = value)
- /**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
- @deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
- @Deprecated
- def withForwardProxy(value: ForwardProxy): FcmSettings = copy(forwardProxy =
Option(value))
-
private def copy(
- clientEmail: String = clientEmail,
- privateKey: String = privateKey,
- projectId: String = projectId,
isTest: Boolean = isTest,
- maxConcurrentConnections: Int = maxConcurrentConnections,
- forwardProxy: Option[ForwardProxy] = forwardProxy): FcmSettings =
- new FcmSettings(clientEmail = clientEmail,
- privateKey = privateKey,
- projectId = projectId,
- isTest = isTest,
- maxConcurrentConnections = maxConcurrentConnections,
- forwardProxy = forwardProxy)
+ maxConcurrentConnections: Int = maxConcurrentConnections): FcmSettings =
+ new FcmSettings(isTest = isTest,
+ maxConcurrentConnections = maxConcurrentConnections)
override def toString =
-
s"""FcmFlowConfig(clientEmail=$clientEmail,projectId=$projectId,isTest=$isTest,maxConcurrentConnections=$maxConcurrentConnections,forwardProxy=$forwardProxy)"""
-
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.ForwardProxy]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.ForwardProxy",
"Alpakka 3.0.0")
-@Deprecated
-object ForwardProxyTrustPem {
-
- /** Scala API */
- def apply(pemPath: String): ForwardProxyTrustPem =
- new ForwardProxyTrustPem(pemPath)
-
- /** Java API */
- def create(pemPath: String): ForwardProxyTrustPem =
- apply(pemPath)
-
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.ForwardProxy]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.ForwardProxy",
"Alpakka 3.0.0")
-@Deprecated
-final class ForwardProxyTrustPem private (val pemPath: String) {
-
- def getPemPath: String = pemPath
-
- override def toString: String =
- "ForwardProxyTrustPem(" +
- s"pemPath=$pemPath," +
- ")"
-
- override def equals(other: Any): Boolean = other match {
- case that: ForwardProxyTrustPem =>
- Objects.equals(this.pemPath, that.pemPath)
- case _ => false
- }
-
- override def hashCode(): Int =
- Objects.hash(pemPath)
-
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.ForwardProxy]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.ForwardProxy",
"Alpakka 3.0.0")
-@Deprecated
-object ForwardProxyCredentials {
-
- /** Scala API */
- def apply(username: String, password: String): ForwardProxyCredentials =
- new ForwardProxyCredentials(username, password)
-
- /** Java API */
- def create(username: String, password: String): ForwardProxyCredentials =
- apply(username, password)
-
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.ForwardProxy]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.ForwardProxy",
"Alpakka 3.0.0")
-@Deprecated
-final class ForwardProxyCredentials private (val username: String, val
password: String) {
-
- /** Java API */
- def getUsername: String = username
-
- /** Java API */
- def getPassword: String = password
-
- def withUsername(username: String) = copy(username = username)
- def withPassword(password: String) = copy(password = password)
-
- private def copy(username: String = username, password: String = password) =
- new ForwardProxyCredentials(username, password)
-
- override def toString =
- "ForwardProxyCredentials(" +
- s"username=$username," +
- s"password=******" +
- ")"
-
- override def equals(other: Any): Boolean = other match {
- case that: ForwardProxyCredentials =>
- Objects.equals(this.username, that.username) &&
- Objects.equals(this.password, that.password)
- case _ => false
- }
-
- override def hashCode(): Int =
- Objects.hash(username, password)
-
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.ForwardProxy]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.ForwardProxy",
"Alpakka 3.0.0")
-@Deprecated
-object ForwardProxy {
-
- /** Scala API */
- def apply(host: String, port: Int) =
- new ForwardProxy(host, port, Option.empty, Option.empty)
-
- def apply(host: String, port: Int, credentials:
Option[ForwardProxyCredentials]) =
- new ForwardProxy(host, port, credentials, Option.empty)
-
- def apply(host: String,
- port: Int,
- credentials: Option[ForwardProxyCredentials],
- trustPem: Option[ForwardProxyTrustPem]) =
- new ForwardProxy(host, port, credentials, trustPem)
-
- /** Java API */
- def create(host: String, port: Int) =
- apply(host, port)
-
- def create(host: String, port: Int, credentials:
Option[ForwardProxyCredentials]) =
- apply(host, port, credentials)
-
- def create(host: String,
- port: Int,
- credentials: Option[ForwardProxyCredentials],
- trustPem: Option[ForwardProxyTrustPem]) =
- apply(host, port, credentials, trustPem)
-
-}
-
-/**
- * @deprecated Use [[pekko.stream.connectors.google.ForwardProxy]]
- */
-@deprecated("Use org.apache.pekko.stream.connectors.google.ForwardProxy",
"Alpakka 3.0.0")
-@Deprecated
-final class ForwardProxy private (val host: String,
- val port: Int,
- val credentials: Option[ForwardProxyCredentials],
- val trustPem: Option[ForwardProxyTrustPem]) {
-
- /** Java API */
- def getHost: String = host
-
- /** Java API */
- def getPort: Int = port
-
- /** Java API */
- def getCredentials: java.util.Optional[ForwardProxyCredentials] =
credentials.toJava
-
- def getForwardProxyTrustPem: java.util.Optional[ForwardProxyTrustPem] =
trustPem.toJava
-
- def withHost(host: String) = copy(host = host)
- def withPort(port: Int) = copy(port = port)
- def withCredentials(credentials: ForwardProxyCredentials) = copy(credentials
= Option(credentials))
-
- private def copy(host: String = host,
- port: Int = port,
- credentials: Option[ForwardProxyCredentials] = credentials,
- trustPem: Option[ForwardProxyTrustPem] = trustPem) =
- new ForwardProxy(host, port, credentials, trustPem)
-
- override def toString =
- "ForwardProxy(" +
- s"host=$host," +
- s"port=$port," +
- s"credentials=$credentials," +
- s"trustPem=$trustPem" +
- ")"
-
- override def equals(other: Any): Boolean = other match {
- case that: ForwardProxy =>
- Objects.equals(this.host, that.host) &&
- Objects.equals(this.port, that.port) &&
- Objects.equals(this.credentials, that.credentials) &&
- Objects.equals(this.trustPem, that.trustPem)
- case _ => false
- }
-
- override def hashCode(): Int =
- Objects.hash(host, Int.box(port), credentials)
-
- private[fcm] def toCommonForwardProxy(implicit system:
ClassicActorSystemProvider) =
- CommonForwardProxy(
- "https",
- host,
- port,
- credentials.map(c => BasicHttpCredentials(c.username, c.password)),
- trustPem.map(_.pemPath))
+
s"""FcmFlowConfig(isTest=$isTest,maxConcurrentConnections=$maxConcurrentConnections)"""
}
object FcmSettings {
/** Scala API */
- @nowarn("msg=deprecated")
- def apply(): FcmSettings = apply("deprecated", "deprecated", "deprecated")
-
- /** Java API */
- def create(): FcmSettings = apply()
-
- /**
- * Scala API
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
- @deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
- @Deprecated
- def apply(
- clientEmail: String,
- privateKey: String,
- projectId: String): FcmSettings = new FcmSettings(
- clientEmail,
- privateKey,
- projectId,
+ def apply(): FcmSettings = new FcmSettings(
isTest = false,
maxConcurrentConnections = 100)
- /**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
- @deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
- @Deprecated
- def apply(
- clientEmail: String,
- privateKey: String,
- projectId: String,
- forwardProxy: ForwardProxy): FcmSettings = new FcmSettings(
- clientEmail,
- privateKey,
- projectId,
- isTest = false,
- maxConcurrentConnections = 100,
- forwardProxy = Option(forwardProxy))
-
- /**
- * Java API
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
- @deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
- @Deprecated
- def create(clientEmail: String, privateKey: String, projectId: String):
FcmSettings = {
- apply(clientEmail, privateKey, projectId)
- }
-
- /**
- * @deprecated Use [[pekko.stream.connectors.google.GoogleSettings]]
- */
- @deprecated("Use org.apache.pekko.stream.connectors.google.GoogleSettings",
"Alpakka 3.0.0")
- @Deprecated
- def create(clientEmail: String, privateKey: String, projectId: String,
forwardProxy: ForwardProxy): FcmSettings = {
- apply(clientEmail, privateKey, projectId, forwardProxy)
- }
+ /** Java API */
+ def create(): FcmSettings = apply()
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]