Datastream service v1alpha1
Package
@google-cloud/datastream
Constructors
(constructor)(opts, gaxInstance)
constructor(opts?: ClientOptions, gaxInstance?: typeof gax | typeof gax.fallback);
Construct an instance of DatastreamClient.
Parameters |
Name |
Description |
opts |
ClientOptions
|
gaxInstance |
typeof gax | typeof fallback
: loaded instance of google-gax . Useful if you need to avoid loading the default gRPC version and want to use the fallback HTTP implementation. Load only fallback version and pass it to the constructor: ``` const gax = require('google-gax/build/src/fallback'); // avoids loading google-gax with gRPC const client = new DatastreamClient({fallback: true}, gax); ```
|
Properties
apiEndpoint
get apiEndpoint(): string;
The DNS address for this API service.
apiEndpoint
static get apiEndpoint(): string;
The DNS address for this API service - same as servicePath.
auth
datastreamStub
datastreamStub?: Promise<{
[name: string]: Function;
}>;
descriptors
descriptors: Descriptors;
innerApiCalls
innerApiCalls: {
[name: string]: Function;
};
operationsClient
operationsClient: gax.OperationsClient;
pathTemplates
pathTemplates: {
[name: string]: gax.PathTemplate;
};
port
static get port(): number;
The port for this API service.
scopes
static get scopes(): string[];
The scopes needed to make gRPC calls for every method defined in this service.
servicePath
static get servicePath(): string;
The DNS address for this API service.
universeDomain
get universeDomain(): string;
warn
warn: (code: string, message: string, warnType?: string) => void;
Methods
checkCreateConnectionProfileProgress(name)
checkCreateConnectionProfileProgress(name: string): Promise<LROperation<protos.google.cloud.datastream.v1alpha1.ConnectionProfile, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by createConnectionProfile()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The parent that owns the collection of ConnectionProfiles.
*/
// const parent = 'abc123'
/**
* Required. The connection profile identifier.
*/
// const connectionProfileId = 'abc123'
/**
* Required. The connection profile resource to create.
*/
// const connectionProfile = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callCreateConnectionProfile() {
// Construct request
const request = {
parent,
connectionProfileId,
connectionProfile,
};
// Run request
const [operation] = await datastreamClient.createConnectionProfile(request);
const [response] = await operation.promise();
console.log(response);
}
callCreateConnectionProfile();
checkCreatePrivateConnectionProgress(name)
checkCreatePrivateConnectionProgress(name: string): Promise<LROperation<protos.google.cloud.datastream.v1alpha1.PrivateConnection, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by createPrivateConnection()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The parent that owns the collection of PrivateConnections.
*/
// const parent = 'abc123'
/**
* Required. The private connectivity identifier.
*/
// const privateConnectionId = 'abc123'
/**
* Required. The Private Connectivity resource to create.
*/
// const privateConnection = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callCreatePrivateConnection() {
// Construct request
const request = {
parent,
privateConnectionId,
privateConnection,
};
// Run request
const [operation] = await datastreamClient.createPrivateConnection(request);
const [response] = await operation.promise();
console.log(response);
}
callCreatePrivateConnection();
checkCreateRouteProgress(name)
checkCreateRouteProgress(name: string): Promise<LROperation<protos.google.cloud.datastream.v1alpha1.Route, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by createRoute()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The parent that owns the collection of Routes.
*/
// const parent = 'abc123'
/**
* Required. The Route identifier.
*/
// const routeId = 'abc123'
/**
* Required. The Route resource to create.
*/
// const route = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callCreateRoute() {
// Construct request
const request = {
parent,
routeId,
route,
};
// Run request
const [operation] = await datastreamClient.createRoute(request);
const [response] = await operation.promise();
console.log(response);
}
callCreateRoute();
checkCreateStreamProgress(name)
checkCreateStreamProgress(name: string): Promise<LROperation<protos.google.cloud.datastream.v1alpha1.Stream, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by createStream()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The parent that owns the collection of streams.
*/
// const parent = 'abc123'
/**
* Required. The stream identifier.
*/
// const streamId = 'abc123'
/**
* Required. The stream resource to create.
*/
// const stream = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
/**
* Optional. Only validate the stream, but do not create any resources.
* The default is false.
*/
// const validateOnly = true
/**
* Optional. Create the stream without validating it.
*/
// const force = true
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callCreateStream() {
// Construct request
const request = {
parent,
streamId,
stream,
};
// Run request
const [operation] = await datastreamClient.createStream(request);
const [response] = await operation.promise();
console.log(response);
}
callCreateStream();
checkDeleteConnectionProfileProgress(name)
checkDeleteConnectionProfileProgress(name: string): Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by deleteConnectionProfile()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the connection profile resource to delete.
*/
// const name = 'abc123'
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes after the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callDeleteConnectionProfile() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await datastreamClient.deleteConnectionProfile(request);
const [response] = await operation.promise();
console.log(response);
}
callDeleteConnectionProfile();
checkDeletePrivateConnectionProgress(name)
checkDeletePrivateConnectionProgress(name: string): Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by deletePrivateConnection()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the private connectivity configuration to delete.
*/
// const name = 'abc123'
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes after the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
/**
* Optional. If set to true, any child routes that belong to this PrivateConnection will
* also be deleted.
*/
// const force = true
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callDeletePrivateConnection() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await datastreamClient.deletePrivateConnection(request);
const [response] = await operation.promise();
console.log(response);
}
callDeletePrivateConnection();
checkDeleteRouteProgress(name)
checkDeleteRouteProgress(name: string): Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by deleteRoute()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the Route resource to delete.
*/
// const name = 'abc123'
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes after the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callDeleteRoute() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await datastreamClient.deleteRoute(request);
const [response] = await operation.promise();
console.log(response);
}
callDeleteRoute();
checkDeleteStreamProgress(name)
checkDeleteStreamProgress(name: string): Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by deleteStream()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the stream resource to delete.
*/
// const name = 'abc123'
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes after the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callDeleteStream() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await datastreamClient.deleteStream(request);
const [response] = await operation.promise();
console.log(response);
}
callDeleteStream();
checkFetchErrorsProgress(name)
checkFetchErrorsProgress(name: string): Promise<LROperation<protos.google.cloud.datastream.v1alpha1.FetchErrorsResponse, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by fetchErrors()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Name of the Stream resource for which to fetch any errors.
*/
// const stream = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callFetchErrors() {
// Construct request
const request = {
};
// Run request
const [operation] = await datastreamClient.fetchErrors(request);
const [response] = await operation.promise();
console.log(response);
}
callFetchErrors();
checkUpdateConnectionProfileProgress(name)
checkUpdateConnectionProfileProgress(name: string): Promise<LROperation<protos.google.cloud.datastream.v1alpha1.ConnectionProfile, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by updateConnectionProfile()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Optional. Field mask is used to specify the fields to be overwritten in the
* ConnectionProfile resource by the update.
* The fields specified in the update_mask are relative to the resource, not
* the full request. A field will be overwritten if it is in the mask. If the
* user does not provide a mask then all fields will be overwritten.
*/
// const updateMask = {}
/**
* Required. The ConnectionProfile to update.
*/
// const connectionProfile = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callUpdateConnectionProfile() {
// Construct request
const request = {
connectionProfile,
};
// Run request
const [operation] = await datastreamClient.updateConnectionProfile(request);
const [response] = await operation.promise();
console.log(response);
}
callUpdateConnectionProfile();
checkUpdateStreamProgress(name)
checkUpdateStreamProgress(name: string): Promise<LROperation<protos.google.cloud.datastream.v1alpha1.Stream, protos.google.cloud.datastream.v1alpha1.OperationMetadata>>;
Check the status of the long running operation returned by updateStream()
.
Parameter |
Name |
Description |
name |
string
The operation name that will be passed.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Optional. Field mask is used to specify the fields to be overwritten in the
* stream resource by the update.
* The fields specified in the update_mask are relative to the resource, not
* the full request. A field will be overwritten if it is in the mask. If the
* user does not provide a mask then all fields will be overwritten.
*/
// const updateMask = {}
/**
* Required. The stream resource to update.
*/
// const stream = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
/**
* Optional. Only validate the stream with the changes, without actually updating it.
* The default is false.
*/
// const validateOnly = true
/**
* Optional. Execute the update without validating it.
*/
// const force = true
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callUpdateStream() {
// Construct request
const request = {
stream,
};
// Run request
const [operation] = await datastreamClient.updateStream(request);
const [response] = await operation.promise();
console.log(response);
}
callUpdateStream();
close()
Terminate the gRPC channel and close the client.
The client will no longer be usable and all future behavior is undefined.
Returns |
Type |
Description |
Promise<void> |
{Promise} A promise that resolves when the client is closed.
|
connectionProfilePath(project, location, connectionProfile)
connectionProfilePath(project: string, location: string, connectionProfile: string): string;
Return a fully-qualified connectionProfile resource name string.
Parameters |
Name |
Description |
project |
string
|
location |
string
|
connectionProfile |
string
|
Returns |
Type |
Description |
string |
{string} Resource name string.
|
createConnectionProfile(request, options)
createConnectionProfile(request?: protos.google.cloud.datastream.v1alpha1.ICreateConnectionProfileRequest, options?: CallOptions): Promise<[
LROperation<protos.google.cloud.datastream.v1alpha1.IConnectionProfile, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Use this method to create a connection profile in a project and location.
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The parent that owns the collection of ConnectionProfiles.
*/
// const parent = 'abc123'
/**
* Required. The connection profile identifier.
*/
// const connectionProfileId = 'abc123'
/**
* Required. The connection profile resource to create.
*/
// const connectionProfile = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callCreateConnectionProfile() {
// Construct request
const request = {
parent,
connectionProfileId,
connectionProfile,
};
// Run request
const [operation] = await datastreamClient.createConnectionProfile(request);
const [response] = await operation.promise();
console.log(response);
}
callCreateConnectionProfile();
createConnectionProfile(request, options, callback)
createConnectionProfile(request: protos.google.cloud.datastream.v1alpha1.ICreateConnectionProfileRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IConnectionProfile, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
createConnectionProfile(request, callback)
createConnectionProfile(request: protos.google.cloud.datastream.v1alpha1.ICreateConnectionProfileRequest, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IConnectionProfile, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
createPrivateConnection(request, options)
createPrivateConnection(request?: protos.google.cloud.datastream.v1alpha1.ICreatePrivateConnectionRequest, options?: CallOptions): Promise<[
LROperation<protos.google.cloud.datastream.v1alpha1.IPrivateConnection, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Use this method to create a private connectivity configuration.
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The parent that owns the collection of PrivateConnections.
*/
// const parent = 'abc123'
/**
* Required. The private connectivity identifier.
*/
// const privateConnectionId = 'abc123'
/**
* Required. The Private Connectivity resource to create.
*/
// const privateConnection = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callCreatePrivateConnection() {
// Construct request
const request = {
parent,
privateConnectionId,
privateConnection,
};
// Run request
const [operation] = await datastreamClient.createPrivateConnection(request);
const [response] = await operation.promise();
console.log(response);
}
callCreatePrivateConnection();
createPrivateConnection(request, options, callback)
createPrivateConnection(request: protos.google.cloud.datastream.v1alpha1.ICreatePrivateConnectionRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IPrivateConnection, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
createPrivateConnection(request, callback)
createPrivateConnection(request: protos.google.cloud.datastream.v1alpha1.ICreatePrivateConnectionRequest, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IPrivateConnection, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
createRoute(request, options)
createRoute(request?: protos.google.cloud.datastream.v1alpha1.ICreateRouteRequest, options?: CallOptions): Promise<[
LROperation<protos.google.cloud.datastream.v1alpha1.IRoute, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Use this method to create a route for a private connectivity in a project and location.
Parameters |
Name |
Description |
request |
ICreateRouteRequest
The request object that will be sent.
|
options |
CallOptions
Call options. See CallOptions for more details.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The parent that owns the collection of Routes.
*/
// const parent = 'abc123'
/**
* Required. The Route identifier.
*/
// const routeId = 'abc123'
/**
* Required. The Route resource to create.
*/
// const route = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callCreateRoute() {
// Construct request
const request = {
parent,
routeId,
route,
};
// Run request
const [operation] = await datastreamClient.createRoute(request);
const [response] = await operation.promise();
console.log(response);
}
callCreateRoute();
createRoute(request, options, callback)
createRoute(request: protos.google.cloud.datastream.v1alpha1.ICreateRouteRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IRoute, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
createRoute(request, callback)
createRoute(request: protos.google.cloud.datastream.v1alpha1.ICreateRouteRequest, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IRoute, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
createStream(request, options)
createStream(request?: protos.google.cloud.datastream.v1alpha1.ICreateStreamRequest, options?: CallOptions): Promise<[
LROperation<protos.google.cloud.datastream.v1alpha1.IStream, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Use this method to create a stream.
Parameters |
Name |
Description |
request |
ICreateStreamRequest
The request object that will be sent.
|
options |
CallOptions
Call options. See CallOptions for more details.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The parent that owns the collection of streams.
*/
// const parent = 'abc123'
/**
* Required. The stream identifier.
*/
// const streamId = 'abc123'
/**
* Required. The stream resource to create.
*/
// const stream = {}
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes since the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
/**
* Optional. Only validate the stream, but do not create any resources.
* The default is false.
*/
// const validateOnly = true
/**
* Optional. Create the stream without validating it.
*/
// const force = true
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callCreateStream() {
// Construct request
const request = {
parent,
streamId,
stream,
};
// Run request
const [operation] = await datastreamClient.createStream(request);
const [response] = await operation.promise();
console.log(response);
}
callCreateStream();
createStream(request, options, callback)
createStream(request: protos.google.cloud.datastream.v1alpha1.ICreateStreamRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IStream, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
createStream(request, callback)
createStream(request: protos.google.cloud.datastream.v1alpha1.ICreateStreamRequest, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IStream, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
deleteConnectionProfile(request, options)
deleteConnectionProfile(request?: protos.google.cloud.datastream.v1alpha1.IDeleteConnectionProfileRequest, options?: CallOptions): Promise<[
LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Use this method to delete a connection profile..
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the connection profile resource to delete.
*/
// const name = 'abc123'
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes after the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callDeleteConnectionProfile() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await datastreamClient.deleteConnectionProfile(request);
const [response] = await operation.promise();
console.log(response);
}
callDeleteConnectionProfile();
deleteConnectionProfile(request, options, callback)
deleteConnectionProfile(request: protos.google.cloud.datastream.v1alpha1.IDeleteConnectionProfileRequest, options: CallOptions, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
deleteConnectionProfile(request, callback)
deleteConnectionProfile(request: protos.google.cloud.datastream.v1alpha1.IDeleteConnectionProfileRequest, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
deletePrivateConnection(request, options)
deletePrivateConnection(request?: protos.google.cloud.datastream.v1alpha1.IDeletePrivateConnectionRequest, options?: CallOptions): Promise<[
LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Use this method to delete a private connectivity configuration.
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the private connectivity configuration to delete.
*/
// const name = 'abc123'
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes after the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
/**
* Optional. If set to true, any child routes that belong to this PrivateConnection will
* also be deleted.
*/
// const force = true
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callDeletePrivateConnection() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await datastreamClient.deletePrivateConnection(request);
const [response] = await operation.promise();
console.log(response);
}
callDeletePrivateConnection();
deletePrivateConnection(request, options, callback)
deletePrivateConnection(request: protos.google.cloud.datastream.v1alpha1.IDeletePrivateConnectionRequest, options: CallOptions, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
deletePrivateConnection(request, callback)
deletePrivateConnection(request: protos.google.cloud.datastream.v1alpha1.IDeletePrivateConnectionRequest, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
deleteRoute(request, options)
deleteRoute(request?: protos.google.cloud.datastream.v1alpha1.IDeleteRouteRequest, options?: CallOptions): Promise<[
LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Use this method to delete a route.
Parameters |
Name |
Description |
request |
IDeleteRouteRequest
The request object that will be sent.
|
options |
CallOptions
Call options. See CallOptions for more details.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the Route resource to delete.
*/
// const name = 'abc123'
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes after the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callDeleteRoute() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await datastreamClient.deleteRoute(request);
const [response] = await operation.promise();
console.log(response);
}
callDeleteRoute();
deleteRoute(request, options, callback)
deleteRoute(request: protos.google.cloud.datastream.v1alpha1.IDeleteRouteRequest, options: CallOptions, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
deleteRoute(request, callback)
deleteRoute(request: protos.google.cloud.datastream.v1alpha1.IDeleteRouteRequest, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
deleteStream(request, options)
deleteStream(request?: protos.google.cloud.datastream.v1alpha1.IDeleteStreamRequest, options?: CallOptions): Promise<[
LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Use this method to delete a stream.
Parameters |
Name |
Description |
request |
IDeleteStreamRequest
The request object that will be sent.
|
options |
CallOptions
Call options. See CallOptions for more details.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the stream resource to delete.
*/
// const name = 'abc123'
/**
* Optional. A request ID to identify requests. Specify a unique request ID
* so that if you must retry your request, the server will know to ignore
* the request if it has already been completed. The server will guarantee
* that for at least 60 minutes after the first request.
* For example, consider a situation where you make an initial request and the
* request times out. If you make the request again with the same request ID,
* the server can check if original operation with the same request ID was
* received, and if so, will ignore the second request. This prevents clients
* from accidentally creating duplicate commitments.
* The request ID must be a valid UUID with the exception that zero UUID is
* not supported (00000000-0000-0000-0000-000000000000).
*/
// const requestId = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callDeleteStream() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await datastreamClient.deleteStream(request);
const [response] = await operation.promise();
console.log(response);
}
callDeleteStream();
deleteStream(request, options, callback)
deleteStream(request: protos.google.cloud.datastream.v1alpha1.IDeleteStreamRequest, options: CallOptions, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
deleteStream(request, callback)
deleteStream(request: protos.google.cloud.datastream.v1alpha1.IDeleteStreamRequest, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
discoverConnectionProfile(request, options)
discoverConnectionProfile(request?: protos.google.cloud.datastream.v1alpha1.IDiscoverConnectionProfileRequest, options?: CallOptions): Promise<[
protos.google.cloud.datastream.v1alpha1.IDiscoverConnectionProfileResponse,
(protos.google.cloud.datastream.v1alpha1.IDiscoverConnectionProfileRequest | undefined),
{} | undefined
]>;
Use this method to discover a connection profile. The discover API call exposes the data objects and metadata belonging to the profile. Typically, a request returns children data objects under a parent data object that's optionally supplied in the request.
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The parent resource of the ConnectionProfile type. Must be in the
* format `projects/* /locations/*`.
*/
// const parent = 'abc123'
/**
* An ad-hoc ConnectionProfile configuration.
*/
// const connectionProfile = {}
/**
* A reference to an existing ConnectionProfile.
*/
// const connectionProfileName = 'abc123'
/**
* Whether to retrieve the full hierarchy of data objects (TRUE) or only the
* current level (FALSE).
*/
// const recursive = true
/**
* The number of hierarchy levels below the current level to be retrieved.
*/
// const recursionDepth = 1234
/**
* Oracle RDBMS to enrich with child data objects and metadata.
*/
// const oracleRdbms = {}
/**
* MySQL RDBMS to enrich with child data objects and metadata.
*/
// const mysqlRdbms = {}
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callDiscoverConnectionProfile() {
// Construct request
const request = {
parent,
};
// Run request
const response = await datastreamClient.discoverConnectionProfile(request);
console.log(response);
}
callDiscoverConnectionProfile();
discoverConnectionProfile(request, options, callback)
discoverConnectionProfile(request: protos.google.cloud.datastream.v1alpha1.IDiscoverConnectionProfileRequest, options: CallOptions, callback: Callback<protos.google.cloud.datastream.v1alpha1.IDiscoverConnectionProfileResponse, protos.google.cloud.datastream.v1alpha1.IDiscoverConnectionProfileRequest | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
discoverConnectionProfile(request, callback)
discoverConnectionProfile(request: protos.google.cloud.datastream.v1alpha1.IDiscoverConnectionProfileRequest, callback: Callback<protos.google.cloud.datastream.v1alpha1.IDiscoverConnectionProfileResponse, protos.google.cloud.datastream.v1alpha1.IDiscoverConnectionProfileRequest | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
fetchErrors(request, options)
fetchErrors(request?: protos.google.cloud.datastream.v1alpha1.IFetchErrorsRequest, options?: CallOptions): Promise<[
LROperation<protos.google.cloud.datastream.v1alpha1.IFetchErrorsResponse, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Use this method to fetch any errors associated with a stream.
Parameters |
Name |
Description |
request |
IFetchErrorsRequest
The request object that will be sent.
|
options |
CallOptions
Call options. See CallOptions for more details.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Name of the Stream resource for which to fetch any errors.
*/
// const stream = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callFetchErrors() {
// Construct request
const request = {
};
// Run request
const [operation] = await datastreamClient.fetchErrors(request);
const [response] = await operation.promise();
console.log(response);
}
callFetchErrors();
fetchErrors(request, options, callback)
fetchErrors(request: protos.google.cloud.datastream.v1alpha1.IFetchErrorsRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IFetchErrorsResponse, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
fetchErrors(request, callback)
fetchErrors(request: protos.google.cloud.datastream.v1alpha1.IFetchErrorsRequest, callback: Callback<LROperation<protos.google.cloud.datastream.v1alpha1.IFetchErrorsResponse, protos.google.cloud.datastream.v1alpha1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
fetchStaticIps(request, options)
fetchStaticIps(request?: protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsRequest, options?: CallOptions): Promise<[
string[],
protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsRequest | null,
protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsResponse
]>;
The FetchStaticIps API call exposes the static ips used by Datastream. Typically, a request returns children data objects under a parent data object that's optionally supplied in the request.
fetchStaticIps(request, options, callback)
fetchStaticIps(request: protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsRequest, options: CallOptions, callback: PaginationCallback<protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsRequest, protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsResponse | null | undefined, string>): void;
Returns |
Type |
Description |
void |
|
fetchStaticIps(request, callback)
fetchStaticIps(request: protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsRequest, callback: PaginationCallback<protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsRequest, protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsResponse | null | undefined, string>): void;
Returns |
Type |
Description |
void |
|
fetchStaticIpsAsync(request, options)
fetchStaticIpsAsync(request?: protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsRequest, options?: CallOptions): AsyncIterable<string>;
Equivalent to fetchStaticIps
, but returns an iterable object.
for
-await
-of
syntax is used with the iterable to get response elements on-demand.
Returns |
Type |
Description |
AsyncIterable<string> |
{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing string. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name resource of the Response type. Must be in the
* format `projects/* /locations/*`.
*/
// const name = 'abc123'
/**
* Maximum number of Ips to return, will likely not be specified.
*/
// const pageSize = 1234
/**
* A page token, received from a previous `ListStaticIps` call.
* will likely not be specified.
*/
// const pageToken = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callFetchStaticIps() {
// Construct request
const request = {
name,
};
// Run request
const iterable = datastreamClient.fetchStaticIpsAsync(request);
for await (const response of iterable) {
console.log(response);
}
}
callFetchStaticIps();
fetchStaticIpsStream(request, options)
fetchStaticIpsStream(request?: protos.google.cloud.datastream.v1alpha1.IFetchStaticIpsRequest, options?: CallOptions): Transform;
Equivalent to method.name.toCamelCase()
, but returns a NodeJS Stream object.
Returns |
Type |
Description |
Transform |
{Stream} An object stream which emits an object representing string on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using fetchStaticIpsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.
|
getConnectionProfile(request, options)
getConnectionProfile(request?: protos.google.cloud.datastream.v1alpha1.IGetConnectionProfileRequest, options?: CallOptions): Promise<[
protos.google.cloud.datastream.v1alpha1.IConnectionProfile,
(protos.google.cloud.datastream.v1alpha1.IGetConnectionProfileRequest | undefined),
{} | undefined
]>;
Use this method to get details about a connection profile.
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the connection profile resource to get.
*/
// const name = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callGetConnectionProfile() {
// Construct request
const request = {
name,
};
// Run request
const response = await datastreamClient.getConnectionProfile(request);
console.log(response);
}
callGetConnectionProfile();
getConnectionProfile(request, options, callback)
getConnectionProfile(request: protos.google.cloud.datastream.v1alpha1.IGetConnectionProfileRequest, options: CallOptions, callback: Callback<protos.google.cloud.datastream.v1alpha1.IConnectionProfile, protos.google.cloud.datastream.v1alpha1.IGetConnectionProfileRequest | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
getConnectionProfile(request, callback)
getConnectionProfile(request: protos.google.cloud.datastream.v1alpha1.IGetConnectionProfileRequest, callback: Callback<protos.google.cloud.datastream.v1alpha1.IConnectionProfile, protos.google.cloud.datastream.v1alpha1.IGetConnectionProfileRequest | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
getPrivateConnection(request, options)
getPrivateConnection(request?: protos.google.cloud.datastream.v1alpha1.IGetPrivateConnectionRequest, options?: CallOptions): Promise<[
protos.google.cloud.datastream.v1alpha1.IPrivateConnection,
(protos.google.cloud.datastream.v1alpha1.IGetPrivateConnectionRequest | undefined),
{} | undefined
]>;
Use this method to get details about a private connectivity configuration.
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the private connectivity configuration to get.
*/
// const name = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callGetPrivateConnection() {
// Construct request
const request = {
name,
};
// Run request
const response = await datastreamClient.getPrivateConnection(request);
console.log(response);
}
callGetPrivateConnection();
getPrivateConnection(request, options, callback)
getPrivateConnection(request: protos.google.cloud.datastream.v1alpha1.IGetPrivateConnectionRequest, options: CallOptions, callback: Callback<protos.google.cloud.datastream.v1alpha1.IPrivateConnection, protos.google.cloud.datastream.v1alpha1.IGetPrivateConnectionRequest | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
getPrivateConnection(request, callback)
getPrivateConnection(request: protos.google.cloud.datastream.v1alpha1.IGetPrivateConnectionRequest, callback: Callback<protos.google.cloud.datastream.v1alpha1.IPrivateConnection, protos.google.cloud.datastream.v1alpha1.IGetPrivateConnectionRequest | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
getProjectId()
getProjectId(): Promise<string>;
Returns |
Type |
Description |
Promise<string> |
|
getProjectId(callback)
getProjectId(callback: Callback<string, undefined, undefined>): void;
Parameter |
Name |
Description |
callback |
Callback<string, undefined, undefined>
|
Returns |
Type |
Description |
void |
|
getRoute(request, options)
getRoute(request?: protos.google.cloud.datastream.v1alpha1.IGetRouteRequest, options?: CallOptions): Promise<[
protos.google.cloud.datastream.v1alpha1.IRoute,
protos.google.cloud.datastream.v1alpha1.IGetRouteRequest | undefined,
{} | undefined
]>;
Use this method to get details about a route.
Parameters |
Name |
Description |
request |
IGetRouteRequest
The request object that will be sent.
|
options |
CallOptions
Call options. See CallOptions for more details.
|
Example
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the Route resource to get.
*/
// const name = 'abc123'
// Imports the Datastream library
const {DatastreamClient} = require('@google-cloud/datastream').v1alpha1;
// Instantiates a client
const datastreamClient = new DatastreamClient();
async function callGetRoute() {
// Construct request
const request = {
name,
};
// Run request
const response = await datastreamClient.getRoute(request);
console.log(response);
}
callGetRoute();
getRoute(request, options, callback)
getRoute(request: protos.google.cloud.datastream.v1alpha1.IGetRouteRequest, options: CallOptions, callback: Callback<protos.google.cloud.datastream.v1alpha1.IRoute, protos.google.cloud.datastream.v1alpha1.IGetRouteRequest | null | undefined, {} | null | undefined>): void;
Returns |
Type |
Description |
void |
|
getRoute(request, callback)