Github user cepiross commented on a diff in the pull request:

    https://github.com/apache/tajo/pull/39#discussion_r13847503
  
    --- Diff: 
tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/AbstractDBStore.java
 ---
    @@ -152,9 +152,20 @@ protected String getCatalogUri() {
         return catalogUri;
       }
     
    +  protected boolean isConnValid(int timeout) throws CatalogException {
    --- End diff --
    
    As @jihoonson stated, I experienced Tajo Session removal, indicating that 
MariaDB JDBC disconnection, when I tried to execute a query directly after 
dropping table schema, as following: 
    
    **NOTE! this log is only after applying latest TAJO-847 patch**
    2014-06-17 12:48:35,466 INFO org.apache.tajo.master.GlobalEngine: 
=============================================
    2014-06-17 12:48:35,489 INFO org.apache.tajo.catalog.CatalogServer: 
relation "linewalks.test" is deleted from the catalog (192.168.0.15:26005)
    2014-06-17 12:48:35,504 INFO org.apache.tajo.master.GlobalEngine: relation 
"linewalks.test" is  purged.
    2014-06-17 12:48:43,526 INFO org.apache.tajo.master.GlobalEngine: Query: 
select * from table20
    2014-06-17 12:48:43,526 INFO org.apache.tajo.master.GlobalEngine: 
hive.query.mode:false
    2014-06-17 12:48:43,529 INFO org.apache.tajo.catalog.store.MariaDBStore: 
Conn abortion when checking isValid; retrieve false to create another Conn.
    2014-06-17 12:48:43,565 INFO org.apache.tajo.master.GlobalEngine: 
=============================================
    2014-06-17 12:48:43,565 INFO org.apache.tajo.master.GlobalEngine: Optimized 
Query:
    …
    2014-06-17 12:48:43,565 INFO org.apache.tajo.master.GlobalEngine: 
=============================================
    2014-06-17 12:48:47,272 INFO org.apache.tajo.master.session.SessionManager: 
Session a1121c5d-51ea-4397-b345-e062cd32350f is removed.
    
    [Error description]
    In other words, the query sequence always incurs NullPointerException in 
invoking Conn.isValid method when using up-to-date MariaDB JDBC Connector.
    [Solution]
    To avoid the drawback, I have agreed with @jihoonson to insert 
MariaDBStore-specific NPE handling, isConnValid method; which is a temporal 
solution until MariaDB JDBC resolves disconnection issue.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to