huaweicloud-obs-spring-boot-starter

HuaWei Cloud Object Storage Spring Boot Starter

License

License

Categories

Categories

Spring Boot Container Microservices
GroupId

GroupId

com.github.lkqm
ArtifactId

ArtifactId

huaweicloud-obs-spring-boot-starter
Last Version

Last Version

0.0.1
Release Date

Release Date

Type

Type

jar
Description

Description

huaweicloud-obs-spring-boot-starter
HuaWei Cloud Object Storage Spring Boot Starter
Project URL

Project URL

https://github.com/lkqm/huaweicloud-obs-spring-boot-starter
Project Organization

Project Organization

Pivotal Software, Inc.
Source Code Management

Source Code Management

https://github.com/lkqm/huaweicloud-obs-spring-boot-starter

Download huaweicloud-obs-spring-boot-starter

How to add to project

<!-- https://jarcasting.com/artifacts/com.github.lkqm/huaweicloud-obs-spring-boot-starter/ -->
<dependency>
    <groupId>com.github.lkqm</groupId>
    <artifactId>huaweicloud-obs-spring-boot-starter</artifactId>
    <version>0.0.1</version>
</dependency>
// https://jarcasting.com/artifacts/com.github.lkqm/huaweicloud-obs-spring-boot-starter/
implementation 'com.github.lkqm:huaweicloud-obs-spring-boot-starter:0.0.1'
// https://jarcasting.com/artifacts/com.github.lkqm/huaweicloud-obs-spring-boot-starter/
implementation ("com.github.lkqm:huaweicloud-obs-spring-boot-starter:0.0.1")
'com.github.lkqm:huaweicloud-obs-spring-boot-starter:jar:0.0.1'
<dependency org="com.github.lkqm" name="huaweicloud-obs-spring-boot-starter" rev="0.0.1">
  <artifact name="huaweicloud-obs-spring-boot-starter" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.github.lkqm', module='huaweicloud-obs-spring-boot-starter', version='0.0.1')
)
libraryDependencies += "com.github.lkqm" % "huaweicloud-obs-spring-boot-starter" % "0.0.1"
[com.github.lkqm/huaweicloud-obs-spring-boot-starter "0.0.1"]

Dependencies

compile (4)

Group / Artifact Type Version
org.springframework.boot : spring-boot-starter jar 1.5.22.RELEASE
org.springframework.boot : spring-boot-configuration-processor Optional jar 1.5.22.RELEASE
com.huaweicloud : esdk-obs-java jar 3.20.6.1
org.projectlombok : lombok Optional jar 1.16.22

test (1)

Group / Artifact Type Version
org.springframework.boot : spring-boot-starter-test jar 1.5.22.RELEASE

Project Modules

There are no modules declared in this project.

huaweicloud-obs-spring-boot-starter

huaweicloud-sdk-java-obs spring boot starter.

Supports: JDK 1.7, spring-boot 1.5.x, spring-boot 2.x

Quick

  1. Add dependency

    <dependency>
       <groupId>com.github.lkqm</groupId>
       <artifactId>huaweicloud-obs-spring-boot-starter</artifactId>
       <version>${version}</version>
    </dependency>
    
  2. Config property

    huaweicloud.obs.endpoint=@endpoint                    # service (MUST)
    huaweicloud.obs.access-key-id=@keyId                  # access key id
    huaweicloud.obs.access-key-secret=@secret             # access key secret
    huaweicloud.obs.security-token=@token                 # auth token
    huaweicloud.obs.config.XXX                            # other configuration,see `ObsConfiguration`
    
  3. Use

    @Resource
    ObsClient obsClient;
    
    @Test
    public void test() {
        obsClient.putObject(bucketName, objectKey, new ByteArrayInputStream(content.getBytes("UTF-8")), null);
    }
    

Versions

Version
0.0.1