tencentcloud.BiDatasource
Explore with Pulumi AI
Provides a resource to create a bi datasource
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const datasource = new tencentcloud.BiDatasource("datasource", {
charset: "utf8",
dbHost: "bj-cdb-1lxqg5r6.sql.tencentcdb.com",
dbName: "tf-test",
dbPort: 63694,
dbPwd: "ABc123,,,",
dbType: "MYSQL",
dbUser: "root",
projectId: 11015030,
sourceName: "tf-source-name",
});
import pulumi
import pulumi_tencentcloud as tencentcloud
datasource = tencentcloud.BiDatasource("datasource",
charset="utf8",
db_host="bj-cdb-1lxqg5r6.sql.tencentcdb.com",
db_name="tf-test",
db_port=63694,
db_pwd="ABc123,,,",
db_type="MYSQL",
db_user="root",
project_id=11015030,
source_name="tf-source-name")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := tencentcloud.NewBiDatasource(ctx, "datasource", &tencentcloud.BiDatasourceArgs{
Charset: pulumi.String("utf8"),
DbHost: pulumi.String("bj-cdb-1lxqg5r6.sql.tencentcdb.com"),
DbName: pulumi.String("tf-test"),
DbPort: pulumi.Float64(63694),
DbPwd: pulumi.String("ABc123,,,"),
DbType: pulumi.String("MYSQL"),
DbUser: pulumi.String("root"),
ProjectId: pulumi.Float64(11015030),
SourceName: pulumi.String("tf-source-name"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() =>
{
var datasource = new Tencentcloud.BiDatasource("datasource", new()
{
Charset = "utf8",
DbHost = "bj-cdb-1lxqg5r6.sql.tencentcdb.com",
DbName = "tf-test",
DbPort = 63694,
DbPwd = "ABc123,,,",
DbType = "MYSQL",
DbUser = "root",
ProjectId = 11015030,
SourceName = "tf-source-name",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.BiDatasource;
import com.pulumi.tencentcloud.BiDatasourceArgs;
import java.util.List;
import java.util.ArrayList;
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) {
var datasource = new BiDatasource("datasource", BiDatasourceArgs.builder()
.charset("utf8")
.dbHost("bj-cdb-1lxqg5r6.sql.tencentcdb.com")
.dbName("tf-test")
.dbPort(63694)
.dbPwd("ABc123,,,")
.dbType("MYSQL")
.dbUser("root")
.projectId(11015030)
.sourceName("tf-source-name")
.build());
}
}
resources:
datasource:
type: tencentcloud:BiDatasource
properties:
charset: utf8
dbHost: bj-cdb-1lxqg5r6.sql.tencentcdb.com
dbName: tf-test
dbPort: 63694
dbPwd: ABc123,,,
dbType: MYSQL
dbUser: root
projectId: 1.101503e+07
sourceName: tf-source-name
Create BiDatasource Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new BiDatasource(name: string, args: BiDatasourceArgs, opts?: CustomResourceOptions);
@overload
def BiDatasource(resource_name: str,
args: BiDatasourceArgs,
opts: Optional[ResourceOptions] = None)
@overload
def BiDatasource(resource_name: str,
opts: Optional[ResourceOptions] = None,
project_id: Optional[float] = None,
db_pwd: Optional[str] = None,
charset: Optional[str] = None,
source_name: Optional[str] = None,
db_user: Optional[str] = None,
db_type: Optional[str] = None,
db_host: Optional[str] = None,
db_name: Optional[str] = None,
db_port: Optional[float] = None,
data_origin_project_id: Optional[str] = None,
catalog: Optional[str] = None,
data_origin_datasource_id: Optional[str] = None,
bi_datasource_id: Optional[str] = None,
service_type: Optional[str] = None,
data_origin: Optional[str] = None,
uniq_vpc_id: Optional[str] = None,
vpc_id: Optional[str] = None)
func NewBiDatasource(ctx *Context, name string, args BiDatasourceArgs, opts ...ResourceOption) (*BiDatasource, error)
public BiDatasource(string name, BiDatasourceArgs args, CustomResourceOptions? opts = null)
public BiDatasource(String name, BiDatasourceArgs args)
public BiDatasource(String name, BiDatasourceArgs args, CustomResourceOptions options)
type: tencentcloud:BiDatasource
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args BiDatasourceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args BiDatasourceArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args BiDatasourceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args BiDatasourceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args BiDatasourceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
BiDatasource Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The BiDatasource resource accepts the following input properties:
- Charset string
- Charset.
- Db
Host string - Host.
- Db
Name string - Database name.
- Db
Port double - Port.
- Db
Pwd string - Password.
- Db
Type string MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- Db
User string - User name.
- Project
Id double - Project id.
- Source
Name string - Datasource name in BI.
- Bi
Datasource stringId - ID of the resource.
- Catalog string
- Catalog.
- Data
Origin string - Third-party datasource identification, this parameter can be ignored.
- Data
Origin stringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- Data
Origin stringProject Id - Third-party datasource project id, this parameter can be ignored.
- Service
Type string - Own or Cloud, default:
Own
. - Uniq
Vpc stringId - Tencent cloud private network unified identity.
- Vpc
Id string - Tencent cloud private network identity.
- Charset string
- Charset.
- Db
Host string - Host.
- Db
Name string - Database name.
- Db
Port float64 - Port.
- Db
Pwd string - Password.
- Db
Type string MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- Db
User string - User name.
- Project
Id float64 - Project id.
- Source
Name string - Datasource name in BI.
- Bi
Datasource stringId - ID of the resource.
- Catalog string
- Catalog.
- Data
Origin string - Third-party datasource identification, this parameter can be ignored.
- Data
Origin stringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- Data
Origin stringProject Id - Third-party datasource project id, this parameter can be ignored.
- Service
Type string - Own or Cloud, default:
Own
. - Uniq
Vpc stringId - Tencent cloud private network unified identity.
- Vpc
Id string - Tencent cloud private network identity.
- charset String
- Charset.
- db
Host String - Host.
- db
Name String - Database name.
- db
Port Double - Port.
- db
Pwd String - Password.
- db
Type String MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- db
User String - User name.
- project
Id Double - Project id.
- source
Name String - Datasource name in BI.
- bi
Datasource StringId - ID of the resource.
- catalog String
- Catalog.
- data
Origin String - Third-party datasource identification, this parameter can be ignored.
- data
Origin StringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- data
Origin StringProject Id - Third-party datasource project id, this parameter can be ignored.
- service
Type String - Own or Cloud, default:
Own
. - uniq
Vpc StringId - Tencent cloud private network unified identity.
- vpc
Id String - Tencent cloud private network identity.
- charset string
- Charset.
- db
Host string - Host.
- db
Name string - Database name.
- db
Port number - Port.
- db
Pwd string - Password.
- db
Type string MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- db
User string - User name.
- project
Id number - Project id.
- source
Name string - Datasource name in BI.
- bi
Datasource stringId - ID of the resource.
- catalog string
- Catalog.
- data
Origin string - Third-party datasource identification, this parameter can be ignored.
- data
Origin stringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- data
Origin stringProject Id - Third-party datasource project id, this parameter can be ignored.
- service
Type string - Own or Cloud, default:
Own
. - uniq
Vpc stringId - Tencent cloud private network unified identity.
- vpc
Id string - Tencent cloud private network identity.
- charset str
- Charset.
- db_
host str - Host.
- db_
name str - Database name.
- db_
port float - Port.
- db_
pwd str - Password.
- db_
type str MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- db_
user str - User name.
- project_
id float - Project id.
- source_
name str - Datasource name in BI.
- bi_
datasource_ strid - ID of the resource.
- catalog str
- Catalog.
- data_
origin str - Third-party datasource identification, this parameter can be ignored.
- data_
origin_ strdatasource_ id - Third-party datasource project id, this parameter can be ignored.
- data_
origin_ strproject_ id - Third-party datasource project id, this parameter can be ignored.
- service_
type str - Own or Cloud, default:
Own
. - uniq_
vpc_ strid - Tencent cloud private network unified identity.
- vpc_
id str - Tencent cloud private network identity.
- charset String
- Charset.
- db
Host String - Host.
- db
Name String - Database name.
- db
Port Number - Port.
- db
Pwd String - Password.
- db
Type String MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- db
User String - User name.
- project
Id Number - Project id.
- source
Name String - Datasource name in BI.
- bi
Datasource StringId - ID of the resource.
- catalog String
- Catalog.
- data
Origin String - Third-party datasource identification, this parameter can be ignored.
- data
Origin StringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- data
Origin StringProject Id - Third-party datasource project id, this parameter can be ignored.
- service
Type String - Own or Cloud, default:
Own
. - uniq
Vpc StringId - Tencent cloud private network unified identity.
- vpc
Id String - Tencent cloud private network identity.
Outputs
All input properties are implicitly available as output properties. Additionally, the BiDatasource resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing BiDatasource Resource
Get an existing BiDatasource resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: BiDatasourceState, opts?: CustomResourceOptions): BiDatasource
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
bi_datasource_id: Optional[str] = None,
catalog: Optional[str] = None,
charset: Optional[str] = None,
data_origin: Optional[str] = None,
data_origin_datasource_id: Optional[str] = None,
data_origin_project_id: Optional[str] = None,
db_host: Optional[str] = None,
db_name: Optional[str] = None,
db_port: Optional[float] = None,
db_pwd: Optional[str] = None,
db_type: Optional[str] = None,
db_user: Optional[str] = None,
project_id: Optional[float] = None,
service_type: Optional[str] = None,
source_name: Optional[str] = None,
uniq_vpc_id: Optional[str] = None,
vpc_id: Optional[str] = None) -> BiDatasource
func GetBiDatasource(ctx *Context, name string, id IDInput, state *BiDatasourceState, opts ...ResourceOption) (*BiDatasource, error)
public static BiDatasource Get(string name, Input<string> id, BiDatasourceState? state, CustomResourceOptions? opts = null)
public static BiDatasource get(String name, Output<String> id, BiDatasourceState state, CustomResourceOptions options)
resources: _: type: tencentcloud:BiDatasource get: id: ${id}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Bi
Datasource stringId - ID of the resource.
- Catalog string
- Catalog.
- Charset string
- Charset.
- Data
Origin string - Third-party datasource identification, this parameter can be ignored.
- Data
Origin stringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- Data
Origin stringProject Id - Third-party datasource project id, this parameter can be ignored.
- Db
Host string - Host.
- Db
Name string - Database name.
- Db
Port double - Port.
- Db
Pwd string - Password.
- Db
Type string MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- Db
User string - User name.
- Project
Id double - Project id.
- Service
Type string - Own or Cloud, default:
Own
. - Source
Name string - Datasource name in BI.
- Uniq
Vpc stringId - Tencent cloud private network unified identity.
- Vpc
Id string - Tencent cloud private network identity.
- Bi
Datasource stringId - ID of the resource.
- Catalog string
- Catalog.
- Charset string
- Charset.
- Data
Origin string - Third-party datasource identification, this parameter can be ignored.
- Data
Origin stringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- Data
Origin stringProject Id - Third-party datasource project id, this parameter can be ignored.
- Db
Host string - Host.
- Db
Name string - Database name.
- Db
Port float64 - Port.
- Db
Pwd string - Password.
- Db
Type string MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- Db
User string - User name.
- Project
Id float64 - Project id.
- Service
Type string - Own or Cloud, default:
Own
. - Source
Name string - Datasource name in BI.
- Uniq
Vpc stringId - Tencent cloud private network unified identity.
- Vpc
Id string - Tencent cloud private network identity.
- bi
Datasource StringId - ID of the resource.
- catalog String
- Catalog.
- charset String
- Charset.
- data
Origin String - Third-party datasource identification, this parameter can be ignored.
- data
Origin StringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- data
Origin StringProject Id - Third-party datasource project id, this parameter can be ignored.
- db
Host String - Host.
- db
Name String - Database name.
- db
Port Double - Port.
- db
Pwd String - Password.
- db
Type String MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- db
User String - User name.
- project
Id Double - Project id.
- service
Type String - Own or Cloud, default:
Own
. - source
Name String - Datasource name in BI.
- uniq
Vpc StringId - Tencent cloud private network unified identity.
- vpc
Id String - Tencent cloud private network identity.
- bi
Datasource stringId - ID of the resource.
- catalog string
- Catalog.
- charset string
- Charset.
- data
Origin string - Third-party datasource identification, this parameter can be ignored.
- data
Origin stringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- data
Origin stringProject Id - Third-party datasource project id, this parameter can be ignored.
- db
Host string - Host.
- db
Name string - Database name.
- db
Port number - Port.
- db
Pwd string - Password.
- db
Type string MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- db
User string - User name.
- project
Id number - Project id.
- service
Type string - Own or Cloud, default:
Own
. - source
Name string - Datasource name in BI.
- uniq
Vpc stringId - Tencent cloud private network unified identity.
- vpc
Id string - Tencent cloud private network identity.
- bi_
datasource_ strid - ID of the resource.
- catalog str
- Catalog.
- charset str
- Charset.
- data_
origin str - Third-party datasource identification, this parameter can be ignored.
- data_
origin_ strdatasource_ id - Third-party datasource project id, this parameter can be ignored.
- data_
origin_ strproject_ id - Third-party datasource project id, this parameter can be ignored.
- db_
host str - Host.
- db_
name str - Database name.
- db_
port float - Port.
- db_
pwd str - Password.
- db_
type str MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- db_
user str - User name.
- project_
id float - Project id.
- service_
type str - Own or Cloud, default:
Own
. - source_
name str - Datasource name in BI.
- uniq_
vpc_ strid - Tencent cloud private network unified identity.
- vpc_
id str - Tencent cloud private network identity.
- bi
Datasource StringId - ID of the resource.
- catalog String
- Catalog.
- charset String
- Charset.
- data
Origin String - Third-party datasource identification, this parameter can be ignored.
- data
Origin StringDatasource Id - Third-party datasource project id, this parameter can be ignored.
- data
Origin StringProject Id - Third-party datasource project id, this parameter can be ignored.
- db
Host String - Host.
- db
Name String - Database name.
- db
Port Number - Port.
- db
Pwd String - Password.
- db
Type String MYSQL
,MSSQL
,POSTGRE
,ORACLE
,CLICKHOUSE
,TIDB
,HIVE
,PRESTO
.- db
User String - User name.
- project
Id Number - Project id.
- service
Type String - Own or Cloud, default:
Own
. - source
Name String - Datasource name in BI.
- uniq
Vpc StringId - Tencent cloud private network unified identity.
- vpc
Id String - Tencent cloud private network identity.
Import
bi datasource can be imported using the id, e.g.
$ pulumi import tencentcloud:index/biDatasource:BiDatasource datasource datasource_id
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- tencentcloud tencentcloudstack/terraform-provider-tencentcloud
- License
- Notes
- This Pulumi package is based on the
tencentcloud
Terraform Provider.