Shawyeok commented on issue #23509: URL: https://github.com/apache/pulsar/issues/23509#issuecomment-2575598765
I believe @qmonmert 's major missing point is that you cannot override individual dependencies by using properties without [inheriting the starter parent POM](https://docs.spring.io/spring-boot/3.3/maven-plugin/using.html#:~:text=The%20preceding%20sample%20setup%20does%20not%20let%20you%20override%20individual%20dependencies%20by%20using%20properties). There is a quick fix for @qmonmert [example project](https://github.com/qmonmert/pulsarapp/tree/5cc5d52e02117945ffabf851394db1afb920af43): ```diff diff --git a/pom.xml b/pom.xml index 7448642..91defe1 100644 --- a/pom.xml +++ b/pom.xml @@ -1,7 +1,12 @@ <?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> - + <parent> + <groupId>org.springframework.boot</groupId> + <artifactId>spring-boot-starter-parent</artifactId> + <version>3.3.5</version> + <relativePath/> <!-- lookup parent from repository --> + </parent> <groupId>tech.jhipster.pulsarapp</groupId> <artifactId>pulsarapp</artifactId> <version>0.0.1-SNAPSHOT</version> @@ -10,13 +15,6 @@ <packaging>jar</packaging> <dependencyManagement> <dependencies> - <dependency> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-dependencies</artifactId> - <version>${spring-boot.version}</version> - <type>pom</type> - <scope>import</scope> - </dependency> </dependencies> </dependencyManagement> <dependencies> @@ -117,6 +115,7 @@ <properties-maven-plugin.version>1.2.1</properties-maven-plugin.version> <sonar-maven-plugin.version>4.0.0.4121</sonar-maven-plugin.version> <testcontainers.version>1.20.3</testcontainers.version> + <pulsar.version>4.0.1</pulsar.version> </properties> <build> ``` Additionally, there is an [article](https://spring.io/blog/2016/04/13/overriding-dependency-versions-with-spring-boot) on the Spring blog explaining this behavior in detail. I noticed this issue a while back, and now it popped up due to its close notification. Hope this helps! :-) -- 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]
