Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Google Cloud Storage: add access with new actors API #2213

Merged
merged 1 commit into from
Mar 19, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ ProblemFilters.exclude[MissingClassProblem]("main.scala.*")
ProblemFilters.exclude[IncompatibleSignatureProblem]("akka.stream.alpakka.googlecloud.storage.StorageObject.*")
ProblemFilters.exclude[IncompatibleMethTypeProblem]("akka.stream.alpakka.googlecloud.storage.StorageObject.withCustomerEncryption")
ProblemFilters.exclude[IncompatibleMethTypeProblem]("akka.stream.alpakka.googlecloud.storage.StorageObject.withOwner")

# override of apply in extension with the concrete type instead of the generic type
ProblemFilters.exclude[IncompatibleResultTypeProblem]("akka.stream.alpakka.googlecloud.storage.GCStorageExt.apply")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Has this really changed? Maybe it's just lightbend-labs/mima#433

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

package akka.stream.alpakka.googlecloud.storage

import akka.actor.{ActorSystem, ExtendedActorSystem, Extension, ExtensionId, ExtensionIdProvider}
import akka.actor.{ClassicActorSystemProvider, ExtendedActorSystem, Extension, ExtensionId, ExtensionIdProvider}

/**
* Manages one [[GCStorageSettings]] per `ActorSystem`.
Expand All @@ -19,6 +19,25 @@ object GCStorageExt extends ExtensionId[GCStorageExt] with ExtensionIdProvider {
override def lookup = GCStorageExt
override def createExtension(system: ExtendedActorSystem) = new GCStorageExt(system)

/** Java API */
override def get(system: ActorSystem): GCStorageExt = super.get(system)
/**
* Get the GCS extension with the classic actors API.
*/
override def apply(system: akka.actor.ActorSystem): GCStorageExt = super.apply(system)

/**
* Get the GCS extension with the new actors API.
*/
def apply(system: ClassicActorSystemProvider): GCStorageExt = super.apply(system.classicSystem)

/**
* Java API.
* Get the GCS extension with the classic actors API.
*/
override def get(system: akka.actor.ActorSystem): GCStorageExt = super.apply(system)

/**
* Java API.
* Get the GCS extension with the new actors API.
*/
def get(system: ClassicActorSystemProvider): GCStorageExt = super.apply(system.classicSystem)
}