Skip to content

Commit

Permalink
JAVA-21601 | Using oracle Starter instead of Multiple dependencies. (e…
Browse files Browse the repository at this point in the history
  • Loading branch information
GaetanoPiazzolla authored Jun 30, 2023
1 parent 45c2efe commit 5ee991f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 16 deletions.
17 changes: 4 additions & 13 deletions persistence-modules/spring-boot-persistence-2/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -111,19 +111,10 @@
<artifactId>hsqldb</artifactId>
</dependency>
<dependency>
<groupId>com.oracle.database.jdbc</groupId>
<artifactId>ojdbc8</artifactId>
<version>${oracle-database.version}</version>
</dependency>
<dependency>
<groupId>com.oracle.database.ha</groupId>
<artifactId>ons</artifactId>
<version>${oracle-database.version}</version>
</dependency>
<dependency>
<groupId>com.oracle.database.jdbc</groupId>
<artifactId>ucp</artifactId>
<version>${oracle-database.version}</version>
<groupId>com.oracle.database.spring</groupId>
<artifactId>oracle-spring-boot-starter-ucp</artifactId>
<version>3.1.0</version> <!-- or 2.7.7 for Spring Boot 2.x -->
<type>pom</type>
</dependency>
</dependencies>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,15 @@
@RunWith(SpringRunner.class)
@SpringBootTest(classes = {SpringOraclePoolingApplication.class})
@ActiveProfiles({"oracle-pooling-basic"})
@TestPropertySource(properties = "spring.datasource.type=oracle.ucp.jdbc.UCPDataSource")
@TestPropertySource(properties = "spring.datasource.type=oracle.ucp.jdbc.PoolDataSource")
public class SpringOraclePoolingApplicationOracleUCPLiveTest {

@Autowired
private DataSource dataSource;

@Test
public void givenOracleUCPConfiguration_thenBuildsOraclePoolDataSource() {
assertTrue(dataSource instanceof oracle.ucp.jdbc.UCPDataSource);
assertTrue(dataSource instanceof oracle.ucp.jdbc.PoolDataSource);
}


}

0 comments on commit 5ee991f

Please sign in to comment.