From 114fa47171e666cfd2214cf436f99c267b6a2d7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A1=D0=B5=D1=80=D0=B3=D0=B5=D0=B9=20=D0=A6=D1=8B=D0=BF?= =?UTF-8?q?=D0=B0=D0=BD=D0=BE=D0=B2?= Date: Mon, 11 Oct 2021 10:55:00 +0300 Subject: [PATCH 1/3] Use Arrays.hashCode() in ByteArrayResource.hashCode() --- .../java/org/springframework/core/io/ByteArrayResource.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spring-core/src/main/java/org/springframework/core/io/ByteArrayResource.java b/spring-core/src/main/java/org/springframework/core/io/ByteArrayResource.java index 359d6b8574..6a2e666b6b 100644 --- a/spring-core/src/main/java/org/springframework/core/io/ByteArrayResource.java +++ b/spring-core/src/main/java/org/springframework/core/io/ByteArrayResource.java @@ -126,7 +126,7 @@ public class ByteArrayResource extends AbstractResource { */ @Override public int hashCode() { - return (byte[].class.hashCode() * 29 * this.byteArray.length); + return Arrays.hashCode(byteArray); } } From eb07dea7958b0314fc79ea4f4b5e8ce710c169ef Mon Sep 17 00:00:00 2001 From: Sam Brannen Date: Mon, 11 Oct 2021 15:31:40 +0200 Subject: [PATCH 2/3] Polish contribution See gh-27544 --- .../java/org/springframework/core/io/ByteArrayResource.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spring-core/src/main/java/org/springframework/core/io/ByteArrayResource.java b/spring-core/src/main/java/org/springframework/core/io/ByteArrayResource.java index 6a2e666b6b..c5989b8330 100644 --- a/spring-core/src/main/java/org/springframework/core/io/ByteArrayResource.java +++ b/spring-core/src/main/java/org/springframework/core/io/ByteArrayResource.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2018 the original author or authors. + * Copyright 2002-2021 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -126,7 +126,7 @@ public class ByteArrayResource extends AbstractResource { */ @Override public int hashCode() { - return Arrays.hashCode(byteArray); + return Arrays.hashCode(this.byteArray); } } From 83eac9af187c0151bf8039f1827649a8c3ca588f Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Mon, 11 Oct 2021 16:18:35 +0200 Subject: [PATCH 3/3] Upgrade CI to github-release resource 1.5.5 Closes gh-27459 --- ci/pipeline.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ci/pipeline.yml b/ci/pipeline.yml index b9fe3db2f9..64f6ffe3ad 100644 --- a/ci/pipeline.yml +++ b/ci/pipeline.yml @@ -46,6 +46,11 @@ resource_types: source: repository: springio/artifactory-resource tag: 0.0.17 +- name: github-release + type: registry-image + source: + repository: concourse/github-release-resource + tag: 1.5.5 - name: github-status-resource type: registry-image source: