The log levels supported by the logger. The log levels in order of most verbose to least verbose are:
Defines values for CopyStatusType. Possible values include: 'pending', 'success', 'aborted', 'failed'
A factory function that creates a new CredentialPolicy that uses the provided nextPolicy.
Defines values for DeleteSnapshotsOptionType. Possible values include: 'include'
Contains response data for the create operation.
Contains response data for the deleteMethod operation.
Contains response data for the forceCloseHandles operation.
Contains response data for the getProperties operation.
Contains response data for the listFilesAndDirectoriesSegment operation.
Contains response data for the listHandles operation.
Contains response data for the setMetadata operation.
Contains response data for the setProperties operation.
Contains response data for the abortCopy operation.
Indicates keep existing file attributes unchanged.
Contains response data for the create operation.
Contains response data for the deleteMethod operation.
Contains response data for the forceCloseHandles operation.
Contains response data for the getProperties operation.
Contains response data for the getRangeList operation. Contains response data for the getRangeList operation.
Contains response data for the listHandles operation.
Indicates inherit file permission from the parent directory.
Indicates keep existing file permission value unchanged.
Defines values for FileRangeWriteType. Possible values include: 'update', 'clear'
Contains response data for the setHTTPHeaders operation.
Contains response data for the setMetadata operation.
Contains response data for the startCopy operation.
Defines values for FileType. Possible values include: 'File'
Contains response data for the uploadRangeFromURL operation.
Contains response data for the uploadRange operation.
High resolution HrTime: [seconds: number, nanoseconds: number]
Defines values for ListSharesIncludeType. Possible values include: 'snapshots', 'metadata'
Operation is an async function to be executed and managed by Batch.
OutgoingHandler is an async function triggered by BufferScheduler.
A HttpHeaders collection represented as a simple JSON object.
Creates a new RequestPolicy per-request that uses the provided nextPolicy.
Contains response data for the getProperties operation.
Contains response data for the listSharesSegment operation.
Contains response data for the setProperties operation.
Contains response data for the createPermission operation.
Contains response data for the create operation.
Contains response data for the createSnapshot operation.
Contains response data for the deleteMethod operation.
Contains response data for the getAccessPolicy operation.
Contains response data for the getPermission operation.
Contains response data for the getProperties operation.
Contains response data for the getStatistics operation. Response - Share Get Statistics Operation.
Contains response data for the setAccessPolicy operation.
Contains response data for the setMetadata operation.
Contains response data for the setQuota operation.
Defines values for StorageErrorCode. Possible values include: 'AccountAlreadyExists', 'AccountBeingCreated', 'AccountIsDisabled', 'AuthenticationFailed', 'AuthorizationFailure', 'ConditionHeadersNotSupported', 'ConditionNotMet', 'EmptyMetadataKey', 'InsufficientAccountPermissions', 'InternalError', 'InvalidAuthenticationInfo', 'InvalidHeaderValue', 'InvalidHttpVerb', 'InvalidInput', 'InvalidMd5', 'InvalidMetadata', 'InvalidQueryParameterValue', 'InvalidRange', 'InvalidResourceName', 'InvalidUri', 'InvalidXmlDocument', 'InvalidXmlNodeValue', 'Md5Mismatch', 'MetadataTooLarge', 'MissingContentLengthHeader', 'MissingRequiredQueryParameter', 'MissingRequiredHeader', 'MissingRequiredXmlNode', 'MultipleConditionHeadersNotSupported', 'OperationTimedOut', 'OutOfRangeInput', 'OutOfRangeQueryParameterValue', 'RequestBodyTooLarge', 'ResourceTypeMismatch', 'RequestUrlFailedToParse', 'ResourceAlreadyExists', 'ResourceNotFound', 'ServerBusy', 'UnsupportedHeader', 'UnsupportedXmlNode', 'UnsupportedQueryParameter', 'UnsupportedHttpVerb', 'CannotDeleteFileOrDirectory', 'ClientCacheFlushDelay', 'DeletePending', 'DirectoryNotEmpty', 'FileLockConflict', 'InvalidFileOrDirectoryPathName', 'ParentNotFound', 'ReadOnlyAttribute', 'ShareAlreadyExists', 'ShareBeingDeleted', 'ShareDisabled', 'ShareNotFound', 'SharingViolation', 'ShareSnapshotInProgress', 'ShareSnapshotCountExceeded', 'ShareSnapshotOperationNotSupported', 'ShareHasSnapshots', 'ContainerQuotaDowngradeNotAllowed'
Defines TimeInput.
hrtime, expoch milliseconds, performance.now() or Date
Indicates setting as the time of the request.
Indicates keep existing time value unchanged.
Fired in response to upload or download progress.
The AzureLogger provides a mechanism for overriding where logs are output to.
By default, logs are sent to stderr.
Override the log
method to redirect logs to another location.
Defines the default token refresh buffer duration.
ONLY AVAILABLE IN NODE.JS RUNTIME.
Promisified version of fs.stat().
A constant that indicates whether the environment is node.js or browser based.
The @azure/logger configuration for this package.
A factory method used to generated a RetryPolicy factory.
Append a string to URL path. Will remove duplicated "/" in front of the string when URL path ends with a "/".
Source URL string
String to be appended to URL
An updated URL string
Applies the properties on the prototype of sourceCtors to the prototype of targetCtor
The target object on which the properties need to be applied.
An array of source objects from which the properties need to be taken.
Base64 decode.
Base64 encode.
Creates a new BearerTokenAuthenticationPolicy factory.
The TokenCredential implementation that can supply the bearer token.
The scopes for which the bearer token applies.
Convert a Browser Blob object into ArrayBuffer.
Creates a span using the global tracer.
The tracingOptions for the underlying http request.
A wrapper for setTimeout that resolves a promise after t milliseconds.
The number of milliseconds to be delayed.
The value to be resolved with after a timeout of t milliseconds.
Resolved promise
Create a new serialization RequestPolicyCreator that will serialized HTTP request bodies as they pass through the HTTP pipeline.
Encodes an URI.
The URI to be encoded.
The encoded URI.
Reserved URL characters must be properly escaped for Storage services like Blob or File.
When customers pass a URL string into XXXClient classes constructor, the URL string may already be URL encoded or not. But before sending to Azure Storage server, the URL must be encoded. However, it's hard for a SDK to guess whether the URL string has been encoded or not. We have 2 potential strategies, and chose strategy two for the XXXClient constructors.
This is what legacy V2 SDK does, simple and works for most of the cases.
But this strategy will make it not possible to create a blob with "?" in it's name. Because when customer URL string is "http://account.blob.core.windows.net/con/blob?name", the "?name" will be treated as URL paramter instead of blob name. If customer URL string is "http://account.blob.core.windows.net/con/blob%3Fname", a blob named "blob%3Fname" will be created. V2 SDK doesn't have this issue because it doesn't allow customer pass in a full URL, it accepts a separate blob name and encodeURIComponent for it. We cannot accept a SDK cannot create a blob name with "?". So we implement strategy two:
This is what V10 Blob Go SDK does. It accepts a URL type in Go, and call url.EscapedPath() to escape the special chars unescaped.
This strategy gives us flexibility to create with any special characters. But "%" will be treated as a special characters, if the URL string is not encoded, there shouldn't a "%" in the URL string, otherwise the URL is not a valid URL. If customer needs to create a blob with "%" in it's blob name, use "%25" insead of "%". Just like above 3rd sample. And following URL strings are invalid:
Another special character is "?", use "%2F" to represent a blob name with "?" in a URL string.
ContainerClient.getBlobClient(blobName)
We will apply strategy one, and call encodeURIComponent for these parameters like blobName. Because what customers passes in is a plain name instead of a URL.
Executes an array of promises sequentially. Inspiration of this method is here: https://pouchdb.com/2015/05/18/we-have-a-problem-with-promises.html. An awesome blog on promises!
An array of promise factories(A function that return a promise)
A chain of resolved or rejected promises
Extracts the parts of an Azure Storage account connection string.
Connection string.
String key value pairs of the storage account's url and credentials.
Generates a SpanContext
given a traceparent
header value.
The SpanContext
generated from the traceparent
value.
ONLY AVAILABLE IN NODE.JS RUNTIME.
Generates a SASQueryParameters object which contains all SAS query parameters needed to make an actual REST request.
ONLY AVAILABLE IN NODE.JS RUNTIME.
Creates an instance of SASQueryParameters.
Only accepts required settings needed to create a SAS. For optional settings please set corresponding properties directly, such as permissions, startTime and identifier.
WARNING: When identifier is not provided, permissions and expiryTime are required. You MUST assign value to identifier or expiryTime & permissions manually if you initial with this constructor.
Generated UUID
RFC4122 v4 UUID.
Retrieves the currently specified log level.
Get the path to this parameter's value as a dotted string (a.b.c).
The parameter to get the path string for.
The path to this parameter's value as a dotted string.
Get the property parent for the property at the provided path when starting with the provided parent object.
Generates a traceparent
value given a span context.
Contains context for a specific span.
The spanContext
represented as a traceparent
value.
Retrieves the active tracer, or returns a no-op implementation if one is not set.
Get URL parameter by name.
Get URL path from an URL string.
Source URL string
Get URL query key value pairs from an URL string.
Generate SasIPRange format string. For example:
"8.8.8.8" or "1.1.1.1-255.255.255.255"
A range of IP addresses.
string representation of the IP range.
Get whether or not the provided character (single character string) is an alphanumeric (letter or digit) character.
Indicates whether the given string is in ISO 8601 format.
The value to be validated for ISO 8601 duration format.
true
if valid, false
otherwise.
Determines whether the given entity is a basic/primitive type (string, number, boolean, null, undefined).
Any entity
Tests an object to determine whether it implements TokenCredential.
The assumed TokenCredential to be tested.
Validates the given uuid as a string
The uuid as a string that needs to be validated
True if the uuid is valid; false otherwise.
Creates a new Pipeline object with Credential provided.
Such as AnonymousCredential, StorageSharedKeyCredential.
A new Pipeline object.
Converts an OperationOptions to a RequestOptionsBase
OperationOptions object to convert to RequestOptionsBase
String.prototype.padStart()
Converts given XML string into JSON
String containing the XML content to be parsed into JSON
Options that govern the parsing of given xml string
includeRoot
indicates whether the root element is to be included or not in the output
Converts a Promise to a callback.
The Promise to be converted to a callback
A function that takes the callback (cb: Function): void
Converts a Promise to a service callback.
The Promise of HttpOperationResponse to be converted to a service callback
A function that takes the service callback (cb: ServiceCallback
Generate a range string. For example:
"bytes=255-" or "bytes=0-511"
A range of byte positions.
The string representation for the byte range.
ONLY AVAILABLE IN NODE.JS RUNTIME.
Writes the content of a readstream to a local file. Returns a Promise which is completed after the file handle is closed. If Promise is rejected, the reason will be set to the first error raised by either the ReadableStream or the fs.WriteStream.
The read stream.
Destination file path.
Replace all of the instances of searchValue in value with the provided replaceValue.
The value to search and replace in.
The value to search for in the value argument.
The value to replace searchValue with in the value argument.
The value where each instance of searchValue was replaced with replacedValue.
Immediately enables logging at the specified log level.
The log level to enable for logging. Options from most verbose to least verbose are:
Sets the global tracer, enabling tracing for the Azure SDK.
An OpenTelemetry Tracer instance.
Set URL host.
Source URL string
New host string
An updated URL string
Set URL parameter name and value. If name exists in URL parameters, old value will be replaced by name key. If not provide value, the parameter will be deleted.
Source URL string
Parameter name
An updated URL string
Reads a readable stream into buffer. Fill the buffer from offset to end.
A Node.js Readable stream
Buffer to be filled, length must >= offset
From which position in the buffer to be filled, inclusive
To which position in the buffer to be filled, exclusive
Converts given JSON object to XML string
JSON object to be converted into XML string
Options that govern the parsing of given JSON object
rootName
indicates the name of the root element in the resulting XML
Returns a stripped version of the Http Request that does not contain the Authorization header.
The Http Request object
The stripped version of Http Request.
Returns a stripped version of the Http Response which only contains body, headers and the status.
The Http Response
The stripped version of Http Response.
Rounds a date off to seconds.
Date string in ISO8061 format, with or without 7 milliseconds component
Checks if a parsed URL is HTTPS
The url to check
True if the URL is HTTPS; false otherwise.
Generated using TypeDoc
An AzureClientLogger is a function that can log to an appropriate severity level.