IBM Sterling B2B: Configuring SB2Bi to use S3 Storage Provider

Configure AWS SDK for Java on SB2Bi
1) Download AWS SDK for Java from this location https://sdk-for-java.amazonwebservices.com/latest/aws-java-sdk.zip and unzip file.

cd /tmp wget https://sdk-for-java.amazonwebservices.com/latest/aws-java-sdk.zip unzip aws-java-sdk.zip

2) Stop Sterling B2B Integrator

cd /opt/IBM/SterlingIntegrator/bin ./softStop.sh -all ./hardStop.sh

3) Install aws-java-sdk-[version].jar

./install3rdParty.sh awssdk 1.12.565 -j /tmp/aws-java-sdk-1.12.565/lib/aws-java-sdk-1.12.565.jar

4) Import third party libraries

Now we need to import third party libraries (httpclient-[ver].jar,httpcore-[ver].jar, jackson-annotations-[ver].jar, joda-time-[ver].jar) from directory

/tmp/aws-java-sdk-1.12.565/third-party/lib/

but is important to make sure that in /properties/dynamicclasspath.cfg and dynamicclasspath.cfg.in, there are no duplicates (like httpclient.jar) and with a higher version.

in my case SB2Bi 6.2 and aws-java-sdk-1.12.565, in need to

./install3rdParty.sh awssdk 1.12.565 -j /tmp/aws-java-sdk-1.12.565/third-party/lib/netty-codec-http-4.1.94.Final.jar ./install3rdParty.sh awssdk 1.12.565 -j /tmp/aws-java-sdk-1.12.565/third-party/lib/netty-common-4.1.94.Final.jar ./install3rdParty.sh awssdk 1.12.565 -j /tmp/aws-java-sdk-1.12.565/third-party/lib/netty-buffer-4.1.94.Final.jar ./install3rdParty.sh awssdk 1.12.565 -j /tmp/aws-java-sdk-1.12.565/third-party/lib/netty-transport-4.1.94.Final.jar ./install3rdParty.sh awssdk 1.12.565 -j /tmp/aws-java-sdk-1.12.565/third-party/lib/netty-resolver-4.1.94.Final.jar ./install3rdParty.sh awssdk 1.12.565 -j /tmp/aws-java-sdk-1.12.565/third-party/lib/netty-codec-4.1.94.Final.jar ./install3rdParty.sh awssdk 1.12.565 -j /tmp/aws-java-sdk-1.12.565/third-party/lib/netty-handler-4.1.94.Final.jar ./install3rdParty.sh awssdk 1.12.565 -j /tmp/aws-java-sdk-1.12.565/third-party/lib/netty-transport-native-unix-common-4.1.94.Final.jar

so my dynamicclasspath.cfg looked like this:

... VENDOR_JAR=/opt/IBM/SterlingIntegrator/jar/awssdk/1.12.565/aws-java-sdk-1.12.565.jar VENDOR_JAR=/opt/IBM/SterlingIntegrator/jar/awssdk/1.12.565/netty-buffer-4.1.94.Final.jar VENDOR_JAR=/opt/IBM/SterlingIntegrator/jar/awssdk/1.12.565/netty-transport-4.1.94.Final.jar VENDOR_JAR=/opt/IBM/SterlingIntegrator/jar/awssdk/1.12.565/netty-resolver-4.1.94.Final.jar VENDOR_JAR=/opt/IBM/SterlingIntegrator/jar/awssdk/1.12.565/netty-codec-4.1.94.Final.jar VENDOR_JAR=/opt/IBM/SterlingIntegrator/jar/awssdk/1.12.565/netty-handler-4.1.94.Final.jar VENDOR_JAR=/opt/IBM/SterlingIntegrator/jar/awssdk/1.12.565/netty-transport-native-unix-common-4.1.94.Final.jar VENDOR_JAR=/opt/IBM/SterlingIntegrator/jar/awssdk/1.12.565/netty-codec-http-4.1.94.Final.jar

5) Run setupfiles and Start Sterling B2B Integrator

./setupfiles.sh ./run.sh

= Deploying MinIO (S3 storage) =

MinIO is not listed as supported by SB2Bi, but for testing and validation purposes will be excelent.

1) The fastest way to have MinIO: MinIO: Deploy MinIO as Container

Important:


 * S3 Protocol Port: 9000
 * MinIO console Port: 9001

2) Access MinIO console Sample:  http://10.1.1.1:9001/login . To login provide the variables from podman command:

-e "MINIO_ROOT_USER=root" \ -e "MINIO_ROOT_PASSWORD=passw0rd" \

3) Create a bucket. Sample: mysfg-bucket-minio

4) Create an access token. See here MinIO

5) upload a file to test. Example: arquivo_teste2.txt



= Create a BP to get a file in MinIO (S3 storage)=

    get  http://10.1.1.1:9000  mysfg-bucket-minio arquivo_teste2.txt VQ..rA K4..ge false true  

Other examples you can see here Amazon Web Service Simple Storage Service

= Configure Sterling File Gateway to store files in MinIO (S3 storage)=

1) Generate Obscured Access Key and Obscured Secret Key

In the fields Obscured Access Key and Obscured Secret Key, you must enter the obscure key.

So you need to run the obscure command

/opt/IBM/SterlingIntegrator/bin/obscure_passphrase.sh

2) The EndPointURL

Our minio server is not configured with https, so in the enpoint field I will provide the protocol/address/port.

3) Create a Partner and setup configuration for S3

Important 1: In the fields Obscured Access Key and Obscured Secret Key, you must enter the obscure key.

So you need to run the obscure command

/opt/IBM/SterlingIntegrator/bin/obscure_passphrase.sh

Get the output and fill in that fields

My example:



2) Create a Routing Channel



3) Create a Channel



= Ver também =