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

chitralverma pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/griffin.git


The following commit(s) were added to refs/heads/master by this push:
     new bb6ab36  [GRIFFIN-362] Add postgresql and oracle driver into 
dependencies
bb6ab36 is described below

commit bb6ab36cf6008d72fec3cfba29e7dfaccf5d966c
Author: lipzhu <[email protected]>
AuthorDate: Mon Jan 24 10:51:04 2022 +0530

    [GRIFFIN-362] Add postgresql and oracle driver into dependencies
    
    **What changes were proposed in this pull request?**
    1. Add Oracle and postgresql JDBC driver into dependencies in measure 
module due user report
    https://issues.apache.org/jira/browse/GRIFFIN-362
    2. Update postgresql jdbc driver version to the latest in service module.
    
    **Does this PR introduce any user-facing change?**
    No.
    
    How was this patch tested?
    Unit Tests
    
    Closes #597 from lipzhu/GRIFFIN-362.
    
    Authored-by: lipzhu <[email protected]>
    Signed-off-by: chitralverma <[email protected]>
---
 measure/pom.xml                                          | 16 ++++++++++++++++
 .../connector/batch/JDBCBasedDataConnectorTest.scala     |  4 ++--
 service/pom.xml                                          |  2 +-
 3 files changed, 19 insertions(+), 3 deletions(-)

diff --git a/measure/pom.xml b/measure/pom.xml
index 6d97107..7362c79 100644
--- a/measure/pom.xml
+++ b/measure/pom.xml
@@ -53,6 +53,8 @@ under the License.
         <scalaj.version>2.3.0</scalaj.version>
         <mongo.version>2.1.0</mongo.version>
         <curator.version>2.10.0</curator.version>
+        <postgresql.version>42.3.1</postgresql.version>
+        <ojdbc8.version>21.4.0.0.1</ojdbc8.version>
 
         <!-- Testing -->
         <scoverage.plugin.version>1.4.0</scoverage.plugin.version>
@@ -151,6 +153,20 @@ under the License.
             <version>${mysql.java.version}</version>
         </dependency>
 
+        <!-- PostgreSQL -->
+        <dependency>
+            <groupId>org.postgresql</groupId>
+            <artifactId>postgresql</artifactId>
+            <version>${postgresql.version}</version>
+        </dependency>
+
+        <!-- Oracle -->
+        <dependency>
+            <groupId>com.oracle.database.jdbc</groupId>
+            <artifactId>ojdbc8</artifactId>
+            <version>${ojdbc8.version}</version>
+        </dependency>
+
         <!-- MariaDB -->
         <dependency>
             <groupId>org.mariadb.jdbc</groupId>
diff --git 
a/measure/src/test/scala/org/apache/griffin/measure/datasource/connector/batch/JDBCBasedDataConnectorTest.scala
 
b/measure/src/test/scala/org/apache/griffin/measure/datasource/connector/batch/JDBCBasedDataConnectorTest.scala
index 8a755b6..acfac72 100644
--- 
a/measure/src/test/scala/org/apache/griffin/measure/datasource/connector/batch/JDBCBasedDataConnectorTest.scala
+++ 
b/measure/src/test/scala/org/apache/griffin/measure/datasource/connector/batch/JDBCBasedDataConnectorTest.scala
@@ -132,7 +132,7 @@ class JDBCBasedDataConnectorTest extends SparkSuiteBase 
with Matchers {
     } should have message "requirement failed: JDBC connection: password is 
mandatory"
   }
 
-  "JDBC data connector" should "have driver provided in config in classpath" 
in {
+  "JDBC data connector" should "have valid driver provided in config in 
classpath" in {
     the[AssertionError] thrownBy {
       val configs = Map(
         "database" -> "griffin",
@@ -140,7 +140,7 @@ class JDBCBasedDataConnectorTest extends SparkSuiteBase 
with Matchers {
         "tablename" -> "employee",
         "user" -> "user",
         "password" -> "password",
-        "driver" -> "org.postgresql.Driver")
+        "driver" -> "org.postgresql.InvalidDriver")
       JDBCBasedDataConnector(spark, dcParam.copy(config = configs), 
timestampStorage)
     }
   }
diff --git a/service/pom.xml b/service/pom.xml
index 8121998..b6325d6 100644
--- a/service/pom.xml
+++ b/service/pom.xml
@@ -44,7 +44,7 @@ under the License.
         <derby.version>10.14.1.0</derby.version>
         <eclipselink.version>2.6.0</eclipselink.version>
         <mysql.java.version>5.1.47</mysql.java.version>
-        <postgresql.version>9.4.1212.jre7</postgresql.version>
+        <postgresql.version>42.3.1</postgresql.version>
         <livy.core.version>0.3.0</livy.core.version>
         
<elasticsearch-rest-client.version>6.2.4</elasticsearch-rest-client.version>
         <jackson-databind.version>2.9.9.3</jackson-databind.version>

Reply via email to