You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by vy...@apache.org on 2023/09/14 13:11:42 UTC

[logging-log4j-samples] branch main updated: Better workaround for non-reproducible `spring-boot:repackage`

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

vy pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/logging-log4j-samples.git


The following commit(s) were added to refs/heads/main by this push:
     new c0d6906  Better workaround for non-reproducible `spring-boot:repackage`
c0d6906 is described below

commit c0d69061e0a67b355b3c19e2be7b0091db531ef8
Author: Volkan Yazıcı <vo...@yazi.ci>
AuthorDate: Thu Sep 14 15:12:04 2023 +0200

    Better workaround for non-reproducible `spring-boot:repackage`
---
 .../pom.xml                                        | 29 ++++++++--------------
 1 file changed, 10 insertions(+), 19 deletions(-)

diff --git a/log4j-spring-cloud-config-sample-application/pom.xml b/log4j-spring-cloud-config-sample-application/pom.xml
index 76a91d0..2ea9909 100644
--- a/log4j-spring-cloud-config-sample-application/pom.xml
+++ b/log4j-spring-cloud-config-sample-application/pom.xml
@@ -29,6 +29,16 @@
 
   <name>Apache Log4j Samples: Spring Cloud Config App</name>
 
+  <properties>
+
+    <!-- `spring-boot:repackage` doesn't generate reproducible artifacts when `project.build.outputTimestamp` is set to `0`, which is inherited.
+         Hence, we are switching to a non-zero value.
+         There was an earlier reproducibility issue reported: https://github.com/spring-projects/spring-boot/issues/34424
+         Though apparently the fix isn't complete. -->
+    <project.build.outputTimestamp>2023-09-14T15:03:45Z</project.build.outputTimestamp>
+
+  </properties>
+
   <dependencies>
 
     <!-- Required for Async Loggers -->
@@ -184,23 +194,4 @@
     </plugins>
   </build>
 
-  <profiles>
-
-    <!-- Disable `spring-boot:repackage` in CI, since it doesn't produce reproducible artifacts.
-         This issue was reported earlier and (claimed to be) fixed in 2.7.10: https://github.com/spring-projects/spring-boot/issues/34424
-         Yet the fix doesn't help in our case. -->
-    <profile>
-      <id>spring-boot-repackage-disabler</id>
-      <activation>
-        <property>
-          <name>env.CI</name>
-        </property>
-      </activation>
-      <properties>
-        <spring-boot.repackage.skip>true</spring-boot.repackage.skip>
-      </properties>
-    </profile>
-
-  </profiles>
-
 </project>