@microsoft/sp-diagnostics
Advanced tools
Comparing version 1.9.0-plusbeta to 1.9.1-plusbeta
@@ -5,2 +5,14 @@ { | ||
{ | ||
"version": "1.9.1", | ||
"tag": "@microsoft/sp-diagnostics_v1.9.1", | ||
"date": "Wed, 14 Aug 2019 06:49:49 GMT", | ||
"comments": { | ||
"dependency": [ | ||
{ | ||
"comment": "Updating dependency \"@ms/sp-build-internal-web\" from `~0.27.9` to `~0.27.10`" | ||
} | ||
] | ||
} | ||
}, | ||
{ | ||
"version": "1.9.0", | ||
@@ -7,0 +19,0 @@ "tag": "@microsoft/sp-diagnostics_v1.9.0", |
# Change Log - @microsoft/sp-diagnostics | ||
This log was last generated on Mon, 22 Jul 2019 19:07:47 GMT and should not be manually modified. | ||
This log was last generated on Wed, 14 Aug 2019 06:49:49 GMT and should not be manually modified. | ||
## 1.9.1 | ||
Wed, 14 Aug 2019 06:49:49 GMT | ||
*Version update only* | ||
## 1.9.0 | ||
@@ -6,0 +11,0 @@ Mon, 22 Jul 2019 19:07:47 GMT |
@@ -6,3 +6,3 @@ { | ||
"componentType": "Library", | ||
"version": "1.9.0", | ||
"version": "1.9.1", | ||
"loaderConfig": { | ||
@@ -20,3 +20,3 @@ "entryModuleId": "sp-diagnostics", | ||
"type": "component", | ||
"version": "1.9.0", | ||
"version": "1.9.1", | ||
"id": "7263c7d0-1d6a-45ec-8d85-d4d1d234171b" | ||
@@ -26,3 +26,3 @@ }, | ||
"type": "component", | ||
"version": "1.9.0", | ||
"version": "1.9.1", | ||
"id": "73e1dc6c-8441-42cc-ad47-4bd3659f8a3a" | ||
@@ -29,0 +29,0 @@ } |
@@ -8,1052 +8,86 @@ /** | ||
import { ILogHandler } from '@microsoft/sp-core-library'; | ||
import { ServiceKey } from '@microsoft/sp-core-library'; | ||
import { ServiceScope } from '@microsoft/sp-core-library'; | ||
/** | ||
* @copyright Microsoft Corporation. All rights reserved. | ||
*/ | ||
/** | ||
* @internal | ||
*/ | ||
export declare class _CircularBuffer<DataType> { | ||
/** | ||
* The size of the buffer | ||
*/ | ||
private _size; | ||
/** | ||
* Index of the newest item in the buffer | ||
*/ | ||
private _head; | ||
/** | ||
* The overall count of how many items have ever been added to the buffer. | ||
*/ | ||
private _count; | ||
private _buffer; | ||
private _isIterating; | ||
constructor(size: number); | ||
readonly count: number; | ||
push(item: DataType): void; | ||
forEach(handle: (value: DataType) => void): void; | ||
removeAll(): void; | ||
/** | ||
* Index of the oldest item in the buffer | ||
*/ | ||
private readonly _tail; | ||
private _isNotWrapped; | ||
/** | ||
* The next index should be index + 1, unless it reaches | ||
* the end of the buffer and needs to rewind to 0. | ||
*/ | ||
private _getNext; | ||
private _ensureNotIterating; | ||
} | ||
/* Excluded from this release type: _CircularBuffer */ | ||
/** | ||
* Component list for the component field in Engagement Event stream. | ||
* @internal | ||
*/ | ||
export declare const enum _Component { | ||
View = "View", | ||
Button = "Button", | ||
CommentDeleteCancelAction = "CommentDeleteCancelAction", | ||
CommentDeleteConfirmAction = "CommentDeleteConfirmAction", | ||
CommentDeleteOpenAction = "CommentDeleteOpenAction", | ||
CommentReplyAction = "CommentReplyAction", | ||
CommentReplyPostButton = "CommentReplyPostButton", | ||
CommentShowMoreButton = "CommentShowMoreButton", | ||
CommentsDisable = "CommentsDisable", | ||
CommentsEnable = "CommentsEnable", | ||
LoadMoreCommentReplies = "LoadMoreCommentReplies", | ||
LoadMoreComments = "LoadMoreComments", | ||
DiscardButton = "DiscardButton", | ||
DiscardOKButton = "DiscardOKButton", | ||
EditButton = "EditButton", | ||
NewApp = "NewApp", | ||
NewButton = "NewButton", | ||
NewDocLib = "NewDocLib", | ||
NewList = "NewList", | ||
NewPlan = "NewPlan", | ||
NewsAdd = "NewsAdd", | ||
NewsSeeAll = "NewsSeeAll", | ||
NewsArticleTitle = "NewsArticleTitle", | ||
NewsSiteTitle = "NewsSiteTitle", | ||
NewsImageArea = "NewsImageArea", | ||
NewsItemPinned = "NewsItemPinned", | ||
NewsPinnedItemRemoved = "NewsPinnedItemRemoved", | ||
NewsPinnedItemSorted = "NewsPinnedItemSorted", | ||
SelectNewsToPin = "SelectNewsToPin", | ||
CreateNewsLinkFromHome = "CreateNewsLinkFromHome", | ||
CreateNewsPostFromHome = "CreateNewsPostFromHome", | ||
CreateNewsPostFromArticle = "CreateNewsPostFromArticle", | ||
NewsDraft = "NewsDraft", | ||
PostPublishAddToNav = "PostPublishAddToNav", | ||
PostPublishCopyAddress = "PostPublishCopyAddress", | ||
PostPublishEmail = "PostPublishEmail", | ||
PostPublishPostAsNews = "PostPublishPostAsNews", | ||
PromoteButton = "PromoteButton", | ||
PublishButton = "PublishButton", | ||
SaveButton = "SaveButton", | ||
CreateNewsDigest = "CreateNewsDigest", | ||
ContinueNewsDigest = "ContinueNewsDigest", | ||
SendNewsDigest = "SendNewsDigest", | ||
CancelNewsDigest = "CancelNewsDigest", | ||
ShareButton = "ShareButton", | ||
StartWithPageCopy = "StartWithPageCopy", | ||
StartWithNewsPostCopy = "StartWithNewsPostCopy", | ||
StartWithTemplate = "StartWithTemplate", | ||
ScrollBar = "ScrollBar", | ||
Header = "Header", | ||
Component = "Component", | ||
Extension = "Extension", | ||
PageSettingsButton = "PageSettingsButton", | ||
SaveAsTemplateButton = "SaveAsTemplateButton", | ||
SubmitButtonClick = "SubmitButtonClick", | ||
ReviewApprovalsButtonClick = "ReviewApprovalsButtonClick", | ||
SubmitDone = "SubmitDone", | ||
ApproveDone = "ApproveDone", | ||
RejectDone = "RejectDone", | ||
CheckedOutButton = "CheckedOutButton", | ||
BaseWPSelectedLayout = "BaseWPSelectedLayout" | ||
} | ||
/* Excluded from this release type: _Component */ | ||
/** | ||
* CurrentPage Classification for the currentPage field in Engagement Event stream. | ||
* @internal | ||
*/ | ||
export declare const enum _CurrentPage { | ||
HomePage = "HomePage", | ||
NewsArticlePage = "NewsArticlePage", | ||
ArticlePage = "ArticlePage", | ||
ModernPage = "ModernPage", | ||
ClassicPage = "ClassicPage", | ||
NewsPage = "NewsPage", | ||
NewsDigestPage = "NewsDigestPage", | ||
Space = "Space" | ||
} | ||
/* Excluded from this release type: _CurrentPage */ | ||
/** | ||
* Diagnostics class initializes the diagnostics pipeline and connect to backend server. | ||
* Diagnostics contains a set of internal APIs that collects data and reports data via | ||
* the pipeline. The APIs consist of | ||
* -- TraceLogger - for logging diagnostic information | ||
* | ||
* @internal | ||
*/ | ||
export declare class _Diagnostics { | ||
private static _isInitialized; | ||
/** | ||
* Initializes the diagnostics pipelines | ||
*/ | ||
static initialize(settings: _IDiagnosticsSettings): void; | ||
/** | ||
* Returns true if diagnostics has been already initialized. | ||
*/ | ||
static readonly isInitialized: boolean; | ||
/** | ||
* Used to refresh the telemetry settings when they change from the application | ||
* (i.e. when an in-place navigation to a different site happens) | ||
* @param settings - the subset of the telemetry settings to be updated | ||
*/ | ||
static updateSettings(settings: Partial<_IDiagnosticsSettings>): void; | ||
} | ||
/* Excluded from this release type: _Diagnostics */ | ||
/** | ||
* Engagement logging | ||
* use *.Click for all the actions triggered by mouse, keyboard, or touch. | ||
* if you want to add more data or the action is not click but keydown. | ||
* Use extraData to log the type of action or use extraData to log details wrapped in LogEntry | ||
* @internal | ||
*/ | ||
export declare class _EngagementLogger { | ||
private static _logManager; | ||
private static _shouldProcessInRealTime; | ||
private static _handler; | ||
/** | ||
* Init function for the passed logger object | ||
*/ | ||
static _addHandler(logger: _IEngagementHandler): void; | ||
/** | ||
* Starts processing logs in real time | ||
*/ | ||
static startRealTimeProcessing(): void; | ||
/** | ||
* Engagement logging | ||
* | ||
* @remarks | ||
* Use *.Click for all the actions triggered by mouse, keyboard, or touch. | ||
* tagName follows `<Workload>.controlName.actionName` pattern | ||
* For example, `{ name = "AddButton.Click" }`, | ||
* this logs `"<Workload>.AddButton.Click"` with default action triggered by mouse, keyboard, or touch. | ||
* `<Workload>` is set in Telemetry settings | ||
* `IEngagementData` interface is mapped to a set of enums for standardization of mapping. | ||
* Add new items to enum in order to register a new item specification. | ||
* SiteType is defined in SiteType enum | ||
* CurrentPage is defined in CurrentPage enum | ||
* Component is defined in Component enum | ||
* Feature is defined in Feature enum. | ||
*/ | ||
static log(engagementData: _IEngagementData): void; | ||
/** | ||
* Engagement logging | ||
* | ||
* @remarks | ||
* Use *.Click for all the actions triggered by mouse, keyboard, or touch. | ||
* tagName follows `<Workload>.controlName.actionName` pattern | ||
* For example, `tagName = "AddButton.Click"`, | ||
* this logs `"<Workload>.AddButton.Click"` with default action triggered by mouse, keyboard, or touch. | ||
* `<Workload>` is set in Telemetry settings | ||
* Use extraData to log the type of action. | ||
* For example, `actionName = "Keydown"` and `tagName = "ModernPublish.AddButton.Click"` | ||
* this logs `"<Workload>.AddButton.Click"` with the extraData that it was selected using the Keydown | ||
*/ | ||
static logEvent(tagName: string, actionName?: string): void; | ||
/** | ||
* Engagement logging with LogEntry | ||
* | ||
* @remarks | ||
* Here is an example: | ||
* ``` | ||
* {"EngagementName":"SPPage.NavigationAction.SPPageQuickLaunchUpdate"`, | ||
* "Properties":"{\"message\":\"[NavigationAction] | SPPageQuickLaunchUpdate | 2 | null\"}", | ||
* "Duration":0,"LogType":0, | ||
* "ClientTime":1459357627444,"Source":"ClientV2Engagement"} | ||
* ``` | ||
* | ||
* NavigationAction is moduleName in LogEntry, SPPageQuickLaunchUpdate is log feature name | ||
* In this example, SPPage is workload name which is set in Telemetry settings. | ||
* Do NOT add PII data! | ||
*/ | ||
static logEventWithLogEntry(logEntry: _ILogEntry): void; | ||
private static _logEngagementData; | ||
private static _checkValidTagName; | ||
private static _addContextData; | ||
} | ||
/* Excluded from this release type: _EngagementLogger */ | ||
/** | ||
* ExecutionQueue allows multiple handlers to be processed in real time or deferred. | ||
* @internal | ||
*/ | ||
export declare class _ExecutionQueue { | ||
private _shouldExecuteInRealTime; | ||
private _handlers; | ||
private _executionEntries; | ||
/** | ||
* Determines if the added execution entries should be processed in real time. | ||
* If this is set to true, a stack with entries will not be saved. | ||
*/ | ||
/** | ||
* Sets the behavior for this execution stack. | ||
* When set to true, all entries on stack will be processed and future entries | ||
* will be executed in real time. | ||
* When set to false, future entries will be saved in the execution stack for | ||
* later processing. | ||
*/ | ||
shouldExecuteInRealTime: boolean; | ||
/** | ||
* Registers an external handler to collection for delayed asyncronous processing. | ||
* Handlers are registered once. If handler is already registered, it does nothing. | ||
*/ | ||
addHandler(key: string, handler: (args: Array<any>) => void): void; | ||
/** | ||
* Execution Entry registration for delayed asyncronous processing. | ||
*/ | ||
addExecutionEntry(key: string, ...args: any[]): void; | ||
/** | ||
* Removes an external executionEntry handler from collection for asyncronous event logging. | ||
* Logger is registered once. | ||
*/ | ||
removeHandler(key: string, handler: (args: Array<any>) => void): void; | ||
/** | ||
* Reset function clears executionEntry handler collection for asyncronous event logging. | ||
* All recorded execution entries and handlers are purged. | ||
*/ | ||
reset(): void; | ||
/** | ||
* Flushes all the buffered execution entries. | ||
* All recorded execution entries are purged. | ||
*/ | ||
flush(): void; | ||
private _containsHandler; | ||
private _initializeHandlerArrayForKey; | ||
private _processAllExecutionEntries; | ||
private _processExecutionEntry; | ||
} | ||
/* Excluded from this release type: _ExecutionQueue */ | ||
/** | ||
* Feature list for the feature field in Engagement Event stream. | ||
* @internal | ||
*/ | ||
export declare const enum _Feature { | ||
News = "News", | ||
NewsDigest = "NewsDigest", | ||
WebPart = "WebPart", | ||
ScrollBar = "ScrollBar", | ||
Header = "Header", | ||
Canvas = "Canvas", | ||
LeftNav = "Leftnav", | ||
TopNav = "TopNav" | ||
} | ||
/* Excluded from this release type: _Feature */ | ||
/** | ||
* ABExperiment interface. | ||
* @internal | ||
*/ | ||
export declare interface _IABExperiment { | ||
/** Checks if the current specified target is being selected to be part of the experiment **/ | ||
IsExperimentOn?: () => boolean; | ||
} | ||
/* Excluded from this release type: _IABExperiment */ | ||
/** | ||
* Diagnostics configuration | ||
* | ||
* @internal | ||
*/ | ||
export declare interface _IDiagnosticsSettings { | ||
/** | ||
* Flag to enable logging of Diagnostics to the console | ||
*/ | ||
enableConsoleLog: boolean; | ||
/** | ||
* The current site id (GUID) | ||
* Example: `"{440067a7-8e96-4446-8e0e-fafef7a9e9d9}"` | ||
*/ | ||
siteId: string; | ||
/** | ||
* The current web id (GUID) | ||
* Example: `"{b29e6452-fe31-4967-872b-ea5d23dbfe07}"` | ||
*/ | ||
webId: string; | ||
/** | ||
* The current list id (GUID) | ||
* Example: `"{b29e6452-fe31-4967-872b-ea5d23dbfe07}"` | ||
*/ | ||
listId?: string; | ||
/** | ||
* The current list item unique id (GUID) | ||
* Example: `"{b29e6452-fe31-4967-872b-ea5d23dbfe07}"` | ||
*/ | ||
listItemUniqueId?: string; | ||
/** | ||
* The current correlationId (GUID) | ||
* Example: `"{b29e6452-fe31-4967-872b-ea5d23dbfe07}"` | ||
*/ | ||
correlationId?: string; | ||
} | ||
/* Excluded from this release type: _IDiagnosticsSettings */ | ||
/** | ||
* Engagement handler log data action interface | ||
* Represents a subset of Engagement Event Stream fields. | ||
* Full list can be located at: `\odsp-utilities\src\local\logging\events\Engagement.event.json` | ||
* @internal | ||
*/ | ||
export declare interface _IEngagementData { | ||
/** name should follow `AppName.ControlName.ActionName` pattern **/ | ||
name: string; | ||
/** extraData is used to specify additional details regarding the action **/ | ||
extraData?: { | ||
[key: string]: any; | ||
}; | ||
/** used for tracking the site the user was on when the log was made **/ | ||
siteId?: string; | ||
/** used for tracking the web the user was on when the log was made **/ | ||
webId?: string; | ||
/** ABExperiment object used by experiments **/ | ||
experiment?: _IABExperiment; | ||
/** Site Type name of the relevant SharePoint web **/ | ||
siteType?: _SiteType; | ||
/** Component name of the relevant engagement event **/ | ||
component?: _Component; | ||
/** Feature name of the relevant recorded action **/ | ||
currentPage?: _CurrentPage; | ||
/** Feature name of the relevant recorded action **/ | ||
feature?: _Feature; | ||
/** Feature name of the relevant recorded action **/ | ||
usageType?: _UsageType; | ||
/** This indicates whether it is an intentional action by the user. | ||
* Setting isIntentional to true | ||
* will automatically publish engagement specific data to Interana | ||
*/ | ||
isIntentional?: boolean; | ||
/** | ||
* The Id of the relevant SharePoint list | ||
*/ | ||
listId?: string; | ||
/** | ||
* The Id of the relevant SharePoint document | ||
*/ | ||
docId?: string; | ||
/** used for tracking the item the user was on when the log was made **/ | ||
listItemUniqueId?: string; | ||
} | ||
/* Excluded from this release type: _IEngagementData */ | ||
/** | ||
* @file IEngagementHandler.ts | ||
* @copyright (c) Microsoft Corporation. All rights reserved. | ||
*/ | ||
/** | ||
* Engagement logger log data interface | ||
* @internal | ||
*/ | ||
export declare interface _IEngagementHandler { | ||
/** Engagement user action logging operation **/ | ||
logData(data: _IEngagementData): void; | ||
} | ||
/* Excluded from this release type: _IEngagementHandler */ | ||
/** | ||
* If you don't specify parameter:eventName | ||
* the event name for all errors logged that way will be same "CaughtError" with | ||
* appropriate prefix ("ModernPublish.CaughtError" etc.) | ||
* The parameter "eventName" is there to be used from Qos. | ||
* It is not encouraged to use it directly from ErrorHelper but if you do, | ||
* the log will be written with custom event name of following format: | ||
* <Workload>.<eventName>.<resultCode>.Failure, where resultCOde is only used | ||
* in ILogErrorData. | ||
* | ||
* | ||
* @internal | ||
*/ | ||
export declare interface _ILogData { | ||
/** | ||
* | ||
*/ | ||
source: _ILogSource; | ||
/** | ||
* | ||
*/ | ||
eventName?: string; | ||
/** | ||
* | ||
*/ | ||
serviceScope?: ServiceScope; | ||
/** | ||
* | ||
*/ | ||
logEntry?: _ILogEntry; | ||
} | ||
/* Excluded from this release type: _ILogData */ | ||
/** | ||
* @internal | ||
*/ | ||
export declare interface _ILogEntry { | ||
/** | ||
* The name of the module associated with this entry | ||
*/ | ||
moduleName: string; | ||
/** | ||
* The feature associated with this entry | ||
*/ | ||
logFeature: string; | ||
/** | ||
* The log type | ||
* todo: dkholo:task#356773 perform a cleanup after data format validation confirmation | ||
*/ | ||
logType: _LogType; | ||
/** | ||
* The optional property bag | ||
*/ | ||
logProperties?: { | ||
[key: string]: string; | ||
}; | ||
} | ||
/* Excluded from this release type: _ILogEntry */ | ||
/** | ||
* The error parameter is the only required parameter and basically will be just converted to string and | ||
* logged to Debug stream (RealibilityLogs in SLAPI). | ||
* It will also be uploaded to the server immediately and not wait for next batch log upload. | ||
* The parameter "resultCode" is there to be used from Qos. | ||
* | ||
* @internal | ||
*/ | ||
export declare interface _ILogErrorData extends _ILogData { | ||
/** | ||
* The error associated with this log data. | ||
*/ | ||
error: Error; | ||
/** | ||
* | ||
*/ | ||
resultCode?: string; | ||
} | ||
/* Excluded from this release type: _ILogErrorData */ | ||
/** | ||
* Interface defining the source a log | ||
* | ||
* @internal | ||
*/ | ||
export declare interface _ILogSource { | ||
id: string; | ||
} | ||
/* Excluded from this release type: ILogHandler */ | ||
/** | ||
* @internal | ||
*/ | ||
export declare interface _ILogVerboseData extends _ILogData { | ||
/** | ||
* The message associated with this log data. | ||
*/ | ||
message: string; | ||
} | ||
/* Excluded from this release type: _ILogSource */ | ||
/** | ||
* Interface for Qos internal object | ||
* @internal | ||
*/ | ||
export declare interface _IQos { | ||
data: { | ||
extraData: string; | ||
name: string; | ||
resultCode: string; | ||
resultType: _QosResultType; | ||
}; | ||
shortEventName: string; | ||
new (event: _IQosStartEvent): any; | ||
end(event: _IQosEndEvent): void; | ||
} | ||
/* Excluded from this release type: _ILogVerboseData */ | ||
/** | ||
* IQosEndEvent interface. | ||
* @internal | ||
*/ | ||
export declare interface _IQosEndEvent { | ||
resultCode?: string; | ||
resultType: _QosResultType; | ||
error?: string; | ||
extraData?: Object; | ||
} | ||
/* Excluded from this release type: _IQos */ | ||
/** | ||
* Interface for SPFx QoS extraData field. | ||
* This provides schema validation through the interface to consolidate all extra data in a known set of fields. | ||
* | ||
* @remarks | ||
* The goal of this interface is to provide a comprehensive list of extra data fields and encourage re-use, even if | ||
* it's used in a different context. | ||
* | ||
* @internal | ||
*/ | ||
export declare interface _IQosExtraData { | ||
/** | ||
* Component id. This should be a Guid value. | ||
*/ | ||
manifestId?: string; | ||
/** | ||
* Component version. This should be a string that matches with sp-core-library Version definition. | ||
*/ | ||
version?: string; | ||
/** | ||
* Component alias. | ||
*/ | ||
alias?: string; | ||
/** | ||
* True if the component is a first-party component. | ||
*/ | ||
isInternal?: boolean; | ||
/** | ||
* Name. Its meaning can change depending on the context of the QoS monitor. | ||
* | ||
* Usage: | ||
* SPComponentLoader.loadPathDependency: Resource name (path dependency) being loaded. | ||
*/ | ||
name?: string; | ||
/** | ||
* True if the component in the operation comes from a debug manifest. | ||
* Usage: SPComponentLoader.loadComponent | ||
*/ | ||
isDebug?: boolean; | ||
/** | ||
* Loader used in the operation. Currently it can be "systemjs" or "requirejs" | ||
* Usage: SPComponentLoader.loadComponent | ||
*/ | ||
loader?: string; | ||
} | ||
/* Excluded from this release type: _IQosEndEvent */ | ||
/** | ||
* @copyright Microsoft Corporation. All rights reserved. | ||
*/ | ||
/** | ||
* IQosStartEvent interface. | ||
* @internal | ||
*/ | ||
export declare interface _IQosStartEvent { | ||
name: string; | ||
} | ||
/* Excluded from this release type: _IQosExtraData */ | ||
/** | ||
* Trace logger log data interface | ||
* @internal | ||
*/ | ||
export declare interface _ITraceHandler { | ||
/** Trace logging operation **/ | ||
log(traceEvent: _ITraceLogEvent): void; | ||
/** Verbose trace logging operation **/ | ||
verbose(traceVerboseEvent: _IVerboseTraceLogEvent): void; | ||
} | ||
/* Excluded from this release type: _IQosStartEvent */ | ||
/** | ||
* ITraceLogEvent log data interface | ||
* @internal | ||
*/ | ||
export declare interface _ITraceLogEvent extends _IVerboseTraceLogEvent { | ||
/** Result Code for the Trace Log **/ | ||
resultCode?: string; | ||
} | ||
/* Excluded from this release type: _ITraceHandler */ | ||
/** | ||
* @internal | ||
*/ | ||
export declare interface _ITraceLogger { | ||
logError(source: _ILogSource, error: Error, eventName?: string, resultCode?: string): void; | ||
logVerbose(source: _ILogSource, message: string, eventName?: string): void; | ||
logErrorWithLogEntry(source: _ILogSource, logEntry: _ILogEntry, eventName?: string, resultCode?: string): void; | ||
logVerboseWithLogEntry(source: _ILogSource, logEntry: _ILogEntry, eventName?: string): void; | ||
} | ||
/* Excluded from this release type: _ITraceLogEvent */ | ||
/** | ||
* IVerboseTraceLogEvent log data interface | ||
* @internal | ||
*/ | ||
export declare interface _IVerboseTraceLogEvent { | ||
/** Data for the Trace Log **/ | ||
data: string | Error; | ||
/** Event Name for the Trace Log **/ | ||
eventName?: string; | ||
} | ||
/* Excluded from this release type: _ITraceLogger */ | ||
/** | ||
* Represents a Log entry | ||
* | ||
* @internal | ||
*/ | ||
export declare class _LogEntry implements _ILogEntry { | ||
moduleName: string; | ||
logFeature: string; | ||
logType: _LogType; | ||
logProperties: { | ||
[key: string]: string; | ||
}; | ||
/** | ||
* Initializes a new instance of LogEntry | ||
* @param moduleName - the name of the module | ||
* @param logFeature - the name of the feature | ||
* @param logType - the log type | ||
* @param logProperties - optional property bag | ||
*/ | ||
constructor(moduleName: string, logFeature?: string, logType?: _LogType, logProperties?: { | ||
[key: string]: string; | ||
}); | ||
/** | ||
* convert the log entry to string | ||
* @returns the serialized log entry | ||
*/ | ||
toString(): string; | ||
} | ||
/* Excluded from this release type: _IVerboseTraceLogEvent */ | ||
/** | ||
* An object that represents one log event. | ||
* @internal | ||
*/ | ||
export declare class _LogEvent { | ||
/** | ||
* Allows process log events. | ||
*/ | ||
static logManager: _LogManager<_LogEvent>; | ||
private _timestamp; | ||
private _scope; | ||
private _source; | ||
private _message; | ||
private _error; | ||
private _level; | ||
private _prefix; | ||
/** | ||
* Use this method to log an event. | ||
* | ||
* @param source - source of the log event, e.g. class name of the source file | ||
* @param data - data of the log event | ||
* @param level - level of the log event | ||
* @param serviceScope - scope of the log event, e.g. component/web part | ||
*/ | ||
static log(source: string, data: string | Error, level: _LogLevel, serviceScope?: ServiceScope): _LogEvent; | ||
/** | ||
* Do not call this constructor directly. Use LogEvent.log instead. | ||
*/ | ||
constructor(source: string, data: string | Error, level: _LogLevel, serviceScope?: ServiceScope); | ||
toString(): string; | ||
readonly timestamp: number; | ||
readonly level: _LogLevel; | ||
readonly prefix: string; | ||
readonly scope: _LogSource; | ||
readonly source: string; | ||
readonly message: string; | ||
readonly error: Error; | ||
private readonly _maxSourceLength; | ||
private readonly _maxMessageLength; | ||
private _validate; | ||
private _setData; | ||
private _getPrefix; | ||
private _getScope; | ||
} | ||
/* Excluded from this release type: _LogEntry */ | ||
/** | ||
* @file LogFeature.ts | ||
* @Copyright (c) Microsoft Corporation. All rights reserved. | ||
* Used for logging so you can filter logs by features. | ||
*/ | ||
/** | ||
* @internal | ||
*/ | ||
export declare class _LogFeature { | ||
static None: string; | ||
} | ||
/* Excluded from this release type: _LogEvent */ | ||
/** | ||
* This handler adapts the sp-core-library Log to use the internal telemetry. | ||
* @internal | ||
*/ | ||
export declare class _LogHandler implements ILogHandler { | ||
verbose(source: string, message: string, scope: ServiceScope): void; | ||
info(source: string, message: string, scope: ServiceScope): void; | ||
warn(source: string, message: string, scope: ServiceScope): void; | ||
error(source: string, error: Error, scope: ServiceScope): void; | ||
} | ||
/* Excluded from this release type: _LogFeature */ | ||
/** | ||
* @copyright Microsoft Corporation. All rights reserved. | ||
*/ | ||
/** | ||
* LogLevel represents the level of a log event. | ||
* @internal | ||
*/ | ||
export declare enum _LogLevel { | ||
/** | ||
* verbose event for debugging | ||
*/ | ||
Verbose = 1, | ||
/** | ||
* Informational event | ||
*/ | ||
Info = 2, | ||
/** | ||
* A warning | ||
*/ | ||
Warning = 3, | ||
/** | ||
* An error | ||
*/ | ||
Error = 4 | ||
} | ||
/* Excluded from this release type: _LogHandler */ | ||
/** | ||
* LogManager allows multiple handlers to process log events. | ||
* It caches the latest 5000 log events. If a handler is just added, the | ||
* handler is able to get access to the cached events and all incoming events. | ||
* Dev-dashboard and potentially third-party can use it to get access to events. | ||
* @internal | ||
*/ | ||
export declare class _LogManager<TLog> { | ||
private static readonly _maxVerboseLog; | ||
private _shouldLogInRealTime; | ||
private _handlers; | ||
private _events; | ||
constructor(initialHandler?: (e: TLog) => void); | ||
/** | ||
* Event list for delayed asynchronous processing. | ||
* Events are accumulated in CircularBuffer for processing later. | ||
*/ | ||
readonly events: _CircularBuffer<TLog>; | ||
/** | ||
* Registers an external logger to logger collection for asynchronous event logging. | ||
* Logger is registered once. | ||
*/ | ||
addHandler(handler: (e: TLog) => void): void; | ||
/** | ||
* Event logging operation for delayed asynchronous processing. | ||
*/ | ||
log(event: TLog): void; | ||
/** | ||
* Removes an external logger from logger collection for asynchronous event logging. | ||
* Logger is registered once. | ||
*/ | ||
removeHandler(handler: (e: TLog) => void): void; | ||
/** | ||
* Reset function clears logger collection for asynchronous event logging. | ||
* All recorded events are purged. | ||
*/ | ||
reset(): void; | ||
/** | ||
* Processes all the buffered events using the registered handler. | ||
*/ | ||
processAll(handler: (e: TLog) => void): void; | ||
private _containsHandler; | ||
private _processAllEvents; | ||
private _processLogEvent; | ||
} | ||
/* Excluded from this release type: _LogLevel */ | ||
/** | ||
* Represents a Log entry | ||
* | ||
* @internal | ||
*/ | ||
export declare class _LogSource implements _ILogSource { | ||
private readonly _id; | ||
/** | ||
* Factory method to create an instance of the LogSource class | ||
* @returns a reference to an instance of the LogSource class | ||
*/ | ||
static create(id: string): _LogSource; | ||
readonly id: string; | ||
/** | ||
* @returns if the LogSource is empty. | ||
*/ | ||
isEmpty(): boolean; | ||
private constructor(); | ||
} | ||
/* Excluded from this release type: _LogManager */ | ||
/* Excluded from this release type: _LogSource */ | ||
/** @public */ | ||
export declare const _logSourceServiceKey: ServiceKey<_LogSource>; | ||
/** | ||
* Represents the supported log types | ||
* | ||
* @internal | ||
*/ | ||
export declare enum _LogType { | ||
/** | ||
* Trace level log. Use this for logging diagnostics | ||
*/ | ||
Trace = 1, | ||
/** | ||
* Event level log. Use this for logging usage etc | ||
*/ | ||
Event = 2, | ||
/** | ||
* Use for errors | ||
*/ | ||
Error = 3 | ||
} | ||
/* Excluded from this release type: _LogType */ | ||
/** | ||
* QosLogger allows multiple QosMonitors to be deferred processed. | ||
* @internal | ||
*/ | ||
export declare class _QosLogger { | ||
private static _instance; | ||
private _qosEvents; | ||
private _deferExecutor; | ||
private _shouldProcessInRealTime; | ||
private _qosLogger; | ||
static readonly instance: _QosLogger; | ||
constructor(); | ||
shouldProcessInRealTime: boolean; | ||
setLogger(qosLogger: _IQos): void; | ||
getQosEvent(key: string): _IQos; | ||
startQosMonitor(key: string, startData: _IQosStartEvent): void; | ||
writeQosEndResult(key: string, endData: _IQosEndEvent): void; | ||
private _startMonitor; | ||
private _endMonitor; | ||
private initializeLogger; | ||
} | ||
/* Excluded from this release type: _QosLogger */ | ||
/** | ||
* Qos logger | ||
* This class represents the Qos monitor APIs | ||
* | ||
* @preapproved @internal | ||
*/ | ||
export declare class _QosMonitor { | ||
private static readonly logSource; | ||
private static readonly qosMonitorHasEndedErrorString; | ||
private _id; | ||
private _hasEnded; | ||
private _endExtraData; | ||
private _scenarioName; | ||
private _endResultCode; | ||
private _endResult; | ||
private _copyToEngagement; | ||
private _qosResultTypeValue; | ||
static startRealTimeProcessing(): void; | ||
/** | ||
* Only used in unit tests | ||
* @internal | ||
*/ | ||
static _shouldProcessInRealTime(processInRealTime: boolean): void; | ||
/** | ||
* Creates a QoS monitor (initializes it and logs the start event) | ||
* @param scenarioName - Unique name of the QoS scenario | ||
* You will see start tag: SPPages.ScenarioName.Start | ||
* @param copyToEngagement - indicate whether this data should be used as Engagement as well. | ||
*/ | ||
constructor(scenarioName: string, copyToEngagement?: boolean); | ||
readonly name: string; | ||
readonly shortEventName: string; | ||
readonly resultCode: string; | ||
readonly resultType: _QosResultType; | ||
readonly extraData: any; | ||
readonly hasEnded: boolean; | ||
/** | ||
* QoS monitor ends with success | ||
* You will see success tag: SPPages.ScenarioName.Success | ||
*/ | ||
writeSuccess(extraData?: { | ||
[key: string]: any; | ||
}): void; | ||
/** | ||
* QoS monitor ends with failure | ||
* You will see failure tag: SPPages.ScenarioName.<failuretag>.Failure. | ||
* <failuretag> will be filled with param tagName | ||
*/ | ||
writeUnexpectedFailure(tagNameSuffix?: string, ex?: Error, extraData?: { | ||
[key: string]: any; | ||
}): void; | ||
writeExpectedFailure(tagNameSuffix?: string, ex?: Error, extraData?: { | ||
[key: string]: any; | ||
}): void; | ||
private _writeQosEnd; | ||
private _isLogCorrelationIdKillSwitchActive; | ||
private _shouldSkip; | ||
private _writeToEngagement; | ||
private _shouldWriteToEngagement; | ||
} | ||
/* Excluded from this release type: _QosMonitor */ | ||
/** | ||
* @copyright Microsoft Corporation. All rights reserved. | ||
*/ | ||
/** | ||
* Qos Result Type enum. | ||
* @internal | ||
*/ | ||
export declare const enum _QosResultType { | ||
Success = 0, | ||
Failure = 1, | ||
ExpectedFailure = 2 | ||
} | ||
/* Excluded from this release type: _QosResultType */ | ||
/** | ||
* Syte Type Classification for the syteType field in Engagement Event stream. | ||
* @internal | ||
*/ | ||
export declare const enum _SiteType { | ||
Group = "GroupSite", | ||
Team = "TeamSite", | ||
CommSite = "CommunicationSite", | ||
PublishingSite = "PublishingSite" | ||
} | ||
/* Excluded from this release type: _SiteType */ | ||
/** | ||
* This is used to log traces of failed operations and debugging information. | ||
* @internal | ||
*/ | ||
export declare class _TraceLogger { | ||
/** | ||
* Allows process trace log events. | ||
*/ | ||
static _logManager: _LogManager<_ITraceLogEvent>; | ||
/** | ||
* Allows process verbose trace log events. | ||
*/ | ||
static _verboseLogManager: _LogManager<_IVerboseTraceLogEvent>; | ||
private static _defaultLogger; | ||
private static _shouldWriteToConsole; | ||
/** | ||
* Init function for the passed logger object | ||
* | ||
* @internal | ||
*/ | ||
static _addHandler(logger: _ITraceHandler): void; | ||
/** | ||
* Exception logging | ||
* This shoule be used whenever you want to log something that might in future help to debug failures. | ||
* The error parameter is the only required one and basically will be just converted to string and | ||
* logged to Debug stream (RealibilityLogs in SLAPI). | ||
* It will also be uploaded to the server immediately and not wait for next batch log upload. | ||
* If you don't specify second parameter:eventName | ||
* the event name for all errors logged that way will be same "CaughtError" with | ||
* appropriate prefix ("ModernPublish.CaughtError" etc.) | ||
* These two parameters "eventName and resultCode" are there to be used from Qos. | ||
* It is not encouraged to use them directly from ErrorHelper but if you do, | ||
* the log will be written with custom event name of following format: | ||
* <Workload>.<eventName>.<resultCode>.Failure, Workload is set in Telemetry settings. | ||
**/ | ||
static logError(source: _ILogSource, error: Error, eventName?: string, resultCode?: string): void; | ||
/** | ||
* Exception logging intended to replace to logError. | ||
* | ||
* @remarks | ||
* Uses the `ILogErrorData` interface to prevent excessive undefined parameters | ||
* when calling this function. | ||
* This should be used whenever you want to log something that might in future help to | ||
* debug failures. | ||
* It will also be uploaded to the server immediately and not wait for next batch log upload. | ||
*/ | ||
static logErrorData(data: _ILogErrorData): void; | ||
/** | ||
* Trace logging | ||
* The idea here is that verbose logs don't get uploaded to the server unless | ||
* a failure is logged using ErrorHelper.log method. | ||
* There is a circular buffer that holds last 50 verbose logs from all scenarios and | ||
* it is only flushed and uploaded in case a failure is logged. | ||
* That way whenever you get a failure event with message you also have all supportive verbose messages | ||
* you logged throughout your scenario execution (or other scenarios). | ||
* And hopefully that would help you get to the bottom of what exactly went wrong. | ||
* If no failure happens and your scenario succeeds, verbose logs will be just left in the buffer | ||
* and most likely overriden by next scenario that logs something verbose. | ||
**/ | ||
static logVerbose(source: _ILogSource, message: string, eventName?: string): void; | ||
/** | ||
* Verbose logging intended to replace to logVerbose. | ||
* The idea here is that verbose logs don't get uploaded to the server unless | ||
* a failure is logged using ErrorHelper.log method. | ||
* There is a circular buffer that holds last 50 verbose logs from all scenarios and | ||
* it is only flushed and uploaded in case a failure is logged. | ||
* That way whenever you get a failure event with message you also have all supportive verbose messages | ||
* you logged throughout your scenario execution (or other scenarios). | ||
* And hopefully that would help you get to the bottom of what exactly went wrong. | ||
* If no failure happens and your scenario succeeds, verbose logs will be just left in the buffer | ||
* and most likely overriden by next scenario that logs something verbose. | ||
*/ | ||
static logVerboseData(data: _ILogVerboseData): void; | ||
/** | ||
* Exception logging With LogEntry | ||
* error message should be packed into logProperties | ||
* LogType should be LogType.Error and LogProperties should have `{error:errorMessage}` | ||
* Do NOT add PII data! | ||
**/ | ||
static logErrorWithLogEntry(source: _ILogSource, logEntry: _ILogEntry, eventName?: string, resultCode?: string): void; | ||
/** | ||
* Indicates if the log entries should be output to the console. | ||
* This flag is set to true by default. | ||
*/ | ||
/** | ||
* Toggles console output functionality. | ||
* Property can be chaged by remote caller. | ||
*/ | ||
static shouldWriteToConsole: boolean; | ||
static logVerboseWithLogEntry(source: _ILogSource, logEntry: _ILogEntry, eventName?: string): void; | ||
private static _log; | ||
private static _addEventPrefix; | ||
private static _writeToConsole; | ||
} | ||
/* Excluded from this release type: _TraceLogger */ | ||
/** | ||
* UsageType list for the usageType field in Engagement Event stream. | ||
* @internal | ||
*/ | ||
export declare const enum _UsageType { | ||
Click = "Click", | ||
Scroll = "Scroll", | ||
ScrollUp = "ScrollUp", | ||
ScrollDown = "ScrollDown", | ||
Hover = "Hover", | ||
Load = "Load", | ||
PageLoad = "PageLoad", | ||
Render = "Render", | ||
Drag = "Drag", | ||
Drop = "Drop", | ||
Tap = "Tap", | ||
KeyDown = "KeyDown", | ||
KeyPress = "KeyPress", | ||
RightClick = "RightClick", | ||
Swipe = "Swipe" | ||
} | ||
/* Excluded from this release type: _UsageType */ | ||
export { } |
@@ -1,2 +0,2 @@ | ||
define("78359e4b-07c2-43c6-8d0b-d060b4d577e8_1.9.0", ["@microsoft/sp-core-library","@microsoft/sp-lodash-subset"], function(__WEBPACK_EXTERNAL_MODULE__microsoft_sp_core_library__, __WEBPACK_EXTERNAL_MODULE__microsoft_sp_lodash_subset__) { return /******/ (function(modules) { // webpackBootstrap | ||
define("78359e4b-07c2-43c6-8d0b-d060b4d577e8_1.9.1", ["@microsoft/sp-core-library","@microsoft/sp-lodash-subset"], function(__WEBPACK_EXTERNAL_MODULE__microsoft_sp_core_library__, __WEBPACK_EXTERNAL_MODULE__microsoft_sp_lodash_subset__) { return /******/ (function(modules) { // webpackBootstrap | ||
/******/ // The module cache | ||
@@ -3,0 +3,0 @@ /******/ var installedModules = {}; |
{ | ||
"name": "@microsoft/sp-diagnostics", | ||
"version": "1.9.0-plusbeta", | ||
"version": "1.9.1-plusbeta", | ||
"description": "Diagnostics tools for the SharePoint Framework", | ||
@@ -16,7 +16,7 @@ "license": "SEE LICENSE IN \"EULA\" FOLDER", | ||
"@ms/sp-build-compiler-3.3": "1.9.0-dev.4", | ||
"@ms/sp-build-internal-web": "~0.27.6" | ||
"@ms/sp-build-internal-web": "~0.27.10" | ||
}, | ||
"dependencies": { | ||
"@microsoft/sp-core-library": "1.9.0-plusbeta", | ||
"@microsoft/sp-lodash-subset": "1.9.0-plusbeta" | ||
"@microsoft/sp-core-library": "1.9.1-plusbeta", | ||
"@microsoft/sp-lodash-subset": "1.9.1-plusbeta" | ||
}, | ||
@@ -23,0 +23,0 @@ "scripts": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1857809
3714
+ Added@microsoft/sp-core-library@1.9.1-plusbeta(transitive)
+ Added@microsoft/sp-lodash-subset@1.9.1-plusbeta(transitive)
+ Added@microsoft/sp-module-interfaces@1.9.1-plusbeta(transitive)
- Removed@microsoft/sp-core-library@1.9.0-plusbeta(transitive)
- Removed@microsoft/sp-lodash-subset@1.9.0-plusbeta(transitive)
- Removed@microsoft/sp-module-interfaces@1.9.0-plusbeta(transitive)