diff options
author | Jakob Odersky <jakob@driver.xyz> | 2018-10-04 13:52:14 -0700 |
---|---|---|
committer | Jakob Odersky <jakob@odersky.com> | 2018-10-09 16:19:39 -0700 |
commit | 477804e21c3c61666a48b74f17caef04233c2363 (patch) | |
tree | 0f12c52e34850cac4ddeab99ae8b5d761f2dd3a3 /core-storage/src/main/scala/xyz/driver/core/storage | |
parent | e67f49c20c6901bf77bcfb735254e44dc70c0cee (diff) | |
download | driver-core-477804e21c3c61666a48b74f17caef04233c2363.tar.gz driver-core-477804e21c3c61666a48b74f17caef04233c2363.tar.bz2 driver-core-477804e21c3c61666a48b74f17caef04233c2363.zip |
Fix dependencies in tests to accomodate project split
Diffstat (limited to 'core-storage/src/main/scala/xyz/driver/core/storage')
-rw-r--r-- | core-storage/src/main/scala/xyz/driver/core/storage/AliyunBlobStorage.scala | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/core-storage/src/main/scala/xyz/driver/core/storage/AliyunBlobStorage.scala b/core-storage/src/main/scala/xyz/driver/core/storage/AliyunBlobStorage.scala index 7e59df4..fd0e7c6 100644 --- a/core-storage/src/main/scala/xyz/driver/core/storage/AliyunBlobStorage.scala +++ b/core-storage/src/main/scala/xyz/driver/core/storage/AliyunBlobStorage.scala @@ -18,11 +18,11 @@ import scala.concurrent.duration.Duration import scala.concurrent.{ExecutionContext, Future} class AliyunBlobStorage( - client: OSSClient, - bucketId: String, - clock: Clock, - chunkSize: Int = AliyunBlobStorage.DefaultChunkSize)(implicit ec: ExecutionContext) - extends SignedBlobStorage { + client: OSSClient, + bucketId: String, + clock: Clock, + chunkSize: Int = AliyunBlobStorage.DefaultChunkSize)(implicit ec: ExecutionContext) + extends SignedBlobStorage { override def uploadContent(name: String, content: Array[Byte]): Future[String] = Future { client.putObject(bucketId, name, new ByteArrayInputStream(content)) name @@ -61,7 +61,7 @@ class AliyunBlobStorage( Future { client.putObject(bucketId, name, is) Done - }) + }) } override def delete(name: String): Future[String] = Future { @@ -92,8 +92,7 @@ class AliyunBlobStorage( object AliyunBlobStorage { val DefaultChunkSize: Int = 8192 - def apply(config: Config, bucketId: String, clock: Clock)( - implicit ec: ExecutionContext): AliyunBlobStorage = { + def apply(config: Config, bucketId: String, clock: Clock)(implicit ec: ExecutionContext): AliyunBlobStorage = { val clientId = config.getString("storage.aliyun.clientId") val clientSecret = config.getString("storage.aliyun.clientSecret") val endpoint = config.getString("storage.aliyun.endpoint") @@ -101,7 +100,7 @@ object AliyunBlobStorage { } def apply(clientId: String, clientSecret: String, endpoint: String, bucketId: String, clock: Clock)( - implicit ec: ExecutionContext): AliyunBlobStorage = { + implicit ec: ExecutionContext): AliyunBlobStorage = { val client = new OSSClient(endpoint, clientId, clientSecret) new AliyunBlobStorage(client, bucketId, clock) } |