Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/candidate-9.6.x' into candidate-…
Browse files Browse the repository at this point in the history
…9.8.x

Signed-off-by: Gavin Halliday <gavin.halliday@lexisnexis.com>
  • Loading branch information
ghalliday committed Sep 20, 2024
2 parents 5e87d0d + d23810d commit 3a769b6
Show file tree
Hide file tree
Showing 42 changed files with 610 additions and 366 deletions.
1 change: 1 addition & 0 deletions cmake_modules/options.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ option(INSTALL_VCPKG_CATALOG "Install vcpkg-catalog.txt" ON)
option(PORTALURL "Set url to hpccsystems portal download page")
option(PROFILING "Set to true if planning to profile so stacks are informative" OFF)
option(COLLECT_SERVICE_METRICS "Set to true to gather metrics for HIDL services by default" OFF)
option(VCPKG_ECLBLAS_DYNAMIC_ARCH "Set to ON to build eclblas with dynamic architecture" ON)

set(CUSTOM_LABEL "" CACHE STRING "Appends a custom label to the final package name")

Expand Down
6 changes: 6 additions & 0 deletions cmake_modules/plugins.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,12 @@ if (USE_ZLIB)
set(VCPKG_ZLIB "${VCPKG_INCLUDE}")
endif()

if (VCPKG_ECLBLAS_DYNAMIC_ARCH)
set(VCPKG_ECLBLAS_DYNAMIC_ARCH_FEATURE "\"dynamic-arch\",")
else ()
set(VCPKG_ECLBLAS_DYNAMIC_ARCH_FEATURE "")
endif()

configure_file("${HPCC_SOURCE_DIR}/vcpkg.json.in" "${HPCC_SOURCE_DIR}/vcpkg.json")

endif()
4 changes: 3 additions & 1 deletion ecl/hql/hqlexpr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11030,7 +11030,9 @@ IHqlExpression *CHqlDelayedCall::clone(HqlExprArray &newkids)

