From d3a5014892a425c088ad5fcaa7a3c9105221947b Mon Sep 17 00:00:00 2001 From: Jake Smith Date: Thu, 29 Feb 2024 16:47:01 +0000 Subject: [PATCH 1/7] Split off 9.2.66 Signed-off-by: Jake Smith --- helm/hpcc/Chart.yaml | 4 ++-- helm/hpcc/templates/_helpers.tpl | 2 +- helm/hpcc/templates/dafilesrv.yaml | 2 +- helm/hpcc/templates/dali.yaml | 2 +- helm/hpcc/templates/dfuserver.yaml | 2 +- helm/hpcc/templates/eclagent.yaml | 4 ++-- helm/hpcc/templates/eclccserver.yaml | 4 ++-- helm/hpcc/templates/eclscheduler.yaml | 2 +- helm/hpcc/templates/esp.yaml | 2 +- helm/hpcc/templates/localroxie.yaml | 2 +- helm/hpcc/templates/roxie.yaml | 8 ++++---- helm/hpcc/templates/sasha.yaml | 2 +- helm/hpcc/templates/thor.yaml | 10 +++++----- version.cmake | 4 ++-- 14 files changed, 25 insertions(+), 25 deletions(-) diff --git a/helm/hpcc/Chart.yaml b/helm/hpcc/Chart.yaml index 49f31f92590..b36187391e9 100644 --- a/helm/hpcc/Chart.yaml +++ b/helm/hpcc/Chart.yaml @@ -6,9 +6,9 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. -version: 9.2.65-closedown0 +version: 9.2.67-closedown0 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. -appVersion: 9.2.65-closedown0 +appVersion: 9.2.67-closedown0 diff --git a/helm/hpcc/templates/_helpers.tpl b/helm/hpcc/templates/_helpers.tpl index 160701f2df3..6f1375ad63b 100644 --- a/helm/hpcc/templates/_helpers.tpl +++ b/helm/hpcc/templates/_helpers.tpl @@ -1405,7 +1405,7 @@ kind: Service metadata: name: {{ $lvars.serviceName | quote }} labels: - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $.root "instance" $lvars.serviceName ) | indent 4 }} {{- if $lvars.labels }} {{ toYaml $lvars.labels | indent 4 }} diff --git a/helm/hpcc/templates/dafilesrv.yaml b/helm/hpcc/templates/dafilesrv.yaml index f0850fdb836..257c73db7be 100644 --- a/helm/hpcc/templates/dafilesrv.yaml +++ b/helm/hpcc/templates/dafilesrv.yaml @@ -50,7 +50,7 @@ spec: labels: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "dafilesrv" "name" "dafilesrv" "instance" .name) | indent 8 }} server: {{ .name | quote }} - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 annotations: checksum/config: {{ $configSHA }} {{- include "hpcc.generateAnnotations" $commonCtx | indent 8 }} diff --git a/helm/hpcc/templates/dali.yaml b/helm/hpcc/templates/dali.yaml index dbea2014a08..3b4fc294026 100644 --- a/helm/hpcc/templates/dali.yaml +++ b/helm/hpcc/templates/dali.yaml @@ -82,7 +82,7 @@ spec: run: {{ $dali.name | quote }} server: {{ $dali.name | quote }} app: dali - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8 }} {{- end }} diff --git a/helm/hpcc/templates/dfuserver.yaml b/helm/hpcc/templates/dfuserver.yaml index d61acb8b72e..878cc0b50f7 100644 --- a/helm/hpcc/templates/dfuserver.yaml +++ b/helm/hpcc/templates/dfuserver.yaml @@ -56,7 +56,7 @@ spec: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "dfuserver" "name" "dfuserver" "instance" .name) | indent 8 }} run: {{ .name | quote }} accessDali: "yes" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/eclagent.yaml b/helm/hpcc/templates/eclagent.yaml index bccbfd74dd2..36a490e5c8a 100644 --- a/helm/hpcc/templates/eclagent.yaml +++ b/helm/hpcc/templates/eclagent.yaml @@ -58,7 +58,7 @@ data: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" $apptype "name" "eclagent" "instance" $appJobName "instanceOf" (printf "%s-job" .me.name)) | indent 12 }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey .me "labels" }} {{ toYaml .me.labels | indent 12 }} {{- end }} @@ -133,7 +133,7 @@ spec: run: {{ .name | quote }} accessDali: "yes" accessEsp: {{ .useChildProcesses | default false | ternary "yes" "no" | quote }} - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/eclccserver.yaml b/helm/hpcc/templates/eclccserver.yaml index 25a0c0893b9..c6715e0ebc8 100644 --- a/helm/hpcc/templates/eclccserver.yaml +++ b/helm/hpcc/templates/eclccserver.yaml @@ -57,7 +57,7 @@ data: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "eclccserver" "name" "eclccserver" "instance" $compileJobName "instanceOf" (printf "%s-job" .me.name)) | indent 12 }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey .me "labels" }} {{ toYaml .me.labels | indent 12 }} {{- end }} @@ -140,7 +140,7 @@ spec: run: {{ .name | quote }} accessDali: "yes" accessEsp: {{ .useChildProcesses | default false | ternary "yes" "no" | quote }} - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/eclscheduler.yaml b/helm/hpcc/templates/eclscheduler.yaml index 33cc9b9f38d..4602c3bfc1c 100644 --- a/helm/hpcc/templates/eclscheduler.yaml +++ b/helm/hpcc/templates/eclscheduler.yaml @@ -64,7 +64,7 @@ spec: run: {{ .name | quote }} accessDali: "yes" accessEsp: "no" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/esp.yaml b/helm/hpcc/templates/esp.yaml index c39803e432c..67af35b335c 100644 --- a/helm/hpcc/templates/esp.yaml +++ b/helm/hpcc/templates/esp.yaml @@ -120,7 +120,7 @@ spec: accessSasha: "yes" {{- end }} app: {{ $application }} - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "name" $application "component" "esp" "instance" .name) | indent 8 }} {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8 }} diff --git a/helm/hpcc/templates/localroxie.yaml b/helm/hpcc/templates/localroxie.yaml index 56210d11d8d..07e0e22895b 100644 --- a/helm/hpcc/templates/localroxie.yaml +++ b/helm/hpcc/templates/localroxie.yaml @@ -70,7 +70,7 @@ spec: server: {{ $servername | quote }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "roxie-server" "name" "roxie" "instance" $roxie.name) | indent 8 }} {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} diff --git a/helm/hpcc/templates/roxie.yaml b/helm/hpcc/templates/roxie.yaml index 8b06d3408bc..062930aa659 100644 --- a/helm/hpcc/templates/roxie.yaml +++ b/helm/hpcc/templates/roxie.yaml @@ -120,7 +120,7 @@ spec: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "topology-server" "name" "roxie" "instance" $commonCtx.toponame) | indent 8 }} run: {{ $commonCtx.toponame | quote }} roxie-cluster: {{ $roxie.name | quote }} - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8}} {{- end }} @@ -178,7 +178,7 @@ kind: Service metadata: name: {{ $commonCtx.toponame | quote }} labels: - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "topology-server" "name" "roxie" "instance" $commonCtx.toponame) | indent 4 }} spec: ports: @@ -240,7 +240,7 @@ spec: roxie-cluster: {{ $roxie.name | quote }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "roxie-server" "name" "roxie" "instance" $servername) | indent 8 }} {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8}} @@ -346,7 +346,7 @@ spec: roxie-cluster: {{ $roxie.name | quote }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8}} {{- end }} diff --git a/helm/hpcc/templates/sasha.yaml b/helm/hpcc/templates/sasha.yaml index ae7c47d2baa..4adf65c8685 100644 --- a/helm/hpcc/templates/sasha.yaml +++ b/helm/hpcc/templates/sasha.yaml @@ -53,7 +53,7 @@ spec: server: {{ $serviceName | quote }} app: sasha accessDali: {{ (has "dali" $sasha.access) | ternary "yes" "no" | quote }} - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- if hasKey $sasha "labels" }} {{ toYaml $sasha.labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/thor.yaml b/helm/hpcc/templates/thor.yaml index b5547330d3e..78df1a6c1bc 100644 --- a/helm/hpcc/templates/thor.yaml +++ b/helm/hpcc/templates/thor.yaml @@ -82,7 +82,7 @@ data: labels: accessDali: "yes" accessEsp: "yes" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "eclagent" "name" "thor" "instance" $eclAgentJobName "instanceOf" (printf "%s-job" .eclAgentName)) | indent 8 }} {{- if hasKey .me "labels" }} {{ toYaml .me.labels | indent 12 }} @@ -145,7 +145,7 @@ data: accessEsp: "yes" app: "thor" component: "thormanager" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 instance: "_HPCC_JOBNAME_" job: "_HPCC_JOBNAME_" {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "thormanager" "name" "thor" "instance" $thorManagerJobName "instanceOf" (printf "%s-thormanager-job" .me.name)) | indent 12 }} @@ -210,7 +210,7 @@ data: accessEsp: "yes" app: "thor" component: "thorworker" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 instance: "_HPCC_JOBNAME_" job: "_HPCC_JOBNAME_" {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "thorworker" "name" "thor" "instance" $thorWorkerJobName "instanceOf" (printf "%s-thorworker-job" .me.name)) | indent 12 }} @@ -341,7 +341,7 @@ spec: accessEsp: {{ $commonCtx.eclAgentUseChildProcesses | ternary "yes" "no" | quote }} app: "thor" component: "thor-eclagent" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 instance: {{ $commonCtx.eclAgentName | quote }} {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "eclagent" "name" "thor" "instance" $commonCtx.eclAgentName ) | indent 8 }} {{- if hasKey $commonCtx.me "labels" }} @@ -404,7 +404,7 @@ spec: accessEsp: "no" app: "thor" component: "thor-thoragent" - helmVersion: 9.2.65-closedown0 + helmVersion: 9.2.67-closedown0 instance: {{ $commonCtx.thorAgentName | quote }} {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "eclagent" "name" "thor" "instance" $commonCtx.thorAgentName ) | indent 8 }} {{- if hasKey $commonCtx.me "labels" }} diff --git a/version.cmake b/version.cmake index 7833a82e358..e633902a6f2 100644 --- a/version.cmake +++ b/version.cmake @@ -5,8 +5,8 @@ set ( HPCC_NAME "Community Edition" ) set ( HPCC_PROJECT "community" ) set ( HPCC_MAJOR 9 ) set ( HPCC_MINOR 2 ) -set ( HPCC_POINT 65 ) +set ( HPCC_POINT 67 ) set ( HPCC_MATURITY "closedown" ) set ( HPCC_SEQUENCE 0 ) -set ( HPCC_TAG_TIMESTAMP "2024-02-22T17:02:01Z" ) +set ( HPCC_TAG_TIMESTAMP "2024-02-29T16:47:01Z" ) ### From 20ff3254afb796d210bd21b1fe75b79704e00cca Mon Sep 17 00:00:00 2001 From: Gordon Smith Date: Mon, 4 Mar 2024 17:29:21 +0000 Subject: [PATCH 2/7] HPCC-31387 ECL Watch failing to display Signed-off-by: Gordon Smith --- esp/src/src-react/components/Frame.tsx | 2 +- esp/src/src-react/components/Title.tsx | 7 +------ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/esp/src/src-react/components/Frame.tsx b/esp/src/src-react/components/Frame.tsx index 58967d6ff4d..60355ee8def 100644 --- a/esp/src/src-react/components/Frame.tsx +++ b/esp/src/src-react/components/Frame.tsx @@ -91,7 +91,7 @@ export const Frame: React.FunctionComponent = () => { }, []); React.useEffect(() => { - document.title = `${showEnvironmentTitle && environmentTitle.length ? environmentTitle : "ECL Watch "}${locationPathname.split("/").join(" | ")}`; + document.title = `${(showEnvironmentTitle && environmentTitle) ? environmentTitle : "ECL Watch "}${locationPathname.split("/").join(" | ")}`; }, [environmentTitle, locationPathname, showEnvironmentTitle]); React.useEffect(() => { diff --git a/esp/src/src-react/components/Title.tsx b/esp/src/src-react/components/Title.tsx index 9af34dfa076..ff235f3b50d 100644 --- a/esp/src/src-react/components/Title.tsx +++ b/esp/src/src-react/components/Title.tsx @@ -247,11 +247,6 @@ export const DevTitle: React.FunctionComponent = ({ } }, [currentUser]); - React.useEffect(() => { - if (!environmentTitle) return; - document.title = environmentTitle; - }, [environmentTitle]); - return
@@ -264,7 +259,7 @@ export const DevTitle: React.FunctionComponent = ({ - {showEnvironmentTitle && environmentTitle.length ? environmentTitle : "ECL Watch"} + {(showEnvironmentTitle && environmentTitle) ? environmentTitle : "ECL Watch"} From 8c4c2995c1e44fabd88de1a1acd81e88f84c0cc2 Mon Sep 17 00:00:00 2001 From: Gavin Halliday Date: Wed, 6 Mar 2024 09:51:26 +0000 Subject: [PATCH 3/7] HPCC-31400 Fix build error with newer versions of clang Signed-off-by: Gavin Halliday --- system/jhtree/jhtree.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/system/jhtree/jhtree.cpp b/system/jhtree/jhtree.cpp index 66ee27999d2..e76b915a383 100644 --- a/system/jhtree/jhtree.cpp +++ b/system/jhtree/jhtree.cpp @@ -647,7 +647,7 @@ class CNodeCacheEntry : public CInterface public: CriticalSection cs; private: - std::atomic node = nullptr; + std::atomic node{nullptr}; public: ~CNodeCacheEntry() { From 084a1c1351e6c284ab6dbbb232edecbee56a1802 Mon Sep 17 00:00:00 2001 From: Gavin Halliday Date: Thu, 7 Mar 2024 15:22:10 +0000 Subject: [PATCH 4/7] HPCC-31415 Add a unit test for OwnedSpanScope to ensure span is closed Signed-off-by: Gavin Halliday --- testing/unittests/jlibtests.cpp | 45 +++++++++++++++++++++++++-------- 1 file changed, 34 insertions(+), 11 deletions(-) diff --git a/testing/unittests/jlibtests.cpp b/testing/unittests/jlibtests.cpp index 238e646a51e..ba972fc220a 100644 --- a/testing/unittests/jlibtests.cpp +++ b/testing/unittests/jlibtests.cpp @@ -65,6 +65,7 @@ class JlibTraceTest : public CppUnit::TestFixture CPPUNIT_TEST(testEnsureTraceID); CPPUNIT_TEST(manualTestsEventsOutput); CPPUNIT_TEST(manualTestsDeclaredFailures); + CPPUNIT_TEST(manualTestScopeEnd); //CPPUNIT_TEST(testJTraceJLOGExporterprintResources); //CPPUNIT_TEST(testJTraceJLOGExporterprintAttributes); @@ -196,7 +197,7 @@ class JlibTraceTest : public CppUnit::TestFixture { Owned emptyMockHTTPHeaders = createProperties(); { - Owned serverSpan = queryTraceManager().createServerSpan("spanWithEventsNoAtts", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("spanWithEventsNoAtts", emptyMockHTTPHeaders); Owned emptyEventAtts = createProperties(); serverSpan->addSpanEvent("event1", emptyEventAtts); } @@ -206,12 +207,12 @@ class JlibTraceTest : public CppUnit::TestFixture twoEventAtt->setProp("key2", ""); { - Owned serverSpan = queryTraceManager().createServerSpan("spanWithEvent1Att", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("spanWithEvent1Att", emptyMockHTTPHeaders); serverSpan->addSpanEvent("event2", twoEventAtt); }//{ "type": "span", "name": "spanWithEvents1Att", "trace_id": "3b9f55aaf8fab51fb0d73a32db7d704f", "span_id": "2a25a44ae0b3abe0", "start": 1709696036335278770, "duration": 3363911469, "events":[ { "name": "event2", "time_stamp": 1709696038413023245, "attributes": {"key": "value" } } ] } { - Owned serverSpan = queryTraceManager().createServerSpan("spanWith2Events", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("spanWith2Events", emptyMockHTTPHeaders); serverSpan->addSpanEvent("event1", twoEventAtt); serverSpan->addSpanEvent("event2", twoEventAtt); }//{ "type": "span", "name": "spanWith2Events", "trace_id": "ff5c5919b9c5f85913652b77f289bf0b", "span_id": "82f91ca1f9d469c1", "start": 1709698012480805016, "duration": 2811601377, "events":[ { "name": "event1", "time_stamp": 1709698013294323139, "attributes": {"key": "value" } },{ "name": "event2", "time_stamp": 1709698014500350802, "attributes": {"key": "value" } } ] } @@ -275,25 +276,25 @@ class JlibTraceTest : public CppUnit::TestFixture { Owned emptyMockHTTPHeaders = createProperties(); { - Owned serverSpan = queryTraceManager().createServerSpan("defaultErrorSpan", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("defaultErrorSpan", emptyMockHTTPHeaders); serverSpan->recordError(); }//{ "type": "span", "name": "defaultErrorSpan", "trace_id": "209b5d8cea0aec9785d2dfa3117e37ad", "span_id": "ab72e76c2f2466c2", "start": 1709675278129335702, "duration": 188292867932, "status": "Error", "kind": "Server", "instrumented_library": "unittests", "events":[ { "name": "Exception", "time_stamp": 1709675465508149013, "attributes": {"escaped": 0 } } ] } { - Owned serverSpan = queryTraceManager().createServerSpan("defaultErrorSpanStruct", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("defaultErrorSpanStruct", emptyMockHTTPHeaders); SpanError error; serverSpan->recordError(error); }//{ "type": "span", "name": "defaultErrorSpanStruct", "trace_id": "19803a446b971f2e0bdddc9c00db50fe", "span_id": "04c93a91ab8785a2", "start": 1709675487767044352, "duration": 2287497219, "status": "Error", "kind": "Server", "instrumented_library": "unittests", "events":[ { "name": "Exception", "time_stamp": 1709675489216412154, "attributes": {"escaped": 0 } } ] } { - Owned serverSpan = queryTraceManager().createServerSpan("failedErrorSpanEscaped", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("failedErrorSpanEscaped", emptyMockHTTPHeaders); SpanError * error = new SpanError("hello"); error->setSpanStatus(true, true); serverSpan->recordError(*error); }//{ "type": "span", "name": "failedErrorSpanEscaped", "trace_id": "634f386c18a6140544c980e0d5a15905", "span_id": "e2f59c48f63a8f82", "start": 1709675508231168974, "duration": 7731717678, "status": "Error", "kind": "Server", "description": "hello", "instrumented_library": "unittests", "events":[ { "name": "Exception", "time_stamp": 1709675512164430668, "attributes": {"escaped": 1,"message": "hello" } } ] } { - Owned serverSpan = queryTraceManager().createServerSpan("failedErrEscapedMsgErrCode", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("failedErrEscapedMsgErrCode", emptyMockHTTPHeaders); SpanError * error = new SpanError(); error->setSpanStatus(true, true); error->setError("hello", 34); @@ -301,22 +302,22 @@ class JlibTraceTest : public CppUnit::TestFixture }//failedErrEscapedMsgErrCode { - Owned serverSpan = queryTraceManager().createServerSpan("containsErrorAndMessageSpan", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("containsErrorAndMessageSpan", emptyMockHTTPHeaders); serverSpan->recordError(SpanError("Error Message!!")); }//{ "type": "span", "name": "containsErrorAndMessageSpan", "trace_id": "9a6e00ea309bc0427733f9b2d452f9e2", "span_id": "de63e9c69b64e411", "start": 1709675552302360510, "duration": 5233037523, "status": "Error", "kind": "Server", "description": "Error Message!!", "instrumented_library": "unittests", "events":[ { "name": "Exception", "time_stamp": 1709675555149852711, "attributes": {"escaped": 0,"message": "Error Message!!" } } { - Owned serverSpan = queryTraceManager().createServerSpan("containsErrorAndMessageFailedNotEscapedSpan", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("containsErrorAndMessageFailedNotEscapedSpan", emptyMockHTTPHeaders); serverSpan->recordError(SpanError("Error Message!!", 23, true, false)); }//{ "type": "span", "name": "containsErrorAndMessageFailedNotEscapedSpan", "trace_id": "02f4b2d215f8230b15063862f8a91e41", "span_id": "c665ec371d6db147", "start": 1709675573581678954, "duration": 3467489486, "status": "Error", "kind": "Server", "description": "Error Message!!", "instrumented_library": "unittests", "events":[ { "name": "Exception", "time_stamp": 1709675576145074240, "attributes": {"code": 23,"escaped": 0,"message": "Error Message!!" } } ] } { - Owned serverSpan = queryTraceManager().createServerSpan("mockExceptionSpanNotFailedNotEscaped", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("mockExceptionSpanNotFailedNotEscaped", emptyMockHTTPHeaders); serverSpan->recordException( makeStringExceptionV(76,"Mock exception"), false, false); }//{ "type": "span", "name": "mockExceptionSpanNotFailedNotEscaped", "trace_id": "e01766474db05ce9085943fa3955cd73", "span_id": "7da620e96e10e42c", "start": 1709675595987480704, "duration": 2609091267, "status": "Unset", "kind": "Server", "instrumented_library": "unittests", "events":[ { "name": "Exception", "time_stamp": 1709675597728975355, "attributes": {"code": 76,"escaped": 0,"message": "Mock exception" } } ] { - Owned serverSpan = queryTraceManager().createServerSpan("thrownExceptionSpan", emptyMockHTTPHeaders); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("thrownExceptionSpan", emptyMockHTTPHeaders); try { throw makeStringExceptionV( 356, "Mock thrown exception"); @@ -328,6 +329,28 @@ class JlibTraceTest : public CppUnit::TestFixture } }//{ "type": "span", "name": "thrownExceptionSpan", "trace_id": "4d6225e1cefdc6823d1134c71c522426", "span_id": "07f7bd070e008f53", "start": 1709675614823881961, "duration": 4665288686, "status": "Unset", "kind": "Server", "instrumented_library": "unittests", "events":[ { "name": "Exception", "time_stamp": 1709675616485586471, "attributes": {"code": 356,"escaped": 1,"message": "Mock thrown exception" } } ] } } + //not able to programmatically test yet, but can visually inspect trace output + void manualTestScopeEnd() + { + Owned savedSpan; + { + SpanFlags flags = SpanFlags::EnsureTraceId; + Owned emptyMockHTTPHeaders = createProperties(); + OwnedSpanScope serverSpan = queryTraceManager().createServerSpan("mySpan", emptyMockHTTPHeaders, flags); + DBGLOG("mySpan is alive"); + savedSpan.set(serverSpan); + }//{ "type": "span", "name": "mySpan", "trace_id": "fe266416e7d588113a5131394d913ab4", "span_id": "7ac62328b04442c5", "start": 1709824793826023368, "duration": 16952 } + //NB: Duration for the span should be << 100,000,000ns + //If logging is asynchronous the log message may appear after the following logging line + DBGLOG("mySpan is finished"); + Sleep(100); + + //Check that the attributes are still accessible even though the span has ended + Owned retrievedSpanCtxAttributes = createProperties(); + savedSpan->getSpanContext(retrievedSpanCtxAttributes.get()); + CPPUNIT_ASSERT_EQUAL_MESSAGE("Unexpected empty TraceID detected", false, isEmptyString(retrievedSpanCtxAttributes->queryProp("traceID"))); + savedSpan.clear(); + } void testTraceDisableConfig() { From 71ae37b2583e8803b1f0eaa92eb702f5448caee9 Mon Sep 17 00:00:00 2001 From: Shamser Ahmed Date: Tue, 5 Mar 2024 17:30:09 +0000 Subject: [PATCH 5/7] HPCC-31393 Subfile queried incorrectly For superfiles, use mapSubPart to obtain the subfile number. Signed-off-by: Shamser Ahmed --- dali/ft/filecopy.cpp | 49 +++++++++++++++++++++++++++++++++----------- 1 file changed, 37 insertions(+), 12 deletions(-) diff --git a/dali/ft/filecopy.cpp b/dali/ft/filecopy.cpp index d93ade88777..c92f42fbd86 100644 --- a/dali/ft/filecopy.cpp +++ b/dali/ft/filecopy.cpp @@ -3573,17 +3573,30 @@ void FileSprayer::updateTargetProperties() } // Update @writeCost and @numWrites in subfile properties and update totalWriteCost - if (superTgt) + if (superTgt && superTgt->numSubFiles() > 0) { if (cur.whichOutput != (unsigned)-1) { - unsigned targetPartNum = targets.item(cur.whichOutput).partNum; - IDistributedFile &subfile = superTgt->querySubFile(targetPartNum, true); - DistributedFilePropertyLock lock(&subfile); + IDistributedFile *subfile; + if (superTgt->numSubFiles() > 1) + { + Owned fDesc = superTgt->getFileDescriptor(); + ISuperFileDescriptor *superFDesc = fDesc->querySuperFileDescriptor(); + unsigned subfileNum, subFilePartNum; + superFDesc->mapSubPart(targets.item(cur.whichOutput).partNum, subfileNum, subFilePartNum); + subfile = superTgt->querySubPart(subfileNum, subFilePartNum); + } + else + { + // If there is a single subfile, it is not necessary to map part to subfile + // (also, querySuperFileDescriptor return nullptr if num subfile == 1) + subfile = &superTgt->querySubFile(0); + } + DistributedFilePropertyLock lock(subfile); IPropertyTree &subFileProps = lock.queryAttributes(); cost_type prevNumWrites = subFileProps.getPropInt64(getDFUQResultFieldName(DFUQRFnumDiskWrites)); cost_type prevWriteCost = subFileProps.getPropInt64(getDFUQResultFieldName(DFUQRFwriteCost)); - cost_type curWriteCost = calcFileAccessCost(&subfile, curProgress.numWrites, 0); + cost_type curWriteCost = calcFileAccessCost(subfile, curProgress.numWrites, 0); subFileProps.setPropInt64(getDFUQResultFieldName(DFUQRFwriteCost), prevWriteCost + curWriteCost); subFileProps.setPropInt64(getDFUQResultFieldName(DFUQRFnumDiskWrites), prevNumWrites + curProgress.numWrites); totalWriteCost += curWriteCost; @@ -3786,23 +3799,35 @@ void FileSprayer::updateTargetProperties() if (distributedSource) { IDistributedSuperFile * superSrc = distributedSource->querySuperFile(); - if (superSrc) + if (superSrc && superSrc->numSubFiles() > 0) { + Owned fDesc = superSrc->getFileDescriptor(); + ISuperFileDescriptor *superFDesc = fDesc->querySuperFileDescriptor(); ForEachItemIn(idx, partition) { PartitionPoint & cur = partition.item(idx); OutputProgress & curProgress = progress.item(idx); - if (cur.whichInput != (unsigned)-1) { - unsigned sourcePartNum = sources.item(cur.whichInput).partNum; - IDistributedFile &subfile = superSrc->querySubFile(sourcePartNum, true); - DistributedFilePropertyLock lock(&subfile); + IDistributedFile *subfile; + if (superFDesc) + { + unsigned subfileNum, subFilePartNum; + superFDesc->mapSubPart(sources.item(cur.whichInput).partNum, subfileNum, subFilePartNum); + subfile = superSrc->querySubPart(subfileNum, subFilePartNum); + } + else + { + // superFDesc==nullptr if there is a single file + // so query the first (and only) subfile + subfile = &superSrc->querySubFile(0); + } + DistributedFilePropertyLock lock(subfile); IPropertyTree &subFileProps = lock.queryAttributes(); stat_type prevNumReads = subFileProps.getPropInt64(getDFUQResultFieldName(DFUQRFnumDiskReads), 0); - cost_type legacyReadCost = getLegacyReadCost(subfile.queryAttributes(), &subfile); + cost_type legacyReadCost = getLegacyReadCost(subfile->queryAttributes(), subfile); cost_type prevReadCost = subFileProps.getPropInt64(getDFUQResultFieldName(DFUQRFreadCost), 0); - cost_type curReadCost = calcFileAccessCost(&subfile, 0, curProgress.numReads); + cost_type curReadCost = calcFileAccessCost(subfile, 0, curProgress.numReads); subFileProps.setPropInt64(getDFUQResultFieldName(DFUQRFnumDiskReads), prevNumReads + curProgress.numReads); subFileProps.setPropInt64(getDFUQResultFieldName(DFUQRFreadCost), legacyReadCost + prevReadCost + curReadCost); totalReadCost += curReadCost; From 7b23c08fab9b0825e439924f4765065f8f5ab8c2 Mon Sep 17 00:00:00 2001 From: Gordon Smith Date: Thu, 7 Mar 2024 17:32:39 +0000 Subject: [PATCH 6/7] Split off 9.4.42 Signed-off-by: Gordon Smith --- helm/hpcc/Chart.yaml | 4 ++-- helm/hpcc/templates/_helpers.tpl | 2 +- helm/hpcc/templates/dafilesrv.yaml | 2 +- helm/hpcc/templates/dali.yaml | 2 +- helm/hpcc/templates/dfuserver.yaml | 2 +- helm/hpcc/templates/eclagent.yaml | 4 ++-- helm/hpcc/templates/eclccserver.yaml | 4 ++-- helm/hpcc/templates/eclscheduler.yaml | 2 +- helm/hpcc/templates/esp.yaml | 2 +- helm/hpcc/templates/localroxie.yaml | 2 +- helm/hpcc/templates/roxie.yaml | 8 ++++---- helm/hpcc/templates/sasha.yaml | 2 +- helm/hpcc/templates/thor.yaml | 10 +++++----- version.cmake | 4 ++-- 14 files changed, 25 insertions(+), 25 deletions(-) diff --git a/helm/hpcc/Chart.yaml b/helm/hpcc/Chart.yaml index f0c4e4a4054..8ddd130af63 100644 --- a/helm/hpcc/Chart.yaml +++ b/helm/hpcc/Chart.yaml @@ -6,9 +6,9 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. -version: 9.4.41-closedown0 +version: 9.4.43-closedown0 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. -appVersion: 9.4.41-closedown0 +appVersion: 9.4.43-closedown0 diff --git a/helm/hpcc/templates/_helpers.tpl b/helm/hpcc/templates/_helpers.tpl index b52b5929b48..493af724e17 100644 --- a/helm/hpcc/templates/_helpers.tpl +++ b/helm/hpcc/templates/_helpers.tpl @@ -1501,7 +1501,7 @@ kind: Service metadata: name: {{ $lvars.serviceName | quote }} labels: - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $.root "instance" $lvars.serviceName ) | indent 4 }} {{- if $lvars.labels }} {{ toYaml $lvars.labels | indent 4 }} diff --git a/helm/hpcc/templates/dafilesrv.yaml b/helm/hpcc/templates/dafilesrv.yaml index 4553c3497fe..8314f27b730 100644 --- a/helm/hpcc/templates/dafilesrv.yaml +++ b/helm/hpcc/templates/dafilesrv.yaml @@ -51,7 +51,7 @@ spec: labels: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "dafilesrv" "name" "dafilesrv" "instance" .name) | indent 8 }} server: {{ .name | quote }} - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 annotations: checksum/config: {{ $configSHA }} {{- include "hpcc.generateAnnotations" $commonCtx | indent 8 }} diff --git a/helm/hpcc/templates/dali.yaml b/helm/hpcc/templates/dali.yaml index 8aadbf80c77..8f940717307 100644 --- a/helm/hpcc/templates/dali.yaml +++ b/helm/hpcc/templates/dali.yaml @@ -84,7 +84,7 @@ spec: run: {{ $dali.name | quote }} server: {{ $dali.name | quote }} app: dali - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8 }} {{- end }} diff --git a/helm/hpcc/templates/dfuserver.yaml b/helm/hpcc/templates/dfuserver.yaml index 73f24e7c2ef..55ab4834628 100644 --- a/helm/hpcc/templates/dfuserver.yaml +++ b/helm/hpcc/templates/dfuserver.yaml @@ -57,7 +57,7 @@ spec: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "dfuserver" "name" "dfuserver" "instance" .name) | indent 8 }} run: {{ .name | quote }} accessDali: "yes" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/eclagent.yaml b/helm/hpcc/templates/eclagent.yaml index 88d2cb86feb..3ca1121f043 100644 --- a/helm/hpcc/templates/eclagent.yaml +++ b/helm/hpcc/templates/eclagent.yaml @@ -60,7 +60,7 @@ data: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" $apptype "name" "eclagent" "instance" $appJobName "instanceOf" (printf "%s-job" .me.name)) | indent 12 }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey .me "labels" }} {{ toYaml .me.labels | indent 12 }} {{- end }} @@ -137,7 +137,7 @@ spec: run: {{ .name | quote }} accessDali: "yes" accessEsp: {{ .useChildProcesses | default false | ternary "yes" "no" | quote }} - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/eclccserver.yaml b/helm/hpcc/templates/eclccserver.yaml index 50f1aeeffc5..68000adb1bc 100644 --- a/helm/hpcc/templates/eclccserver.yaml +++ b/helm/hpcc/templates/eclccserver.yaml @@ -58,7 +58,7 @@ data: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "eclccserver" "name" "eclccserver" "instance" $compileJobName "instanceOf" (printf "%s-job" .me.name)) | indent 12 }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey .me "labels" }} {{ toYaml .me.labels | indent 12 }} {{- end }} @@ -143,7 +143,7 @@ spec: run: {{ .name | quote }} accessDali: "yes" accessEsp: {{ .useChildProcesses | default false | ternary "yes" "no" | quote }} - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/eclscheduler.yaml b/helm/hpcc/templates/eclscheduler.yaml index c9a85e4b523..6a0d68385dc 100644 --- a/helm/hpcc/templates/eclscheduler.yaml +++ b/helm/hpcc/templates/eclscheduler.yaml @@ -65,7 +65,7 @@ spec: run: {{ .name | quote }} accessDali: "yes" accessEsp: "no" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/esp.yaml b/helm/hpcc/templates/esp.yaml index 0f6d42fe71e..a98f626918f 100644 --- a/helm/hpcc/templates/esp.yaml +++ b/helm/hpcc/templates/esp.yaml @@ -122,7 +122,7 @@ spec: accessSasha: "yes" {{- end }} app: {{ $application }} - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "name" $application "component" "esp" "instance" .name) | indent 8 }} {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8 }} diff --git a/helm/hpcc/templates/localroxie.yaml b/helm/hpcc/templates/localroxie.yaml index 6013ddec3bb..42534212775 100644 --- a/helm/hpcc/templates/localroxie.yaml +++ b/helm/hpcc/templates/localroxie.yaml @@ -73,7 +73,7 @@ spec: server: {{ $servername | quote }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "roxie-server" "name" "roxie" "instance" $roxie.name) | indent 8 }} {{- if hasKey . "labels" }} {{ toYaml .labels | indent 8 }} diff --git a/helm/hpcc/templates/roxie.yaml b/helm/hpcc/templates/roxie.yaml index 57f8d523ded..6ac27dc43c9 100644 --- a/helm/hpcc/templates/roxie.yaml +++ b/helm/hpcc/templates/roxie.yaml @@ -125,7 +125,7 @@ spec: {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "topology-server" "name" "roxie" "instance" $commonCtx.toponame) | indent 8 }} run: {{ $commonCtx.toponame | quote }} roxie-cluster: {{ $roxie.name | quote }} - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8}} {{- end }} @@ -183,7 +183,7 @@ kind: Service metadata: name: {{ $commonCtx.toponame | quote }} labels: - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "topology-server" "name" "roxie" "instance" $commonCtx.toponame) | indent 4 }} spec: ports: @@ -245,7 +245,7 @@ spec: roxie-cluster: {{ $roxie.name | quote }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "roxie-server" "name" "roxie" "instance" $servername) | indent 8 }} {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8}} @@ -353,7 +353,7 @@ spec: roxie-cluster: {{ $roxie.name | quote }} accessDali: "yes" accessEsp: "yes" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey $.Values.global "metrics" }} {{- include "hpcc.generateMetricsReporterLabel" $.Values.global.metrics | nindent 8}} {{- end }} diff --git a/helm/hpcc/templates/sasha.yaml b/helm/hpcc/templates/sasha.yaml index 7a3dd69bdb7..bbb75f14322 100644 --- a/helm/hpcc/templates/sasha.yaml +++ b/helm/hpcc/templates/sasha.yaml @@ -53,7 +53,7 @@ spec: server: {{ $serviceName | quote }} app: sasha accessDali: {{ (has "dali" $sasha.access) | ternary "yes" "no" | quote }} - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- if hasKey $sasha "labels" }} {{ toYaml $sasha.labels | indent 8 }} {{- end }} diff --git a/helm/hpcc/templates/thor.yaml b/helm/hpcc/templates/thor.yaml index 13c617f0459..6dba5ea1e6d 100644 --- a/helm/hpcc/templates/thor.yaml +++ b/helm/hpcc/templates/thor.yaml @@ -86,7 +86,7 @@ data: labels: accessDali: "yes" accessEsp: "yes" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "eclagent" "name" "thor" "instance" $eclAgentJobName "instanceOf" (printf "%s-job" .eclAgentName)) | indent 8 }} {{- if hasKey .me "labels" }} {{ toYaml .me.labels | indent 12 }} @@ -151,7 +151,7 @@ data: accessEsp: "yes" app: "thor" component: "thormanager" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 instance: "_HPCC_JOBNAME_" job: "_HPCC_JOBNAME_" {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "thormanager" "name" "thor" "instance" $thorManagerJobName "instanceOf" (printf "%s-thormanager-job" .me.name)) | indent 12 }} @@ -218,7 +218,7 @@ data: accessEsp: "yes" app: "thor" component: "thorworker" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 instance: "_HPCC_JOBNAME_" job: "_HPCC_JOBNAME_" {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "thorworker" "name" "thor" "instance" $thorWorkerJobName "instanceOf" (printf "%s-thorworker-job" .me.name)) | indent 12 }} @@ -351,7 +351,7 @@ spec: accessEsp: {{ $commonCtx.eclAgentUseChildProcesses | ternary "yes" "no" | quote }} app: "thor" component: "thor-eclagent" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 instance: {{ $commonCtx.eclAgentName | quote }} {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "eclagent" "name" "thor" "instance" $commonCtx.eclAgentName ) | indent 8 }} {{- if hasKey $commonCtx.me "labels" }} @@ -416,7 +416,7 @@ spec: accessEsp: "no" app: "thor" component: "thor-thoragent" - helmVersion: 9.4.41-closedown0 + helmVersion: 9.4.43-closedown0 instance: {{ $commonCtx.thorAgentName | quote }} {{- include "hpcc.addStandardLabels" (dict "root" $ "component" "eclagent" "name" "thor" "instance" $commonCtx.thorAgentName ) | indent 8 }} {{- if hasKey $commonCtx.me "labels" }} diff --git a/version.cmake b/version.cmake index 64412a8589d..1952e234114 100644 --- a/version.cmake +++ b/version.cmake @@ -5,8 +5,8 @@ set ( HPCC_NAME "Community Edition" ) set ( HPCC_PROJECT "community" ) set ( HPCC_MAJOR 9 ) set ( HPCC_MINOR 4 ) -set ( HPCC_POINT 41 ) +set ( HPCC_POINT 43 ) set ( HPCC_MATURITY "closedown" ) set ( HPCC_SEQUENCE 0 ) -set ( HPCC_TAG_TIMESTAMP "2024-02-29T16:47:59Z" ) +set ( HPCC_TAG_TIMESTAMP "2024-03-07T17:32:39Z" ) ### From 98a711e4183feab2dc260cb5556c9b2d3adec18c Mon Sep 17 00:00:00 2001 From: Gordon Smith Date: Thu, 29 Feb 2024 16:52:11 +0000 Subject: [PATCH 7/7] HPCC-31379 Fix new OSX 13 compiler warnings Signed-off-by: Gordon Smith --- ecl/hql/CMakeLists.txt | 3 +++ ecl/hql/hqlexpr.cpp | 4 ++-- ecl/hqlcpp/hqlresource.cpp | 4 ++++ roxie/ccd/ccdqueue.cpp | 2 -- system/jlib/jdebug.cpp | 2 -- tools/hidl/hidlcomp.cpp | 2 -- 6 files changed, 9 insertions(+), 8 deletions(-) diff --git a/ecl/hql/CMakeLists.txt b/ecl/hql/CMakeLists.txt index f1a76567b09..32ea50dadaa 100644 --- a/ecl/hql/CMakeLists.txt +++ b/ecl/hql/CMakeLists.txt @@ -167,6 +167,9 @@ if (CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_CLANG) #Compiler complains about an unused function yyunput, and make sure that any warnings are not reported as errors set_source_files_properties (hqllex.cpp PROPERTIES COMPILE_FLAGS " -Wno-unused-function -Wno-error") + + #Compiler complains about a variable is set but not used + set_source_files_properties (hqlgram.cpp PROPERTIES COMPILE_FLAGS " -Wno-error=unused-but-set-variable -Wno-error=class-memaccess") endif() if (WIN32) diff --git a/ecl/hql/hqlexpr.cpp b/ecl/hql/hqlexpr.cpp index 57529bce0ae..82697abb382 100644 --- a/ecl/hql/hqlexpr.cpp +++ b/ecl/hql/hqlexpr.cpp @@ -1146,8 +1146,8 @@ void HqlParseContext::finishMeta(bool isSeparateFile, bool success, bool generat { #if 0 IPropertyTree* tos = curMeta().meta; -# This is disabled as the location of the cache file needs to be -# in the original location for now. This may re-visited in the future. +// This is disabled as the location of the cache file needs to be +// in the original location for now. This may re-visited in the future. if (isSeparateFile && hasCacheLocation()) { StringBuffer fullName; diff --git a/ecl/hqlcpp/hqlresource.cpp b/ecl/hqlcpp/hqlresource.cpp index 61bdc871029..3e722954d86 100644 --- a/ecl/hqlcpp/hqlresource.cpp +++ b/ecl/hqlcpp/hqlresource.cpp @@ -5549,7 +5549,9 @@ void EclResourcer::removeDuplicateIndependentLinks(CSplitterInfo & connections, ResourcerInfo & sinkInfo = *queryResourceInfo(sink); if (allInputsPulledIndependently(sink)) { +#ifdef TRACE_BALANCED unsigned numRemoved = 0; +#endif for (unsigned j=info.balancedLinks.ordinality()-1; j > i; j--) { CSplitterLink & next = info.balancedLinks.item(j); @@ -5557,7 +5559,9 @@ void EclResourcer::removeDuplicateIndependentLinks(CSplitterInfo & connections, { info.balancedLinks.remove(j); sinkInfo.balancedLinks.zap(next); +#ifdef TRACE_BALANCED numRemoved++; +#endif } } diff --git a/roxie/ccd/ccdqueue.cpp b/roxie/ccd/ccdqueue.cpp index 401d2334969..3b405034d3b 100644 --- a/roxie/ccd/ccdqueue.cpp +++ b/roxie/ccd/ccdqueue.cpp @@ -1262,7 +1262,6 @@ class RoxieQueue : public CInterface, implements IThreadFactory bool remove(RoxiePacketHeader &x) { - unsigned scanLength = 0; ISerializedRoxieQueryPacket *found = nullptr; { CriticalBlock qc(qcrit); @@ -1273,7 +1272,6 @@ class RoxieQueue : public CInterface, implements IThreadFactory ISerializedRoxieQueryPacket *queued = waiting.item(i); if (queued) { - scanLength++; if (queued->queryHeader().matchPacket(x)) { waiting.set(i, NULL); diff --git a/system/jlib/jdebug.cpp b/system/jlib/jdebug.cpp index 3aea22a4add..c5608e1b00f 100644 --- a/system/jlib/jdebug.cpp +++ b/system/jlib/jdebug.cpp @@ -3286,7 +3286,6 @@ void printProcMap(const char *fn, bool printbody, bool printsummary, StringBuffe } while (reader.nextln()) { const char *ln = reader.ln; - unsigned n=0; if (*ln) { offset_t start = readHexNum(ln); if (last&&(last!=start)) { @@ -3360,7 +3359,6 @@ void printProcMap(const char *fn, bool printbody, bool printsummary, StringBuffe recs[t].total += ssz; if (ssz>recs[t].largest) recs[t].largest = ssz; - n++; last = end; #ifndef __64BIT__ if ((end<0xffffffff)&&(end>=0xc0000000)) // rest is OS (32-bit only) diff --git a/tools/hidl/hidlcomp.cpp b/tools/hidl/hidlcomp.cpp index 93ec23cf067..f9dba61e2d7 100644 --- a/tools/hidl/hidlcomp.cpp +++ b/tools/hidl/hidlcomp.cpp @@ -2254,10 +2254,8 @@ void ModuleInfo::write_body_class() } outf("}, %d };\n\n",version); - int fn=0; for (ProcInfo *pi=procs; pi; pi=pi->next) { - fn++; pi->write_body_method_structs2(name); } outs("\n");