Class ConnectorProfile


  • public class ConnectorProfile
    extends com.pulumi.resources.CustomResource
    Provides an AppFlow connector profile resource. For information about AppFlow flows, see the [Amazon AppFlow API Reference](https://docs.aws.amazon.com/appflow/1.0/APIReference/Welcome.html). For specific information about creating an AppFlow connector profile, see the [CreateConnectorProfile](https://docs.aws.amazon.com/appflow/1.0/APIReference/API_CreateConnectorProfile.html) page in the Amazon AppFlow API Reference. ## Example Usage
     
     package generated_program;
     
     import com.pulumi.Context;
     import com.pulumi.Pulumi;
     import com.pulumi.core.Output;
     import com.pulumi.aws.iam.IamFunctions;
     import com.pulumi.aws.iam.inputs.GetPolicyArgs;
     import com.pulumi.aws.iam.Role;
     import com.pulumi.aws.iam.RoleArgs;
     import com.pulumi.aws.s3.Bucket;
     import com.pulumi.aws.s3.BucketArgs;
     import com.pulumi.aws.redshift.Cluster;
     import com.pulumi.aws.redshift.ClusterArgs;
     import com.pulumi.aws.appflow.ConnectorProfile;
     import com.pulumi.aws.appflow.ConnectorProfileArgs;
     import com.pulumi.aws.appflow.inputs.ConnectorProfileConnectorProfileConfigArgs;
     import com.pulumi.aws.appflow.inputs.ConnectorProfileConnectorProfileConfigConnectorProfileCredentialsArgs;
     import com.pulumi.aws.appflow.inputs.ConnectorProfileConnectorProfileConfigConnectorProfileCredentialsRedshiftArgs;
     import com.pulumi.aws.appflow.inputs.ConnectorProfileConnectorProfileConfigConnectorProfilePropertiesArgs;
     import com.pulumi.aws.appflow.inputs.ConnectorProfileConnectorProfileConfigConnectorProfilePropertiesRedshiftArgs;
     import static com.pulumi.codegen.internal.Serialization.*;
     import java.util.ArrayList;
     import java.util.Arrays;
     import java.util.Map;
     import java.io.File;
     import java.nio.file.Files;
     import java.nio.file.Paths;
     
     public class App {
         public static void main(String[] args) {
             Pulumi.run(App::stack);
         }
     
         public static void stack(Context ctx) {
             final var example = IamFunctions.getPolicy(GetPolicyArgs.builder()
                 .name("AmazonRedshiftAllCommandsFullAccess")
                 .build());
     
             var exampleRole = new Role("exampleRole", RoleArgs.builder()
                 .name("example_role")
                 .managedPolicyArns(test.arn())
                 .assumeRolePolicy(serializeJson(
                     jsonObject(
                         jsonProperty("Version", "2012-10-17"),
                         jsonProperty("Statement", jsonArray(jsonObject(
                             jsonProperty("Action", "sts:AssumeRole"),
                             jsonProperty("Effect", "Allow"),
                             jsonProperty("Sid", ""),
                             jsonProperty("Principal", jsonObject(
                                 jsonProperty("Service", "ec2.amazonaws.com")
                             ))
                         )))
                     )))
                 .build());
     
             var exampleBucket = new Bucket("exampleBucket", BucketArgs.builder()
                 .bucket("example-bucket")
                 .build());
     
             var exampleCluster = new Cluster("exampleCluster", ClusterArgs.builder()
                 .clusterIdentifier("example_cluster")
                 .databaseName("example_db")
                 .masterUsername("exampleuser")
                 .masterPassword("examplePassword123!")
                 .nodeType("dc1.large")
                 .clusterType("single-node")
                 .build());
     
             var exampleConnectorProfile = new ConnectorProfile("exampleConnectorProfile", ConnectorProfileArgs.builder()
                 .connectorProfileConfig(ConnectorProfileConnectorProfileConfigArgs.builder()
                     .connectorProfileCredentials(ConnectorProfileConnectorProfileConfigConnectorProfileCredentialsArgs.builder()
                         .redshift(ConnectorProfileConnectorProfileConfigConnectorProfileCredentialsRedshiftArgs.builder()
                             .password(exampleCluster.masterPassword())
                             .username(exampleCluster.masterUsername())
                             .build())
                         .build())
                     .connectorProfileProperties(ConnectorProfileConnectorProfileConfigConnectorProfilePropertiesArgs.builder()
                         .redshift(ConnectorProfileConnectorProfileConfigConnectorProfilePropertiesRedshiftArgs.builder()
                             .bucketName(exampleBucket.name())
                             .databaseUrl(Output.tuple(exampleCluster.endpoint(), exampleCluster.databaseName()).applyValue(values -> {
                                 var endpoint = values.t1;
                                 var databaseName = values.t2;
                                 return String.format("jdbc:redshift://%s/%s", endpoint,databaseName);
                             }))
                             .roleArn(exampleRole.arn())
                             .build())
                         .build())
                     .build())
                 .name("example_profile")
                 .connectorType("Redshift")
                 .connectionMode("Public")
                 .build());
     
         }
     }
     
     
    ## Import ### Identity Schema #### Required * `name` (String) Name of the AppFlow connector profile. #### Optional * `accountId` (String) AWS Account where this resource is managed. * `region` (String) Region where this resource is managed. Using `pulumi import`, import AppFlow Connector Profile using the connector profile `name`. For example: ```sh $ pulumi import aws:appflow/connectorProfile:ConnectorProfile example example-profile ```
    • Nested Class Summary

      • Nested classes/interfaces inherited from class com.pulumi.resources.CustomResource

        com.pulumi.resources.CustomResource.CustomResourceInternal
      • Nested classes/interfaces inherited from class com.pulumi.resources.Resource

        com.pulumi.resources.Resource.LazyField<T extends java.lang.Object>, com.pulumi.resources.Resource.LazyFields, com.pulumi.resources.Resource.ResourceInternal
    • Field Summary

      • Fields inherited from class com.pulumi.resources.Resource

        childResources, remote
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      com.pulumi.core.Output<java.lang.String> arn()  
      com.pulumi.core.Output<java.lang.String> connectionMode()  
      com.pulumi.core.Output<java.util.Optional<java.lang.String>> connectorLabel()  
      com.pulumi.core.Output<ConnectorProfileConnectorProfileConfig> connectorProfileConfig()  
      com.pulumi.core.Output<java.lang.String> connectorType()  
      com.pulumi.core.Output<java.lang.String> credentialsArn()  
      static ConnectorProfile get​(java.lang.String name, com.pulumi.core.Output<java.lang.String> id, ConnectorProfileState state, com.pulumi.resources.CustomResourceOptions options)
      Get an existing Host resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
      com.pulumi.core.Output<java.lang.String> kmsArn()  
      com.pulumi.core.Output<java.lang.String> name()  
      com.pulumi.core.Output<java.lang.String> region()  
      • Methods inherited from class com.pulumi.resources.CustomResource

        getId, id, idFuture
      • Methods inherited from class com.pulumi.resources.Resource

        getChildResources, getResourceName, getResourceType, getUrn, pulumiChildResources, pulumiResourceName, pulumiResourceType, urn
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ConnectorProfile

        public ConnectorProfile​(java.lang.String name)
        Parameters:
        name - The _unique_ name of the resulting resource.
      • ConnectorProfile

        public ConnectorProfile​(java.lang.String name,
                                ConnectorProfileArgs args)
        Parameters:
        name - The _unique_ name of the resulting resource.
        args - The arguments to use to populate this resource's properties.
      • ConnectorProfile

        public ConnectorProfile​(java.lang.String name,
                                ConnectorProfileArgs args,
                                @Nullable
                                com.pulumi.resources.CustomResourceOptions options)
        Parameters:
        name - The _unique_ name of the resulting resource.
        args - The arguments to use to populate this resource's properties.
        options - A bag of options that control this resource's behavior.
    • Method Detail

      • arn

        public com.pulumi.core.Output<java.lang.String> arn()
        Returns:
        ARN of the connector profile.
      • connectionMode

        public com.pulumi.core.Output<java.lang.String> connectionMode()
        Returns:
        Connection mode and specifies whether it is public or private. Private flows use AWS PrivateLink to route data over AWS infrastructure without exposing it to the public internet. One of: `Public`, `Private`.
      • connectorLabel

        public com.pulumi.core.Output<java.util.Optional<java.lang.String>> connectorLabel()
        Returns:
        Label of the connector. The label is unique for each `ConnectorRegistration` in your AWS account. Only needed if calling for the `CustomConnector` connector type.
      • connectorProfileConfig

        public com.pulumi.core.Output<ConnectorProfileConnectorProfileConfig> connectorProfileConfig()
        Returns:
        Connector-specific configuration and credentials. See `connectorProfileConfig` Block for details.
      • connectorType

        public com.pulumi.core.Output<java.lang.String> connectorType()
        Returns:
        Type of connector. One of: `Amplitude`, `CustomConnector`, `CustomerProfiles`, `Datadog`, `Dynatrace`, `EventBridge`, `Googleanalytics`, `Honeycode`, `Infornexus`, `LookoutMetrics`, `Marketo`, `Redshift`, `S3`, `Salesforce`, `SAPOData`, `Servicenow`, `Singular`, `Slack`, `Snowflake`, `Trendmicro`, `Upsolver`, `Veeva`, `Zendesk`.
      • credentialsArn

        public com.pulumi.core.Output<java.lang.String> credentialsArn()
        Returns:
        ARN of the connector profile credentials.
      • kmsArn

        public com.pulumi.core.Output<java.lang.String> kmsArn()
        Returns:
        ARN of the KMS key you provide for encryption. This is required if you do not want to use the Amazon AppFlow-managed KMS key. If you don't provide anything here, Amazon AppFlow uses the Amazon AppFlow-managed KMS key.
      • name

        public com.pulumi.core.Output<java.lang.String> name()
        Returns:
        Name of the connector profile. The name is unique for each `ConnectorProfile` in your AWS account.
      • region

        public com.pulumi.core.Output<java.lang.String> region()
        Returns:
        Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
      • get

        public static ConnectorProfile get​(java.lang.String name,
                                           com.pulumi.core.Output<java.lang.String> id,
                                           @Nullable
                                           ConnectorProfileState state,
                                           @Nullable
                                           com.pulumi.resources.CustomResourceOptions options)
        Get an existing Host resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
        Parameters:
        name - The _unique_ name of the resulting resource.
        id - The _unique_ provider ID of the resource to lookup.
        state -
        options - Optional settings to control the behavior of the CustomResource.