attlaz-client 1.62.0 → 1.63.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Model/Filter/FilterNode.d.ts +18 -0
- package/dist/Model/Filter/FilterNode.js +1 -0
- package/dist/Model/Filter/FilterOperator.d.ts +1 -0
- package/dist/Model/Filter/FilterOperator.js +1 -0
- package/dist/Service/AdapterConnectionEndpoint.d.ts +2 -2
- package/dist/Service/AdapterConnectionEndpoint.js +2 -2
- package/dist/Service/LogEndpoint.d.ts +2 -2
- package/dist/Service/LogEndpoint.js +1 -13
- package/dist/index.d.ts +2 -1
- package/dist/index.js +0 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/dist/Model/Log/LogItemFilter.d.ts +0 -9
- package/dist/Model/Log/LogItemFilter.js +0 -4
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { FilterOperator } from './FilterOperator.js';
|
|
2
|
+
export type FilterPrimitive = string | number | boolean | null;
|
|
3
|
+
export type FilterValue = FilterPrimitive | FilterPrimitive[];
|
|
4
|
+
export interface AndFilterNode {
|
|
5
|
+
and: FilterNode[];
|
|
6
|
+
}
|
|
7
|
+
export interface OrFilterNode {
|
|
8
|
+
or: FilterNode[];
|
|
9
|
+
}
|
|
10
|
+
export interface NotFilterNode {
|
|
11
|
+
not: FilterNode;
|
|
12
|
+
}
|
|
13
|
+
export interface CompareFilterNode {
|
|
14
|
+
field: string;
|
|
15
|
+
op: FilterOperator;
|
|
16
|
+
value: FilterValue;
|
|
17
|
+
}
|
|
18
|
+
export type FilterNode = AndFilterNode | OrFilterNode | NotFilterNode | CompareFilterNode;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type FilterOperator = 'eq' | 'neq' | 'in' | 'not_in' | 'lt' | 'lte' | 'gt' | 'gte' | 'is_null' | 'is_not_null' | 'starts_with' | 'contains';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -21,8 +21,8 @@ export declare class AdapterConnectionEndpoint extends Endpoint {
|
|
|
21
21
|
* breakdown so the UI can render a step-by-step view; the overall `state`
|
|
22
22
|
* is the worst of the per-check states (skipped < passed < warning < failed).
|
|
23
23
|
*
|
|
24
|
-
* Used by the Web App's "Test" button.
|
|
25
|
-
* `POST /connections/:id/check` route on Core-Api
|
|
24
|
+
* Used by the Web App's "Test" button. Replaces the legacy
|
|
25
|
+
* `POST /connections/:id/check` route on Core-Api (removed).
|
|
26
26
|
*/
|
|
27
27
|
testConnection(connectionId: string): Promise<TestConnectionResult>;
|
|
28
28
|
}
|
|
@@ -109,8 +109,8 @@ export class AdapterConnectionEndpoint extends Endpoint {
|
|
|
109
109
|
* breakdown so the UI can render a step-by-step view; the overall `state`
|
|
110
110
|
* is the worst of the per-check states (skipped < passed < warning < failed).
|
|
111
111
|
*
|
|
112
|
-
* Used by the Web App's "Test" button.
|
|
113
|
-
* `POST /connections/:id/check` route on Core-Api
|
|
112
|
+
* Used by the Web App's "Test" button. Replaces the legacy
|
|
113
|
+
* `POST /connections/:id/check` route on Core-Api (removed).
|
|
114
114
|
*/
|
|
115
115
|
async testConnection(connectionId) {
|
|
116
116
|
const url = '/services/' + connectionId + '/test-connection';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { FilterNode } from '../Model/Filter/FilterNode.js';
|
|
1
2
|
import { Log } from '../Model/Log/Log.js';
|
|
2
|
-
import { LogItemFilter } from '../Model/Log/LogItemFilter.js';
|
|
3
3
|
import { LogQuery } from '../Model/Log/LogQuery.js';
|
|
4
4
|
import { LogStream } from '../Model/Log/LogStream.js';
|
|
5
5
|
import { LogStreamId } from '../Model/Log/LogStreamId.js';
|
|
@@ -9,7 +9,7 @@ import { CollectionResult } from '../Model/Result/CollectionResult.js';
|
|
|
9
9
|
import { Endpoint } from './Endpoint.js';
|
|
10
10
|
export declare class LogEndpoint extends Endpoint {
|
|
11
11
|
getLogs(logQuery: LogQuery): Promise<CollectionResult<Log>>;
|
|
12
|
-
getCursoredLogEntries(logStreamId: LogStreamId, pagination: CursorPagination | null, filter:
|
|
12
|
+
getCursoredLogEntries(logStreamId: LogStreamId, pagination: CursorPagination | null, filter: FilterNode | null): Promise<CollectionResult<Log>>;
|
|
13
13
|
save(log: Log): Promise<Log>;
|
|
14
14
|
delete(logId: string): Promise<boolean>;
|
|
15
15
|
clear(logStreamId: LogStreamId): Promise<boolean>;
|
|
@@ -44,19 +44,7 @@ export class LogEndpoint extends Endpoint {
|
|
|
44
44
|
const queryString = new QueryString('/logstreams/' + logStreamId.toString() + '/logs');
|
|
45
45
|
queryString.addPagination(pagination);
|
|
46
46
|
if (filter !== null && filter !== undefined) {
|
|
47
|
-
|
|
48
|
-
const arrTags = [];
|
|
49
|
-
// TODO: map this
|
|
50
|
-
for (const tag of filter.tags) {
|
|
51
|
-
arrTags.push(tag.key + ':' + tag.values.join('||'));
|
|
52
|
-
}
|
|
53
|
-
const strTags = arrTags.join('|||');
|
|
54
|
-
// filter_tags=color:gree OR color:blue
|
|
55
|
-
queryString.set('filter_tags', strTags);
|
|
56
|
-
}
|
|
57
|
-
if (filter.logLevels !== null && filter.logLevels.length > 0) {
|
|
58
|
-
queryString.set('filter_log_levels', filter.logLevels.join(','));
|
|
59
|
-
}
|
|
47
|
+
queryString.set('filter', JSON.stringify(filter));
|
|
60
48
|
}
|
|
61
49
|
const result = await this.requestCollection(queryString, Log.parse);
|
|
62
50
|
return result;
|
package/dist/index.d.ts
CHANGED
|
@@ -48,7 +48,8 @@ export { LogStatus } from './Model/Log/LogStatus.js';
|
|
|
48
48
|
export { LogStream } from './Model/Log/LogStream.js';
|
|
49
49
|
export { LogStreamId } from './Model/Log/LogStreamId.js';
|
|
50
50
|
export { LogStreamInformation } from './Model/Log/LogStreamInformation.js';
|
|
51
|
-
export {
|
|
51
|
+
export { FilterNode, AndFilterNode, OrFilterNode, NotFilterNode, CompareFilterNode, FilterValue, FilterPrimitive } from './Model/Filter/FilterNode.js';
|
|
52
|
+
export { FilterOperator } from './Model/Filter/FilterOperator.js';
|
|
52
53
|
export { CursorPagination } from './Model/Pagination/CursorPagination.js';
|
|
53
54
|
/** Messaging * */
|
|
54
55
|
export { Channel } from './Model/Messaging/Channel/Channel.js';
|
package/dist/index.js
CHANGED
|
@@ -39,7 +39,6 @@ export { LogStatus } from './Model/Log/LogStatus.js';
|
|
|
39
39
|
export { LogStream } from './Model/Log/LogStream.js';
|
|
40
40
|
export { LogStreamId } from './Model/Log/LogStreamId.js';
|
|
41
41
|
export { LogStreamInformation } from './Model/Log/LogStreamInformation.js';
|
|
42
|
-
export { LogItemFilter } from './Model/Log/LogItemFilter.js';
|
|
43
42
|
export { CursorPagination } from './Model/Pagination/CursorPagination.js';
|
|
44
43
|
/** Messaging * */
|
|
45
44
|
export { Channel } from './Model/Messaging/Channel/Channel.js';
|
package/dist/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "1.
|
|
1
|
+
export declare const VERSION = "1.62.0";
|
package/dist/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = "1.
|
|
1
|
+
export const VERSION = "1.62.0";
|
package/package.json
CHANGED