Below is my version info
<compiler-plugin.version>3.13.0</compiler-plugin.version><br>
<maven.compiler.release>21</maven.compiler.release><br>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding><br>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding><br>
<quarkus.platform.artifact-id>quarkus-bom</quarkus.platform.artifact-id><br>
<quarkus.platform.group-id>io.quarkus.platform</quarkus.platform.group-id><br>
<quarkus.platform.version>3.13.3</quarkus.platform.version>
I want to only inject a datasouce in my DAO and get the data manually..but it always showed the exception [ jakarta.enterprise.inject.spi.DeploymentException: jakarta.enterprise.inject.UnsatisfiedResolutionException: Unsatisfied dependency for type javax.sql.DataSource and qualifiers ]
I have added the DB definition on the application.properties.
Below the the code
The java source
@Inject
DataSource dataSource;
The properties
quarkus.datasource.enabled=true
quarkus.datasource.db-kind=postgresql
quarkus.datasource.jdbc.url=xxxxxx:5432/xxxxx
quarkus.datasource.username=xxxxx
quarkus.datasource.password=xxxxx
quarkus.datasource.jdbc.min-size=1
quarkus.datasource.jdbc.max-size=5
The pom.xml
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-jdbc-postgresql</artifactId>
</dependency>
I saw lots of examples with hibernate but I want to avoid it..is that possible?
1