You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spark.apache.org by do...@apache.org on 2019/01/08 01:54:20 UTC

[spark] branch master updated: [SPARK-26554][BUILD][FOLLOWUP] Use GitHub instead of GitBox to check HEADER

This is an automated email from the ASF dual-hosted git repository.

dongjoon pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/spark.git


The following commit(s) were added to refs/heads/master by this push:
     new 6f35ede  [SPARK-26554][BUILD][FOLLOWUP] Use GitHub instead of GitBox to check HEADER
6f35ede is described below

commit 6f35ede31cc72a81e3852b1ac7454589d1897bfc
Author: Dongjoon Hyun <do...@apache.org>
AuthorDate: Mon Jan 7 17:54:05 2019 -0800

    [SPARK-26554][BUILD][FOLLOWUP] Use GitHub instead of GitBox to check HEADER
    
    ## What changes were proposed in this pull request?
    
    This PR uses GitHub repository instead of GitBox because GitHub repo returns HTTP header status correctly.
    
    ## How was this patch tested?
    
    Manual.
    
    ```
    $ ./do-release-docker.sh -d /tmp/test -n
    Branch [branch-2.4]:
    Current branch version is 2.4.1-SNAPSHOT.
    Release [2.4.1]:
    RC # [1]:
    This is a dry run. Please confirm the ref that will be built for testing.
    Ref [v2.4.1-rc1]:
    ```
    
    Closes #23482 from dongjoon-hyun/SPARK-26554-2.
    
    Authored-by: Dongjoon Hyun <do...@apache.org>
    Signed-off-by: Dongjoon Hyun <do...@apache.org>
---
 dev/create-release/release-util.sh | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/dev/create-release/release-util.sh b/dev/create-release/release-util.sh
index 9a34052..5486c18 100755
--- a/dev/create-release/release-util.sh
+++ b/dev/create-release/release-util.sh
@@ -21,6 +21,7 @@ DRY_RUN=${DRY_RUN:-0}
 GPG="gpg --no-tty --batch"
 ASF_REPO="https://gitbox.apache.org/repos/asf/spark.git"
 ASF_REPO_WEBUI="https://gitbox.apache.org/repos/asf?p=spark.git"
+ASF_GITHUB_REPO="https://github.com/apache/spark"
 
 function error {
   echo "$*"
@@ -73,9 +74,7 @@ function fcreate_secure {
 }
 
 function check_for_tag {
-  # Check HTML body messages instead of header status codes. Apache GitBox returns
-  # a header with `200 OK` status code for both existing and non-existing tag URLs
-  ! curl -s --fail "$ASF_REPO_WEBUI;a=commit;h=$1" | grep '404 Not Found' > /dev/null
+  curl -s --head --fail "$ASF_GITHUB_REPO/releases/tag/$1" > /dev/null
 }
 
 function get_release_info {


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org