IHqlExpression * CHqlDelayedCall::makeDelayedCall(IHqlExpression * _funcdef, HqlExprArray &operands)
{
ITypeInfo * returnType = _funcdef->queryType()->queryChildType();
ITypeInfo * funcType = _funcdef->queryType();
assertex(funcType->getTypeCode() == type_function);
ITypeInfo * returnType = funcType->queryChildType();
CHqlDelayedCall * ret;
switch (returnType->getTypeCode())
{
Expand Down
24 changes: 24 additions & 0 deletions ecl/hql/hqlgram2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3638,6 +3638,30 @@ IHqlExpression * HqlGram::implementInterfaceFromModule(const attribute & modpos,
{
HqlExprArray parameters;
bool isParametered = extractSymbolParameters(parameters, &baseSym);
if (baseSym.isFunction() != match->isFunction())
{
if (isParametered)
{
//Convert the value to a function definition - the parameters will be ignored
IHqlExpression * formals = queryFunctionParameters(&baseSym);
IHqlExpression * defaults = queryFunctionDefaults(&baseSym);
OwnedHqlExpr funcdef = createFunctionDefinition(id, LINK(match->queryBody()), LINK(formals), LINK(defaults), NULL);
match.setown(match->cloneAllAnnotations(funcdef));
}
else
{
//Convert a function into a value - possible if all parameters (including none) have default values
if (!allParametersHaveDefaults(match))
{
reportError(ERR_EXPECTED_ATTRIBUTE, ipos, "Symbol %s is defined as a value in the base scope, but a function with non-default parameters in the interface", str(id));
}
else
{
HqlExprArray actuals;
match.setown(createBoundFunction(nullptr, match, actuals, nullptr, false));
}
}
}

checkDerivedCompatible(id, newScopeExpr, match, isParametered, parameters, modpos);
newScope->defineSymbol(LINK(match));
Expand Down
50 changes: 50 additions & 0 deletions ecl/regress/iproject.ecl
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
/*##############################################################################
HPCC SYSTEMS software Copyright (C) 2024 HPCC Systems®.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
############################################################################## */

myModule := MODULE

EXPORT value1 := 100;
EXPORT value2 := 200;
EXPORT value3(unsigned x = 10) := 300;
EXPORT value4() := 400;

END;

myInterface := INTERFACE

EXPORT value1 := 0;
EXPORT value2(unsigned unknown) := 0;
EXPORT value3 := 0;
EXPORT value4() := 0;

END;



display(myInterface x) := FUNCTION
RETURN
ORDERED(
OUTPUT(x.value1);
OUTPUT(x.value2(99999));
OUTPUT(x.value3);
OUTPUT(x.value4());
);
END;


mappedModule := PROJECT(myModule, myInterface);
display(mappedModule);
50 changes: 50 additions & 0 deletions ecl/regress/iproject_err.ecl
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
/*##############################################################################
HPCC SYSTEMS software Copyright (C) 2024 HPCC Systems®.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
############################################################################## */

myModule := MODULE

EXPORT value1 := 100;
EXPORT value2 := 200;
EXPORT value3(unsigned i) := 300; // invalid - no default value supplied
EXPORT value4() := 400;

END;

myInterface := INTERFACE

EXPORT value1 := 0;
EXPORT value2() := 0;
EXPORT value3 := 0;
EXPORT value4() := 0;

END;



display(myInterface x) := FUNCTION
RETURN
ORDERED(
OUTPUT(x.value1);
OUTPUT(x.value2());
OUTPUT(x.value3);
OUTPUT(x.value4());
);
END;


mappedModule := PROJECT(myModule, myInterface);
display(mappedModule);
9 changes: 4 additions & 5 deletions esp/src/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions esp/src/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"@hpcc-js/chart": "2.84.1",
"@hpcc-js/codemirror": "2.63.0",
"@hpcc-js/common": "2.72.0",
"@hpcc-js/comms": "2.95.1",
"@hpcc-js/comms": "2.96.1",
"@hpcc-js/dataflow": "8.1.7",
"@hpcc-js/eclwatch": "2.75.3",
"@hpcc-js/graph": "2.86.0",
Expand Down Expand Up @@ -115,4 +115,4 @@
"type": "git",
"url": "https://github.com/hpcc-systems/HPCC-Platform"
}
}
}
31 changes: 16 additions & 15 deletions esp/src/src-react/components/Helpers.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import * as React from "react";
import { CommandBar, ContextualMenuItemType, ICommandBarItemProps, Link, ScrollablePane, Sticky } from "@fluentui/react";
import { CommandBar, ContextualMenuItemType, ICommandBarItemProps, Link } from "@fluentui/react";
import * as ESPRequest from "src/ESPRequest";
import nlsHPCC from "src/nlsHPCC";
import { HelperRow, useWorkunitHelpers } from "../hooks/workunit";
import { HolyGrail } from "../layouts/HolyGrail";
import { FluentGrid, useCopyButtons, useFluentStoreState, FluentColumns } from "./controls/Grid";
import { ShortVerticalDivider } from "./Common";

Expand Down Expand Up @@ -223,18 +224,18 @@ export const Helpers: React.FunctionComponent<HelpersProps> = ({
setData(helpers);
}, [helpers]);

return <ScrollablePane>
<Sticky>
<CommandBar items={buttons} farItems={copyButtons} />
</Sticky>
<FluentGrid
data={data}
primaryID={"id"}
alphaNumColumns={{ Value: true }}
columns={columns}
setSelection={setSelection}
setTotal={setTotal}
refresh={refreshTable}
></FluentGrid>
</ScrollablePane>;
return <HolyGrail
header={<CommandBar items={buttons} farItems={copyButtons} />}
main={
<FluentGrid
data={data}
primaryID={"id"}
alphaNumColumns={{ Value: true }}
columns={columns}
setSelection={setSelection}
setTotal={setTotal}
refresh={refreshTable}
></FluentGrid>
}
/>;
};
2 changes: 1 addition & 1 deletion esp/src/src-react/components/InfoGrid.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ export const InfoGrid: React.FunctionComponent<InfoGridProps> = ({
}
}, [data.length]);

