From 65b5efa6b8c0c99b07808e88d3d53cde8cc90ae2 Mon Sep 17 00:00:00 2001 From: Jihun-Hwang Date: Sun, 14 Jul 2024 14:06:53 +0900 Subject: [PATCH] =?UTF-8?q?refactor:=20ktlint=20trailing=20comma=20?= =?UTF-8?q?=ED=97=88=EC=9A=A9=20=EB=A3=B0=20=EC=A0=81=EC=9A=A9(storage=20?= =?UTF-8?q?=EB=AA=A8=EB=93=88)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/kotlin/com/few/storage/config/ClientConfig.kt | 2 +- .../few/storage/document/client/S3DocumentStoreClient.kt | 2 +- .../few/storage/document/client/dto/DocumentObjectArgs.kt | 6 +++--- .../storage/document/client/dto/DocumentWriteResponse.kt | 2 +- .../few/storage/document/config/S3DocumentStoreConfig.kt | 2 +- .../document/service/s3/S3GetPreSignedDocumentUrlService.kt | 2 +- .../few/storage/document/service/s3/S3PutDocumentService.kt | 2 +- .../com/few/storage/image/client/S3ImageStoreClient.kt | 2 +- .../com/few/storage/image/client/dto/ImageObjectArgs.kt | 6 +++--- .../com/few/storage/image/client/dto/ImageWriteResponse.kt | 2 +- .../com/few/storage/image/config/S3ImageStoreConfig.kt | 2 +- .../image/service/s3/S3GetPreSignedImageUrlService.kt | 2 +- .../com/few/storage/image/service/s3/S3PutImageService.kt | 2 +- .../few/storage/image/service/s3/S3RemoveImageService.kt | 2 +- .../com/few/storage/image/service/support/CdnProperty.kt | 2 +- 15 files changed, 19 insertions(+), 19 deletions(-) diff --git a/storage/src/main/kotlin/com/few/storage/config/ClientConfig.kt b/storage/src/main/kotlin/com/few/storage/config/ClientConfig.kt index eae4aff84..1c074d889 100644 --- a/storage/src/main/kotlin/com/few/storage/config/ClientConfig.kt +++ b/storage/src/main/kotlin/com/few/storage/config/ClientConfig.kt @@ -14,7 +14,7 @@ class ClientConfig( @Value("\${storage.url}") val url: String, @Value("\${storage.access-key}") val accessKey: String, @Value("\${storage.secret-key}") val secretKey: String, - @Value("\${storage.region}") val region: String + @Value("\${storage.region}") val region: String, ) { @Bean diff --git a/storage/src/main/kotlin/com/few/storage/document/client/S3DocumentStoreClient.kt b/storage/src/main/kotlin/com/few/storage/document/client/S3DocumentStoreClient.kt index 3af313578..46c548c26 100644 --- a/storage/src/main/kotlin/com/few/storage/document/client/S3DocumentStoreClient.kt +++ b/storage/src/main/kotlin/com/few/storage/document/client/S3DocumentStoreClient.kt @@ -10,7 +10,7 @@ import org.slf4j.LoggerFactory class S3DocumentStoreClient( private val s3client: AmazonS3Client, - private val region: String + private val region: String, ) : DocumentStoreClient { private val log = LoggerFactory.getLogger(S3DocumentStoreClient::class.java) diff --git a/storage/src/main/kotlin/com/few/storage/document/client/dto/DocumentObjectArgs.kt b/storage/src/main/kotlin/com/few/storage/document/client/dto/DocumentObjectArgs.kt index 5422adde0..b45f6db06 100644 --- a/storage/src/main/kotlin/com/few/storage/document/client/dto/DocumentObjectArgs.kt +++ b/storage/src/main/kotlin/com/few/storage/document/client/dto/DocumentObjectArgs.kt @@ -36,7 +36,7 @@ fun DocumentPutObjectArgs.toS3Args(): PutObjectRequest { data class DocumentGetPreSignedObjectUrlArgs( val bucket: String, val imagePath: String, - val method: String + val method: String, ) data class DocumentPutObjectArgs( @@ -45,10 +45,10 @@ data class DocumentPutObjectArgs( val stream: InputStream, val objectSize: Long, val partSize: Long, - val contentType: ContentType = ContentType.IMAGE_JPEG + val contentType: ContentType = ContentType.IMAGE_JPEG, ) data class DocumentRemoveObjectArgs( val bucket: String, - val imagePath: String + val imagePath: String, ) \ No newline at end of file diff --git a/storage/src/main/kotlin/com/few/storage/document/client/dto/DocumentWriteResponse.kt b/storage/src/main/kotlin/com/few/storage/document/client/dto/DocumentWriteResponse.kt index 048c3fba4..28dec8ebc 100644 --- a/storage/src/main/kotlin/com/few/storage/document/client/dto/DocumentWriteResponse.kt +++ b/storage/src/main/kotlin/com/few/storage/document/client/dto/DocumentWriteResponse.kt @@ -5,5 +5,5 @@ data class DocumentWriteResponse( val region: String, val `object`: String, val etag: String, - val versionId: String + val versionId: String, ) \ No newline at end of file diff --git a/storage/src/main/kotlin/com/few/storage/document/config/S3DocumentStoreConfig.kt b/storage/src/main/kotlin/com/few/storage/document/config/S3DocumentStoreConfig.kt index 84e18627e..8deba5b86 100644 --- a/storage/src/main/kotlin/com/few/storage/document/config/S3DocumentStoreConfig.kt +++ b/storage/src/main/kotlin/com/few/storage/document/config/S3DocumentStoreConfig.kt @@ -17,7 +17,7 @@ import org.springframework.context.event.ContextRefreshedEvent @Import(ClientConfig::class) class S3DocumentStoreConfig( @Value("\${document.store.bucket-name}") val bucket: String, - @Value("\${storage.region}") val region: String + @Value("\${storage.region}") val region: String, ) : ApplicationListener { var log: Logger = LoggerFactory.getLogger(S3DocumentStoreConfig::class.java) diff --git a/storage/src/main/kotlin/com/few/storage/document/service/s3/S3GetPreSignedDocumentUrlService.kt b/storage/src/main/kotlin/com/few/storage/document/service/s3/S3GetPreSignedDocumentUrlService.kt index 37c15df87..b82341a7d 100644 --- a/storage/src/main/kotlin/com/few/storage/document/service/s3/S3GetPreSignedDocumentUrlService.kt +++ b/storage/src/main/kotlin/com/few/storage/document/service/s3/S3GetPreSignedDocumentUrlService.kt @@ -9,7 +9,7 @@ import org.springframework.stereotype.Service @Service class S3GetPreSignedDocumentUrlService( @Value("\${document.store.bucket-name}") val bucket: String, - private val documentStoreClient: DocumentStoreClient + private val documentStoreClient: DocumentStoreClient, ) : GetPreSignedDocumentUrlService { override fun execute(image: String): String? { DocumentArgsGenerator.preSignedUrl(bucket, image).let { args -> diff --git a/storage/src/main/kotlin/com/few/storage/document/service/s3/S3PutDocumentService.kt b/storage/src/main/kotlin/com/few/storage/document/service/s3/S3PutDocumentService.kt index 3ac00ba0a..9e702245e 100644 --- a/storage/src/main/kotlin/com/few/storage/document/service/s3/S3PutDocumentService.kt +++ b/storage/src/main/kotlin/com/few/storage/document/service/s3/S3PutDocumentService.kt @@ -11,7 +11,7 @@ import java.io.File @Service class S3PutDocumentService( @Value("\${document.store.bucket-name}") val bucket: String, - private val documentStoreClient: DocumentStoreClient + private val documentStoreClient: DocumentStoreClient, ) : PutDocumentService { override fun execute(name: String, file: File): DocumentWriteResponse? { DocumentArgsGenerator.putDocument(bucket, name, file).let { args -> diff --git a/storage/src/main/kotlin/com/few/storage/image/client/S3ImageStoreClient.kt b/storage/src/main/kotlin/com/few/storage/image/client/S3ImageStoreClient.kt index c02060fac..684b85dbc 100644 --- a/storage/src/main/kotlin/com/few/storage/image/client/S3ImageStoreClient.kt +++ b/storage/src/main/kotlin/com/few/storage/image/client/S3ImageStoreClient.kt @@ -7,7 +7,7 @@ import org.slf4j.LoggerFactory class S3ImageStoreClient( private val s3client: AmazonS3Client, - private val region: String + private val region: String, ) : ImageStoreClient { val log: Logger = LoggerFactory.getLogger(S3ImageStoreClient::class.java) diff --git a/storage/src/main/kotlin/com/few/storage/image/client/dto/ImageObjectArgs.kt b/storage/src/main/kotlin/com/few/storage/image/client/dto/ImageObjectArgs.kt index 95527eb42..e4e971682 100644 --- a/storage/src/main/kotlin/com/few/storage/image/client/dto/ImageObjectArgs.kt +++ b/storage/src/main/kotlin/com/few/storage/image/client/dto/ImageObjectArgs.kt @@ -37,7 +37,7 @@ fun ImagePutObjectArgs.toS3Args(): PutObjectRequest { data class ImageGetPreSignedObjectUrlArgs( val bucket: String, val imagePath: String, - val method: String + val method: String, ) data class ImagePutObjectArgs( @@ -46,10 +46,10 @@ data class ImagePutObjectArgs( val stream: InputStream, val objectSize: Long, val partSize: Long, - val contentType: ContentType = ContentType.IMAGE_JPEG + val contentType: ContentType = ContentType.IMAGE_JPEG, ) data class ImageRemoveObjectArgs( val bucket: String, - val imagePath: String + val imagePath: String, ) \ No newline at end of file diff --git a/storage/src/main/kotlin/com/few/storage/image/client/dto/ImageWriteResponse.kt b/storage/src/main/kotlin/com/few/storage/image/client/dto/ImageWriteResponse.kt index 7aebdffb1..2f42b6aee 100644 --- a/storage/src/main/kotlin/com/few/storage/image/client/dto/ImageWriteResponse.kt +++ b/storage/src/main/kotlin/com/few/storage/image/client/dto/ImageWriteResponse.kt @@ -5,5 +5,5 @@ data class ImageWriteResponse( val region: String, val `object`: String, val etag: String, - val versionId: String + val versionId: String, ) \ No newline at end of file diff --git a/storage/src/main/kotlin/com/few/storage/image/config/S3ImageStoreConfig.kt b/storage/src/main/kotlin/com/few/storage/image/config/S3ImageStoreConfig.kt index 659ac7693..5180b3c59 100644 --- a/storage/src/main/kotlin/com/few/storage/image/config/S3ImageStoreConfig.kt +++ b/storage/src/main/kotlin/com/few/storage/image/config/S3ImageStoreConfig.kt @@ -14,7 +14,7 @@ import org.springframework.context.event.ContextRefreshedEvent @Configuration class S3ImageStoreConfig( @Value("\${image.store.bucket-name}") val bucket: String, - @Value("\${storage.region}") val region: String + @Value("\${storage.region}") val region: String, ) : ApplicationListener { var log: Logger = LoggerFactory.getLogger(S3ImageStoreConfig::class.java) diff --git a/storage/src/main/kotlin/com/few/storage/image/service/s3/S3GetPreSignedImageUrlService.kt b/storage/src/main/kotlin/com/few/storage/image/service/s3/S3GetPreSignedImageUrlService.kt index cc6f12830..77dd026e5 100644 --- a/storage/src/main/kotlin/com/few/storage/image/service/s3/S3GetPreSignedImageUrlService.kt +++ b/storage/src/main/kotlin/com/few/storage/image/service/s3/S3GetPreSignedImageUrlService.kt @@ -9,7 +9,7 @@ import org.springframework.stereotype.Service @Service class S3GetPreSignedImageUrlService( @Value("\${image.store.bucket-name}") val bucket: String, - private val imageStoreClient: ImageStoreClient + private val imageStoreClient: ImageStoreClient, ) : GetPreSignedImageUrlService { override fun execute(image: String): String? { ImageArgsGenerator.preSignedUrl(bucket, image).let { args -> diff --git a/storage/src/main/kotlin/com/few/storage/image/service/s3/S3PutImageService.kt b/storage/src/main/kotlin/com/few/storage/image/service/s3/S3PutImageService.kt index b4a81a56a..09fbc31e6 100644 --- a/storage/src/main/kotlin/com/few/storage/image/service/s3/S3PutImageService.kt +++ b/storage/src/main/kotlin/com/few/storage/image/service/s3/S3PutImageService.kt @@ -11,7 +11,7 @@ import java.io.File @Service class S3PutImageService( @Value("\${image.store.bucket-name}") val bucket: String, - private val imageStoreClient: ImageStoreClient + private val imageStoreClient: ImageStoreClient, ) : PutImageService { override fun execute(name: String, file: File): ImageWriteResponse? { ImageArgsGenerator.putImage(bucket, name, file).let { args -> diff --git a/storage/src/main/kotlin/com/few/storage/image/service/s3/S3RemoveImageService.kt b/storage/src/main/kotlin/com/few/storage/image/service/s3/S3RemoveImageService.kt index 577063b55..db1f80ffa 100644 --- a/storage/src/main/kotlin/com/few/storage/image/service/s3/S3RemoveImageService.kt +++ b/storage/src/main/kotlin/com/few/storage/image/service/s3/S3RemoveImageService.kt @@ -9,7 +9,7 @@ import org.springframework.stereotype.Service @Service class S3RemoveImageService( @Value("\${image.store.bucket-name}") val bucket: String, - private val imageStoreClient: ImageStoreClient + private val imageStoreClient: ImageStoreClient, ) : RemoveImageService { override fun execute(image: String): Boolean { ImageArgsGenerator.remove(bucket, image).let { args -> diff --git a/storage/src/main/kotlin/com/few/storage/image/service/support/CdnProperty.kt b/storage/src/main/kotlin/com/few/storage/image/service/support/CdnProperty.kt index 8dd03f32d..3fe8bdca4 100644 --- a/storage/src/main/kotlin/com/few/storage/image/service/support/CdnProperty.kt +++ b/storage/src/main/kotlin/com/few/storage/image/service/support/CdnProperty.kt @@ -5,5 +5,5 @@ import org.springframework.stereotype.Component @Component data class CdnProperty( - @Value("\${cdn.url}") val url: String + @Value("\${cdn.url}") val url: String, ) \ No newline at end of file