Skip to content

Commit

Permalink
Merge pull request #4139 from jeclrsg/wsLogaccess_1.05
Browse files Browse the repository at this point in the history
chore(comms): bump version of ws_logaccess service
  • Loading branch information
GordonSmith authored Oct 31, 2023
2 parents da5c25f + 62e69d8 commit 3d813a0
Show file tree
Hide file tree
Showing 2 changed files with 222 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/comms/src/services/wsLogaccess.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { scopedLogger } from "@hpcc-js/util";
import { LogaccessServiceBase, WsLogaccess } from "./wsdl/ws_logaccess/v1.04/ws_logaccess";
import { LogaccessServiceBase, WsLogaccess } from "./wsdl/ws_logaccess/v1.05/ws_logaccess";

const logger = scopedLogger("@hpcc-js/comms/services/wsLogaccess.ts");

Expand All @@ -17,6 +17,7 @@ export interface GetLogsExRequest {
threadid?: string;
timestamp?: string;
components?: string;
instance?: string;
StartDate?: Date;
EndDate?: Date;
LogLineStartFrom: number,
Expand Down Expand Up @@ -50,6 +51,7 @@ export interface LogLine {
threadid?: number;
timestamp?: string;
components?: string;
instance?: string;
}

export interface GetLogsExResponse {
Expand Down
219 changes: 219 additions & 0 deletions packages/comms/src/services/wsdl/ws_logaccess/v1.05/ws_logaccess.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,219 @@
import { IConnection, IOptions } from "../../../../connection";
import { Service } from "../../../../espConnection";

export namespace WsLogaccess {

export type dateTime = string;
export type unsignedInt = number;
export type long = number;

export enum LogColumnType {
global = "global",
workunits = "workunits",
components = "components",
audience = "audience",
class = "class",
instance = "instance",
node = "node",
message = "message",
logid = "logid",
processid = "processid",
threadid = "threadid",
timestamp = "timestamp",
pod = "pod"
}

export enum LogColumnValueType {
string = "string",
numeric = "numeric",
datetime = "datetime",
enum = "enum"
}

export enum LogAccessType {
All = 0,
ByJobID = 1,
ByComponent = 2,
ByLogType = 3,
ByTargetAudience = 4,
BySourceInstance = 5,
BySourceNode = 6,
ByFieldName = 7,
ByPod = 8
}

export enum LogAccessFilterOperator {
NONE = 0,
AND = 1,
OR = 2
}

export enum LogSelectColumnMode {
MIN = 0,
DEFAULT = 1,
ALL = 2,
CUSTOM = 3
}

export enum SortColumType {
ByDate = 0,
ByJobID = 1,
ByComponent = 2,
ByLogType = 3,
ByTargetAudience = 4,
BySourceInstance = 5,
BySourceNode = 6,
ByFieldName = 7,
ByPod = 8
}

export enum SortDirection {
ASC = 0,
DSC = 1
}

export interface GetLogAccessInfoRequest {

}

export interface EnumeratedValues {
Item: string[];
}

export interface Column {
Name: string;
LogType: LogColumnType;
EnumeratedValues: {
Item: string[];
};
ColumnMode: LogSelectColumnMode;
ColumnType: LogColumnValueType;
}

export interface Columns {
Column: Column[];
}

export interface GetLogAccessInfoResponse {
Columns: {
Column: Column[];
};
RemoteLogManagerType: string;
RemoteLogManagerConnectionString: string;
SupportsResultPaging: boolean;
}

export interface leftFilter {
LogCategory: LogAccessType;
SearchByValue: string;
SearchField: string;
}

export interface rightFilter {
LogCategory: LogAccessType;
SearchByValue: string;
SearchField: string;
}

export interface rightBinaryFilter {
BinaryLogFilter: BinaryLogFilter[];
}

export interface BinaryLogFilter {
leftFilter: leftFilter;
leftBinaryFilter: leftBinaryFilter;
Operator: LogAccessFilterOperator;
rightFilter: {
LogCategory: LogAccessType;
SearchByValue: string;
SearchField: string;
};
rightBinaryFilter: {
BinaryLogFilter: BinaryLogFilter[];
};
}

export interface leftBinaryFilter {
BinaryLogFilter: BinaryLogFilter[];
}

export interface Filter {
leftFilter: leftFilter;
leftBinaryFilter: leftBinaryFilter;
Operator: LogAccessFilterOperator;
rightFilter: rightFilter;
rightBinaryFilter: rightBinaryFilter;
}

export interface Range {
StartDate: dateTime;
EndDate: dateTime;
}

export interface SortCondition {
BySortType: SortColumType;
ColumnName: string;
Direction: SortDirection;
}

export interface SortBy {
SortCondition: SortCondition[];
}

export interface GetLogsRequest {
Filter?: {
leftFilter?: leftFilter;
leftBinaryFilter?: leftBinaryFilter;
Operator?: LogAccessFilterOperator;
rightFilter?: rightFilter;
rightBinaryFilter?: rightBinaryFilter;
};
Range?: {
StartDate?: dateTime;
EndDate?: dateTime;
};
LogLineLimit?: unsignedInt;
LogLineStartFrom?: long;
SelectColumnMode?: LogSelectColumnMode;
Columns?: Columns;
Format?: string;
SortBy?: {
SortCondition?: SortCondition[];
};
}

export interface GetLogsResponse {
LogLines: string;
LogLineCount: unsignedInt;
TotalLogLinesAvailable: unsignedInt;
}

export interface ws_logaccessPingRequest {

}

export interface ws_logaccessPingResponse {

}

}

export class LogaccessServiceBase extends Service {

constructor(optsConnection: IOptions | IConnection) {
super(optsConnection, "ws_logaccess", "1.05");
}

GetLogAccessInfo(request: WsLogaccess.GetLogAccessInfoRequest): Promise<WsLogaccess.GetLogAccessInfoResponse> {
return this._connection.send("GetLogAccessInfo", request, "json", false, undefined, "GetLogAccessInfoResponse");
}

GetLogs(request: WsLogaccess.GetLogsRequest): Promise<WsLogaccess.GetLogsResponse> {
return this._connection.send("GetLogs", request, "json", false, undefined, "GetLogsResponse");
}

Ping(request: WsLogaccess.ws_logaccessPingRequest): Promise<WsLogaccess.ws_logaccessPingResponse> {
return this._connection.send("Ping", request, "json", false, undefined, "ws_logaccessPingResponse");
}

}

0 comments on commit 3d813a0

Please sign in to comment.