From 851dcdc3e5d54dcf4bd44e2c1cab8eeab21f20a2 Mon Sep 17 00:00:00 2001 From: Bernd Hufmann Date: Fri, 5 Sep 2025 07:43:31 -0400 Subject: [PATCH 1/4] Fix properties value type of a Trace The TSP specifies it as a map String to String and not as a map String to any type. Signed-off-by: Bernd Hufmann --- tsp-typescript-client/src/models/trace.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tsp-typescript-client/src/models/trace.ts b/tsp-typescript-client/src/models/trace.ts index a09c708..689ac40 100644 --- a/tsp-typescript-client/src/models/trace.ts +++ b/tsp-typescript-client/src/models/trace.ts @@ -3,8 +3,7 @@ import { assertNumber, createNormalizer } from '../protocol/serialization'; export const Trace = createNormalizer({ end: BigInt, nbEvents: assertNumber, - start: BigInt, - properties: undefined, + start: BigInt }); /** @@ -44,7 +43,7 @@ export interface Trace { /** * Trace's properties */ - properties: Record; + properties: Record; /** * Indicate if the indexing of the trace is completed or still running. From ce0ec9420c31fd12e4945ab19875b31097dbfed8 Mon Sep 17 00:00:00 2001 From: Bernd Hufmann Date: Fri, 5 Sep 2025 07:44:13 -0400 Subject: [PATCH 2/4] Remove duplicate ConfigParamDescriptor definition Signed-off-by: Bernd Hufmann --- .../src/models/configuration.ts | 25 ------------------- 1 file changed, 25 deletions(-) diff --git a/tsp-typescript-client/src/models/configuration.ts b/tsp-typescript-client/src/models/configuration.ts index 865cd4f..b33580f 100644 --- a/tsp-typescript-client/src/models/configuration.ts +++ b/tsp-typescript-client/src/models/configuration.ts @@ -34,28 +34,3 @@ export interface Configuration { */ parameters?: Record; } - -/** - * Model of a configuration parameter descriptor - */ -export interface ConfigParamDescriptor { - /** - * The unique name of the key - */ - keyName: string; - - /** - * A short description. - */ - description?: string; - - /** - * The data type string, e.g. use NUMBER for numbers, or STRING as strings - */ - dataType?: string; - - /** - * If parameter needs to in the query parameters or not. Default is false. - */ - isRequired?: boolean; -} From 88c9e14ed9549829c056950799e04b8659a7b716 Mon Sep 17 00:00:00 2001 From: Bernd Hufmann Date: Fri, 5 Sep 2025 07:45:18 -0400 Subject: [PATCH 3/4] Align Bookmark data structure with TSP specification - Rename startTime to start - Rename endTime to end - Remove type Signed-off-by: Bernd Hufmann --- tsp-typescript-client/src/models/bookmark.ts | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/tsp-typescript-client/src/models/bookmark.ts b/tsp-typescript-client/src/models/bookmark.ts index fd8452e..785a5bd 100644 --- a/tsp-typescript-client/src/models/bookmark.ts +++ b/tsp-typescript-client/src/models/bookmark.ts @@ -1,8 +1,8 @@ import { createNormalizer } from '../protocol/serialization'; export const Bookmark = createNormalizer({ - endTime: BigInt, - startTime: BigInt, + end: BigInt, + start: BigInt, }); /** @@ -22,15 +22,10 @@ export interface Bookmark { /** * Start time for the bookmark */ - startTime: bigint; + start: bigint; /** * End time for the bookmark */ - endTime: bigint; - - /** - * Type of the bookmark - */ - type: string; + end: bigint; } From 99ec8dc08d2ef7924ef967d6a059592d37c38b94 Mon Sep 17 00:00:00 2001 From: Bernd Hufmann Date: Fri, 5 Sep 2025 07:48:03 -0400 Subject: [PATCH 4/4] Make style.parentKey and annotation.label optional as per TSP Also, clarify default value of optional parameter ConfigurationParameterDescriptor.dataType Related to TSP fix: https://github.com/eclipse-cdt-cloud/trace-server-protocol/issues/125 Signed-off-by: Bernd Hufmann --- tsp-typescript-client/src/models/annotation.ts | 2 +- tsp-typescript-client/src/models/configuration-source.ts | 2 +- tsp-typescript-client/src/models/styles.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tsp-typescript-client/src/models/annotation.ts b/tsp-typescript-client/src/models/annotation.ts index 83cf453..53ae40f 100644 --- a/tsp-typescript-client/src/models/annotation.ts +++ b/tsp-typescript-client/src/models/annotation.ts @@ -25,7 +25,7 @@ export interface Annotation { /** * Label of the annotation */ - label: string; + label?: string; /** * Time of the annotation diff --git a/tsp-typescript-client/src/models/configuration-source.ts b/tsp-typescript-client/src/models/configuration-source.ts index e1986f1..00d0e3b 100644 --- a/tsp-typescript-client/src/models/configuration-source.ts +++ b/tsp-typescript-client/src/models/configuration-source.ts @@ -48,7 +48,7 @@ export interface ConfigurationParameterDescriptor { description?: string; /** - * The data type string, e.g. use NUMBER for numbers, or STRING as strings + * The data type string, e.g. use NUMBER for numbers, or STRING as strings. Default is STRING. */ dataType?: string; diff --git a/tsp-typescript-client/src/models/styles.ts b/tsp-typescript-client/src/models/styles.ts index c5ae19e..4a79ebb 100644 --- a/tsp-typescript-client/src/models/styles.ts +++ b/tsp-typescript-client/src/models/styles.ts @@ -14,7 +14,7 @@ export interface OutputElementStyle { /** * Parent style key */ - parentKey: string; + parentKey?: string; /** * Style values to override or define properties