Search in sources :

Example 1 with TalendKinesisProvider

use of org.apache.beam.sdk.io.kinesis.TalendKinesisProvider in project components by Talend.

the class KinesisClient method getProvider.

public static TalendKinesisProvider getProvider(KinesisDatasetProperties dataset) {
    KinesisDatastoreProperties datastore = dataset.getDatastoreProperties();
    String region = dataset.region.getValue().getValue();
    if (KinesisRegion.OTHER.getValue().equals(region)) {
        region = dataset.unknownRegion.getValue();
    }
    return new TalendKinesisProvider(datastore.specifyCredentials.getValue(), datastore.accessKey.getValue(), datastore.secretKey.getValue(), datastore.specifyEndpoint.getValue(), datastore.endpoint.getValue(), Regions.fromName(region), datastore.specifySTS.getValue(), datastore.roleArn.getValue(), datastore.roleSessionName.getValue(), datastore.specifyRoleExternalId.getValue(), datastore.roleExternalId.getValue(), datastore.specifySTSEndpoint.getValue(), datastore.stsEndpoint.getValue());
}
Also used : KinesisDatastoreProperties(org.talend.components.kinesis.KinesisDatastoreProperties) TalendKinesisProvider(org.apache.beam.sdk.io.kinesis.TalendKinesisProvider)

Aggregations

TalendKinesisProvider (org.apache.beam.sdk.io.kinesis.TalendKinesisProvider)1 KinesisDatastoreProperties (org.talend.components.kinesis.KinesisDatastoreProperties)1