Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/candidate-9.10.x'
Browse files Browse the repository at this point in the history
Signed-off-by: Gordon Smith <[email protected]>

# Conflicts:
#	commons-hpcc/pom.xml
#	dfsclient/pom.xml
#	pom.xml
#	spark-hpcc/pom.xml
#	wsclient/pom.xml
  • Loading branch information
GordonSmith committed Jan 16, 2025
2 parents 54204ad + 4d096d6 commit bd30187
Show file tree
Hide file tree
Showing 5 changed files with 48 additions and 27 deletions.
32 changes: 20 additions & 12 deletions .github/workflows/JirabotMerge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,23 @@ jobs:
if: github.event.pull_request.merged == true
steps:
- name: "Debug Vars"
env:
JIRA_URL : ${{ vars.JIRA_URL }}
PULL_REQUEST_NUMBER : ${{ github.event.pull_request.number }}
PULL_REQUEST_TITLE : ${{ github.event.pull_request.title }}
PULL_REQUEST_AUTHOR_NAME : ${{ github.event.pull_request.user.login }}
PULL_URL: ${{ github.event.pull_request.html_url }}
COMMENTS_URL: ${{ github.event.pull_request.comments_url }}
BRANCH_NAME: ${{ github.ref_name }}
run: |
echo "JIRA_URL: ${{ vars.JIRA_URL }}"
echo "Pull Request Number: ${{ github.event.pull_request.number }}"
echo "Pull Request Title: ${{ github.event.pull_request.title }}"
echo "Pull Request Author Name: ${{ github.event.pull_request.user.login }}"
echo "Pull Request URL: ${{ github.event.pull_request.html_url }}"
echo "Comments URL: ${{ github.event.pull_request.comments_url }}"
echo "Branch Name: ${{ github.ref_name }}"
- uses: "actions/setup-python@v2"
echo "JIRA_URL: $JIRA_URL"
echo "Pull Request Number: $PULL_REQUEST_NUMBER"
echo "Pull Request Title: $PULL_REQUEST_TITLE"
echo "Pull Request Author Name: $PULL_REQUEST_AUTHOR_NAME"
echo "Pull Request URL: $PULL_URL"
echo "Comments URL: $COMMENTS_URL"
echo "Branch Name: $BRANCH_NAME"
- uses: "actions/setup-python@v5"
with:
python-version: "3.8"
- name: "Install dependencies"
Expand All @@ -33,7 +41,7 @@ jobs:
python -m pip install --upgrade atlassian-python-api
python -m pip install --upgrade jira
- name: "Checkout"
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.base.ref }}
fetch-depth: 0
Expand All @@ -51,6 +59,7 @@ jobs:
COMMENTS_URL: ${{ github.event.pull_request.comments_url }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH_NAME: ${{ github.ref_name }}
shell: python
run: |
import os
import re
Expand Down Expand Up @@ -255,7 +264,7 @@ jobs:
sys.exit(1)
project_prefixes = projectConfig.get('projectPrefixes')
if not project_prefixes:
if project_prefixes is None:
print('Error: PROJECT_CONFIG is missing required field: projectPrefixes. Add a "projectPrefixes" JSON array of project prefix strings to the PROJECT_CONFIG.')
sys.exit(1)
Expand Down Expand Up @@ -291,5 +300,4 @@ jobs:
else:
print('Unable to find Jira issue name in title')
print(result)
shell: python
print(result)
15 changes: 10 additions & 5 deletions .github/workflows/baremetal-regression-suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -129,11 +129,16 @@ jobs:
latestVersionStr = ".".join(map(str, latestVersion))
latestVersionURL = 'https://cdn.hpccsystems.com/releases/CE-Candidate-' + latestVersionStr \
+ '/bin/platform/hpccsystems-platform-community_' + latestVersionStr + '-1jammy_amd64_withsymbols.deb'
print(f"::set-output name=previousVersion::{previousVersionStr}")
print(f"::set-output name=previousVersionURL::{previousVersionURL}")
print(f"::set-output name=latestVersion::{latestVersionStr}")
print(f"::set-output name=latestVersionURL::{latestVersionURL}")
github_output_path = os.getenv('GITHUB_OUTPUT')
if github_output_path:
with open(github_output_path, 'a') as output_file:
output_file.write(f"previousVersion={previousVersionStr}\n")
output_file.write(f"previousVersionURL={previousVersionURL}\n")
output_file.write(f"latestVersion={latestVersionStr}\n")
output_file.write(f"latestVersionURL={latestVersionURL}\n")
else:
print('GITHUB_OUTPUT environment variable is not set.')
- name: Install latest version
run: |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -335,17 +335,19 @@ private static String[] getCredentials(CommandLine cmd)
{
Console console = System.console();

boolean nonInteractive = cmd.hasOption("non_interactive");

String user = cmd.getOptionValue("user");
boolean userIsEmpty = user == null || user.isEmpty();
if (userIsEmpty)
if (userIsEmpty && !nonInteractive)
{
user = new String(console.readLine("Enter username: "));
userIsEmpty = user == null || user.isEmpty();
}

String pass = cmd.getOptionValue("pass");
boolean passIsEmpty = pass == null || pass.isEmpty();
if (!userIsEmpty && passIsEmpty)
if (!userIsEmpty && passIsEmpty & !nonInteractive)
{
pass = new String(console.readPassword("Enter password for " + user + ": "));
}
Expand Down Expand Up @@ -642,6 +644,7 @@ private static Options getReadOptions()
options.addOption("socket_timeout_seconds", true, "Sets the socket operation timeout in seconds.");
options.addOption("connection_startup_limit", true, "Specifies the maximum number of connections to startup concurrently."
+ " useful in cases where starting up connections too quickly can overwhelm intermediate processes.");
options.addOption("non_interactive", false, "Disables prompting for credentials if they are not provided.");

options.addOption(Option.builder("read")
.argName("files")
Expand Down Expand Up @@ -672,6 +675,7 @@ private static Options getReadTestOptions()
options.addOption("socket_timeout_seconds", true, "Sets the socket operation timeout in seconds.");
options.addOption("connection_startup_limit", true, "Specifies the maximum number of connections to startup concurrently."
+ " useful in cases where starting up connections too quickly can overwhelm intermediate processes.");
options.addOption("non_interactive", false, "Disables prompting for credentials if they are not provided.");

options.addOption(Option.builder("file_parts")
.argName("_file_parts")
Expand All @@ -697,6 +701,7 @@ private static Options getCopyOptions()
options.addOption("socket_timeout_seconds", true, "Sets the socket operation timeout in seconds.");
options.addOption("connection_startup_limit", true, "Specifies the maximum number of connections to startup concurrently."
+ " useful in cases where starting up connections too quickly can overwhelm intermediate processes.");
options.addOption("non_interactive", false, "Disables prompting for credentials if they are not provided.");

options.addOption(Option.builder("copy")
.argName("files")
Expand All @@ -721,6 +726,7 @@ private static Options getWriteOptions()
options.addOption("socket_timeout_seconds", true, "Sets the socket operation timeout in seconds.");
options.addOption("connection_startup_limit", true, "Specifies the maximum number of connections to startup concurrently."
+ " useful in cases where starting up connections too quickly can overwhelm intermediate processes.");
options.addOption("non_interactive", false, "Disables prompting for credentials if they are not provided.");

options.addOption(Option.builder("write")
.argName("files")
Expand Down Expand Up @@ -1962,14 +1968,14 @@ private static void performCopy(String[] args, TaskContext context)
{
String readArgs[] = {"-read", srcFile, "-url", srcURL,
"-format", "thor", "-user", user, "-pass", pass,
"-out", "tmp-read"};
"-out", "tmp-read", "-non_interactive"};

performRead(readArgs, context);

String writeArgs[] = {"-write", "tmp-read" + File.separator + srcFile.replace(':', '_') + "*" + " " + destFile,
"-url", srcURL, "-dest_url", destURL,
"-dest_cluster", destClusterName,
"-user", user, "-pass", pass };
"-user", user, "-pass", pass, "-non_interactive"};

performWrite(writeArgs, context);
}
Expand Down Expand Up @@ -2280,4 +2286,4 @@ public static void main(String[] args)

return;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import org.junit.Assert;
import org.junit.Assume;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.experimental.categories.Category;

Expand Down Expand Up @@ -114,7 +115,8 @@ public void setup() throws Exception
}
}

@Test
// Ignoring this test until underlying TLK support changes have been made
@Ignore @Test
public void hpccTLKFilterTest() throws Exception
{
for (int i = 0; i < datasetNames.length; i++)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public void thorFileTests()
{
{
String readArgs[] = {"-read", "benchmark::integer::20kb", "-url", this.connString,
"-format", "thor", "-user", this.hpccUser, "-pass", this.hpccPass };
"-format", "thor", "-user", this.hpccUser, "-pass", this.hpccPass, "-non_interactive" };

JSONArray results = FileUtility.run(readArgs);
JSONObject result = results.optJSONObject(0);
Expand All @@ -58,7 +58,7 @@ public void thorFileTests()

{
String readArgs[] = {"-read_test", "benchmark::integer::20kb", "-url", this.connString,
"-user", this.hpccUser, "-pass", this.hpccPass, "-file_parts", "1" };
"-user", this.hpccUser, "-pass", this.hpccPass, "-file_parts", "1", "-non_interactive" };

JSONArray results = FileUtility.run(readArgs);
JSONObject result = results.optJSONObject(0);
Expand All @@ -72,7 +72,7 @@ public void thorFileTests()
String copyArgs[] = {"-copy", "benchmark::integer::20kb benchmark::integer::20kb-copy",
"-url", this.connString, "-dest_url", this.connString,
"-dest_cluster", this.thorClusterFileGroup,
"-user", this.hpccUser, "-pass", this.hpccPass };
"-user", this.hpccUser, "-pass", this.hpccPass, "-non_interactive" };

JSONArray results = FileUtility.run(copyArgs);
JSONObject result = results.optJSONObject(0);
Expand All @@ -87,7 +87,7 @@ public void thorFileTests()
String writeArgs[] = {"-write", localDir + "benchmark__integer__20kb* benchmark::integer::20kb_write",
"-url", this.connString, "-dest_url", this.connString,
"-dest_cluster", this.thorClusterFileGroup,
"-user", this.hpccUser, "-pass", this.hpccPass };
"-user", this.hpccUser, "-pass", this.hpccPass, "-non_interactive" };

JSONArray results = FileUtility.run(writeArgs);
JSONObject result = results.optJSONObject(0);
Expand Down

0 comments on commit bd30187

Please sign in to comment.