return <div style={{ height: "100%" }}>
return <div style={{ height: "100%", overflow: "hidden" }}>
<CommandBar items={buttons} farItems={copyButtons} />
<SizeMe monitorHeight >{({ size }) =>
<FluentGrid
Expand Down
18 changes: 8 additions & 10 deletions esp/src/src-react/components/LogViewer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,16 +102,14 @@ export const LogViewer: React.FunctionComponent<LogViewerProps> = ({
return <HolyGrail
header={<CommandBar items={buttons} farItems={copyButtons} />}
main={
<div style={{ position: "relative", height: "100%" }}>
<FluentGrid
data={data}
primaryID={"dateTime"}
columns={columns}
setSelection={setSelection}
setTotal={setTotal}
refresh={refreshTable}
></FluentGrid>
</div>
<FluentGrid
data={data}
primaryID={"dateTime"}
columns={columns}
setSelection={setSelection}
setTotal={setTotal}
refresh={refreshTable}
></FluentGrid>
}
/>;
};
4 changes: 2 additions & 2 deletions esp/src/src-react/components/Logs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ export const Logs: React.FunctionComponent<LogsProps> = ({
return <HolyGrail
header={<CommandBar items={buttons} farItems={copyButtons} />}
main={
<>
<div style={{ position: "relative", height: "100%" }}>
<FluentPagedGrid
store={gridStore}
query={query}
Expand All @@ -200,7 +200,7 @@ export const Logs: React.FunctionComponent<LogsProps> = ({
refresh={refreshTable}
></FluentPagedGrid>
<Filter showFilter={showFilter} setShowFilter={setShowFilter} filterFields={filterFields} onApply={pushParams} />
</>
</div>
}
footer={<FluentPagedFooter
persistID={"cloudlogs"}
Expand Down
22 changes: 12 additions & 10 deletions esp/src/src-react/components/MetricsOptions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,16 +67,18 @@ const GridOptions: React.FunctionComponent<GridOptionsProps> = ({
}
}, [selectionHandler, strSelection]);

return <FluentGrid
data={data}
primaryID={"id"}
columns={columns}
selectionMode={SelectionMode.multiple}
setSelection={selectionHandler}
setTotal={setTotal}
refresh={refreshTable}
height={`${innerHeight}px`}
></FluentGrid>;
return <div style={{ position: "relative", height: 400 }}>
<FluentGrid
data={data}
primaryID={"id"}
columns={columns}
selectionMode={SelectionMode.multiple}
setSelection={selectionHandler}
setTotal={setTotal}
refresh={refreshTable}
height={`${innerHeight}px`}
></FluentGrid>
</div>;
};

interface AddLabelProps {
Expand Down
37 changes: 19 additions & 18 deletions esp/src/src-react/components/Resources.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import * as React from "react";
import { CommandBar, ContextualMenuItemType, ICommandBarItemProps, Link, ScrollablePane, Sticky } from "@fluentui/react";
import { CommandBar, ContextualMenuItemType, ICommandBarItemProps, Link } from "@fluentui/react";
import nlsHPCC from "src/nlsHPCC";
import { QuerySortItem } from "src/store/Store";
import { useWorkunitResources } from "../hooks/workunit";
import { updateParam } from "../util/history";
import { HolyGrail } from "../layouts/HolyGrail";
import { FluentGrid, useCopyButtons, useFluentStoreState, FluentColumns } from "./controls/Grid";
import { ShortVerticalDivider } from "./Common";
import { IFrame } from "./IFrame";
Expand Down Expand Up @@ -108,21 +109,21 @@ export const Resources: React.FunctionComponent<ResourcesProps> = ({
}));
}, [resources, wuid]);

return <ScrollablePane>
<Sticky>
<CommandBar items={buttons} farItems={copyButtons} />
</Sticky>
{preview && webUrl ?
<IFrame src={webUrl} /> :
<FluentGrid
data={data}
primaryID={"DisplayPath"}
alphaNumColumns={{ Value: true }}
sort={sort}
columns={columns}
setSelection={setSelection}
setTotal={setTotal}
refresh={refreshTable}
></FluentGrid>}
</ScrollablePane>;
return <HolyGrail
header={<CommandBar items={buttons} farItems={copyButtons} />}
main={
preview && webUrl ?
<IFrame src={webUrl} /> :
<FluentGrid
data={data}
primaryID={"DisplayPath"}
alphaNumColumns={{ Value: true }}
sort={sort}
columns={columns}
setSelection={setSelection}
setTotal={setTotal}
refresh={refreshTable}
></FluentGrid>
}
/>;
};
Loading

0 comments on commit 3a769b6

Please sign in to comment.