imbajin commented on code in PR #787:
URL: 
https://github.com/apache/hugegraph-toolchain/pull/787#discussion_r4213960434


##########
.github/actions/setup-hugegraph-server/release.py:
##########
@@ -0,0 +1,88 @@
+#!/usr/bin/env python3
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with this
+# work for additional information regarding copyright ownership. The ASF
+# licenses this file to You 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.
+#
+"""Pinned ASF binary release identity and bounded download, without source 
fallback."""
+import hashlib
+import os
+import pathlib
+import subprocess
+import sys
+import tempfile
+
+VERSION = "1.7.0"
+REPOSITORY = "apache/hugegraph"
+COMMIT = "b12425c2032bf0d21a97b8221f42a18055c2982f"
+ARCHIVE_NAME = "apache-hugegraph-incubating-1.7.0.tar.gz"
+SOURCE_URL = "https://downloads.apache.org/hugegraph/1.7.0/"; + ARCHIVE_NAME

Review Comment:
   Fixed: a failed primary download now tries the official ASF archive for the 
same fixed release. Both paths enforce the pinned SHA-512 and canonical 
manifest identity; a checksum mismatch remains fatal. Added regression coverage 
for fallback identity and checksum failure without fallback. Latest CI is 
running.



##########
hugegraph-client/assembly/travis/install-candidate-sdk.sh:
##########
@@ -41,16 +41,22 @@ SERVER_FETCH_REF=${SERVER_FETCH_REF:-$1}
 export SERVER_REPOSITORY SERVER_FETCH_REF
 CANDIDATE_REPO=$3
 bash "$SCRIPT_DIR/checkout-server.sh" "$1" "$SOURCE_DIR"
-# Install the Server distribution's dependency reactor so all SDK modules 
share one source.
+# Install the SDK and Server distribution dependency closure from one source.
+# Server cluster tests pull an unrelated released Toolchain/SDK back into this 
build.
 # The fixture installers retain package-only semantics and use another 
repository.
-# Flatten the root too: license metadata rebuilds installed parent models, 
whose
-# raw ${revision} otherwise becomes an invalid artifact request outside the 
reactor.
+SDK_MODULES=hugegraph-server/hugegraph-dist,hugegraph-pd/hg-pd-client
+SDK_MODULES+=,hugegraph-store/hg-store-client,hugegraph-struct
+# Flatten the root too: its installed ${revision} otherwise breaks dependency
+# model reconstruction while remote-resources generates license metadata.
 (cd "$SOURCE_DIR" && mvn "-Dmaven.repo.local=$CANDIDATE_REPO" \
-    org.codehaus.mojo:flatten-maven-plugin:1.2.7:flatten install \
-    -pl hugegraph-server/hugegraph-dist -am \
+    -pl "$SDK_MODULES" -am \
+    org.codehaus.mojo:flatten-maven-plugin:1.3.0:flatten install \
     -Dflatten.mode=resolveCiFriendliesOnly -DupdatePomFile=true \
     -DskipTests -Dmaven.javadoc.skip=true -ntp)
 ACTUAL_COMMIT=$(git -C "$SOURCE_DIR" rev-parse HEAD)
+if [[ "$SERVER_FETCH_REF" =~ ^([0-9a-fA-F]{6}|[0-9a-fA-F]{40})$ ]]; then

Review Comment:
   Removed the unreachable six-character alternative. Machine locks remain 
complete Git identities; the existing branch/ref checkout verification is 
preserved.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to