Die Java Spring -Startanwendung "Siehe Abhängigkeit, es sei denn, dieses Abhängigkeits -Plugin wird mit spezifischen InfJava

Java-Forum
Anonymous
 Die Java Spring -Startanwendung "Siehe Abhängigkeit, es sei denn, dieses Abhängigkeits -Plugin wird mit spezifischen Inf

Post by Anonymous »

Ich habe eine Java Springboot -Anwendung, die ich als Abhängigkeit hinzugefügt habe. Nennen wir diese Anwendung A. Dieses abhängige Projekt ist eine API, die Controller -Klassen verwendet (@restcontroller Annotation). In meiner POM -Datei in der abhängigen Anwendung (aufrufen, nennen Sie es Anwendung b), wenn ich dieses Maven -Projekt wie unten (pom.1) erstelle, kann ich die Abhängigkeit, die ich hinzugefügt habe, nicht "sehen". Es sagt mir, dass "Symbol nicht beheben kann" [Paketname] ". Wenn ich jedoch die Plugin -Konfiguration von POM.2 unten verwende, wird die Abhängigkeit fein auflöst und baut. Warum ist das?

Code: Select all

2025-04-08T10:54:01,678 INFO  \[main\] o.s.b.StartupInfoLogger: Starting MerchantTerminalManagement using Java 1.8.0_341 on PCNAME-LPT with PID 3460 (C:\\Workarea\\Company\\merchant_terminal_management_microservice\\target\\classes started by Username in C:\\Workarea\\Company\\merchant_terminal_management_microservice\\dist)
2025-04-08T10:54:01,684 INFO  \[main\] o.s.b.SpringApplication: No active profile set, falling back to 1 default profile: "default"
2025-04-08T10:54:02,342 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationDelegate: Multiple Spring Data modules found, entering strict repository configuration mode
2025-04-08T10:54:02,345 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationDelegate: Bootstrapping Spring Data Redis repositories in DEFAULT mode.
2025-04-08T10:54:02,362 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationDelegate: Finished Spring Data repository scanning in 4 ms. Found 0 Redis repository interfaces.
2025-04-08T10:54:02,365 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationDelegate: Multiple Spring Data modules found, entering strict repository configuration mode
2025-04-08T10:54:02,365 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationDelegate: Bootstrapping Spring Data JPA repositories in DEFAULT mode.
2025-04-08T10:54:02,518 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationDelegate: Finished Spring Data repository scanning in 150 ms. Found 4 JPA repository interfaces.
2025-04-08T10:54:02,720 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationDelegate: Multiple Spring Data modules found, entering strict repository configuration mode
2025-04-08T10:54:02,720 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationDelegate: Bootstrapping Spring Data Redis repositories in DEFAULT mode.
2025-04-08T10:54:02,731 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.prepaid_utilities_switch.database.repository.ChannelsRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,734 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.prepaid_utilities_switch.database.repository.IMSCommonMessageRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,737 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.prepaid_utilities_switch.database.repository.IPPUCommonMessageRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,739 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.prepaid_utilities_switch.database.repository.ISupplierReconRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,741 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.prepaid_utilities_switch.database.repository.PrepaidUtilityMeterRoutingRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,742 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.prepaid_utilities_switch.database.repository.SupplierErrorMappingRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,743 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.prepaid_utilities_switch.database.repository.SupplierGroupRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,744 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.prepaid_utilities_switch.database.repository.UnknownMeterRepository;  If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,745 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.prepaid_utilities_switch.database.repository.UtilityMeterRoutingConfigRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,749 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.microservice.merchant_terminal_management.database.repositories.ParentEntityRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,749 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.microservice.merchant_terminal_management.database.repositories.SettlementConfigRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,749 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.microservice.merchant_terminal_management.database.repositories.SubEntityRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,750 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationExtensionSupport: Spring Data Redis - Could not safely identify store assignment for repository candidate interface za.co.Company.microservice.merchant_terminal_management.database.repositories.TerminalRepository; If you want this repository to be a Redis repository, consider annotating your entities with one of these annotations: org.springframework.data.redis.core.RedisHash (preferred), or consider extending one of the following types with your repository: org.springframework.data.keyvalue.repository.KeyValueRepository
2025-04-08T10:54:02,750 INFO  \[main\] o.s.d.r.c.RepositoryConfigurationDelegate: Finished Spring Data repository scanning in 29 ms. Found 0 Redis repository interfaces.
2025-04-08T10:54:03,402 INFO  \[main\] o.s.b.w.e.t.TomcatWebServer: Tomcat initialized with port(s): 3008 (http)
2025-04-08T10:54:03,409 INFO  \[main\] o.a.j.l.DirectJDKLog: Initializing ProtocolHandler \["http-nio-3008"\]
2025-04-08T10:54:03,410 INFO  \[main\] o.a.j.l.DirectJDKLog: Starting service \[Tomcat\]
2025-04-08T10:54:03,410 INFO  \[main\] o.a.j.l.DirectJDKLog: Starting Servlet engine: \[Apache Tomcat/9.0.65\]
2025-04-08T10:54:03,578 INFO  \[main\] o.a.j.l.DirectJDKLog: Initializing Spring embedded WebApplicationContext
2025-04-08T10:54:03,578 INFO  \[main\] o.s.b.w.s.c.ServletWebServerApplicationContext: Root WebApplicationContext: initialization completed in 1722 ms
2025-04-08T10:54:03,795 INFO  \[main\] o.h.j.i.u.LogHelper: HHH000204: Processing PersistenceUnitInfo \[name: default\]
2025-04-08T10:54:03,854 INFO  \[main\] o.h.Version: HHH000412: Hibernate ORM core version 5.6.10.Final
2025-04-08T10:54:04,034 INFO  \[main\] o.h.a.c.r.j.JavaReflectionManager: HCANN000001: Hibernate Commons Annotations {5.1.2.Final}
2025-04-08T10:54:04,589 INFO  \[main\] c.z.h.HikariDataSource: HikariPool-1 - Starting...
2025-04-08T10:54:04,872 INFO  \[main\] c.z.h.HikariDataSource: HikariPool-1 - Start completed.
2025-04-08T10:54:04,899 INFO  \[main\] o.h.d.Dialect: HHH000400: Using dialect: org.hibernate.dialect.PostgreSQL10Dialect
2025-04-08T10:54:04,933 INFO  \[main\] o.h.e.b.i.EnversServiceImpl: Envers integration enabled? : true
2025-04-08T10:54:05,498 INFO  \[main\] o.h.e.t.j.p.i.JtaPlatformInitiator: HHH000490: Using JtaPlatform implementation: \[org.hibernate.engine.transaction.jta.platform.internal.NoJtaPlatform\]
2025-04-08T10:54:05,505 INFO  \[main\] o.s.o.j.AbstractEntityManagerFactoryBean: Initialized JPA EntityManagerFactory for persistence unit 'default'
2025-04-08T10:54:05,521 WARN  \[main\] o.s.c.s.AbstractApplicationContext: Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'managementController' defined in URL \[jar:file:/C:/Users/Username/.m2/repository/za/co/Company/prepaid_utilities_switch/prepaid_utilities_switch/1.0/prepaid_utilities_switch-1.0.jar!/za/co/Company/prepaid_utilities_switch/controller/ManagementController.class\]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'managementControllerService' defined in URL \[jar:file:/C:/Users/Username/.m2/repository/za/co/Company/prepaid_utilities_switch/prepaid_utilities_switch/1.0/prepaid_utilities_switch-1.0.jar!/za/co/Company/prepaid_utilities_switch/service/ManagementControllerService.class\]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'PPUCommonMessageImplement' defined in URL \[jar:file:/C:/Users/Username/.m2/repository/za/co/Company/prepaid_utilities_switch/prepaid_utilities_switch/1.0/prepaid_utilities_switch-1.0.jar!/za/co/Company/prepaid_utilities_switch/database/service/PPUCommonMessageImplement.class\]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'za.co.Company.prepaid_utilities_switch.database.repository.IPPUCommonMessageRepository' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {}
2025-04-08T10:54:05,521 INFO  \[main\] o.s.o.j.AbstractEntityManagerFactoryBean: Closing JPA EntityManagerFactory for persistence unit 'default'
2025-04-08T10:54:05,523 INFO  \[main\] c.z.h.HikariDataSource: HikariPool-1 - Shutdown initiated...
2025-04-08T10:54:05,533 INFO  \[main\] c.z.h.HikariDataSource: HikariPool-1 - Shutdown completed.
2025-04-08T10:54:05,538 INFO  \[main\] o.a.j.l.DirectJDKLog: Stopping service \[Tomcat\]
2025-04-08T10:54:05,548 INFO  \[main\] o.s.b.a.l.ConditionEvaluationReportLoggingListener:

Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2025-04-08T10:54:05,572 ERROR \[main\] o.s.b.d.LoggingFailureAnalysisReporter:

