- Module for inline implementation of Pulumi Resource's CRUD operations.
- Part of the
@pulumi/pulumi
package.
new Resource(provider, name, props, opts?, module?, type)
- provider: CRUD operations implementation.
- name: Resource name.
- props: Arguments to populate the new resource.
- opts: Options bag.
- module: Resource module.
- type: Resource type.
- Methods:
getProvider(moduleMember: string)
: Returns ProviderResource or undefined.isInstance(obj: any)
: Checks if object is an instance of CustomResource.
- Properties:
id
: Provider-assigned unique ID.urn
: Stable logical URN.
property
: Property that failed validation.reason
: Reason for failure.
failures
: Array of CheckFailure.inputs
: Inputs to use.
id
: ID of the created resource.outs
: Properties computed during creation.
changes
: Indicates if update is needed.deleteBeforeReplace
: Indicates if deletion is needed before replacement.replaces
: Properties triggering replacement.stables
: Properties that will not change.
id
: ID of the resource read back.props
: Current property state.
- Methods:
check(olds, news)
: Validates property bag.create(inputs)
: Allocates new resource instance.delete(id, props)
: Tears down existing resource.diff(id, olds, news)
: Checks update impacts.read(id, props)
: Reads current live state.update(id, olds, news)
: Updates existing resource.
outs
: Properties computed during updating.