\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*
APPLICATION FAILED TO START
\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*

Description:

Parameter 0 of constructor in za.co.Company.prepaid_utilities_switch.database.service.PPUCommonMessageImplement required a bean of type 'za.co.Company.prepaid_utilities_switch.database.repository.IPPUCommonMessageRepository' that could not be found.

Action:

Consider defining a bean of type 'za.co.Company.prepaid_utilities_switch.database.repository.IPPUCommonMessageRepository' in your configuration.

Disconnected from the target VM, address: '127.0.0.1:57379', transport: 'socket'

Process finished with exit code 1
< /code>
pom.1 extrahieren < /pbr /> 

org.springframework.boot
spring-boot-maven-plugin

true

`
< /code>
pom.2 extrahieren < /pbr /> 
org.springframework.boot
spring-boot-maven-plugin



repackage




executable
true


< /code>
Ich habe versucht, mit verschiedenen Komponenten- und Entitätscan -Annotationen, verschiedenen POM -Dateikonfigurationen zu erstellen, nichts zu funktionieren.@SpringBootApplication
@EnableQ2
@EntityScan("za.co.companyname.microservice.merchant_terminal_management*")
@EnableJpaRepositories("za.co.companyname.microservice.merchant_terminal_management*")
@ComponentScan("za.co.companyname.prepaid_utilities_switch*")

Quick Reply

Change Text Case: 
   
  • Similar Topics
    Replies
    Views
    Last post