Uploaded image for project: 'Atlas'
  1. Atlas
  2. ATLAS-492 Hive Hook Improvements
  3. ATLAS-778

ALTER TABLE TOUCH is not modelled

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 0.7-incubating
    • None
    • None
    • None

    Description

      ALTER TABLE TOUCH is not modelled.

      ALTER TABLE TOUCH changes metadata of hive table(like create time, transient_lastDdlTime). No entity update message is sent to atlas when table touch command is fired.

      0: jdbc:hive2://localhost:10000/default> describe formatted tg2;
      +-------------------------------+-----------------------------------------------------------------+-----------------------+--+
      |           col_name            |                            data_type                            |        comment        |
      +-------------------------------+-----------------------------------------------------------------+-----------------------+--+
      | # col_name                    | data_type                                                       | comment               |
      |                               | NULL                                                            | NULL                  |
      | abc                           | string                                                          |                       |
      |                               | NULL                                                            | NULL                  |
      | # Detailed Table Information  | NULL                                                            | NULL                  |
      | Database:                     | db2sdbxnpqone                                                   | NULL                  |
      | Owner:                        | apathan                                                         | NULL                  |
      | CreateTime:                   | Wed May 11 23:19:55 IST 2016                                    | NULL                  |
      | LastAccessTime:               | UNKNOWN                                                         | NULL                  |
      | Protect Mode:                 | None                                                            | NULL                  |
      | Retention:                    | 0                                                               | NULL                  |
      | Location:                     | hdfs://localhost:9000/user/hive/warehouse/db2sdbxnpqone.db/tg2  | NULL                  |
      | Table Type:                   | MANAGED_TABLE                                                   | NULL                  |
      | Table Parameters:             | NULL                                                            | NULL                  |
      |                               | transient_lastDdlTime                                           | 1462988995            |
      |                               | NULL                                                            | NULL                  |
      | # Storage Information         | NULL                                                            | NULL                  |
      | SerDe Library:                | org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe              | NULL                  |
      | InputFormat:                  | org.apache.hadoop.mapred.TextInputFormat                        | NULL                  |
      | OutputFormat:                 | org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat      | NULL                  |
      | Compressed:                   | No                                                              | NULL                  |
      | Num Buckets:                  | -1                                                              | NULL                  |
      | Bucket Columns:               | []                                                              | NULL                  |
      | Sort Columns:                 | []                                                              | NULL                  |
      | Storage Desc Params:          | NULL                                                            | NULL                  |
      |                               | serialization.format                                            | 1                     |
      +-------------------------------+-----------------------------------------------------------------+-----------------------+--+
      26 rows selected (0.113 seconds)
      0: jdbc:hive2://localhost:10000/default> alter table tg2 touch;
      No rows affected (0.173 seconds)
      0: jdbc:hive2://localhost:10000/default> describe formatted tg2;
      +-------------------------------+-----------------------------------------------------------------+-----------------------+--+
      |           col_name            |                            data_type                            |        comment        |
      +-------------------------------+-----------------------------------------------------------------+-----------------------+--+
      | # col_name                    | data_type                                                       | comment               |
      |                               | NULL                                                            | NULL                  |
      | abc                           | string                                                          |                       |
      |                               | NULL                                                            | NULL                  |
      | # Detailed Table Information  | NULL                                                            | NULL                  |
      | Database:                     | db2sdbxnpqone                                                   | NULL                  |
      | Owner:                        | apathan                                                         | NULL                  |
      | CreateTime:                   | Wed May 11 23:19:55 IST 2016                                    | NULL                  |
      | LastAccessTime:               | UNKNOWN                                                         | NULL                  |
      | Protect Mode:                 | None                                                            | NULL                  |
      | Retention:                    | 0                                                               | NULL                  |
      | Location:                     | hdfs://localhost:9000/user/hive/warehouse/db2sdbxnpqone.db/tg2  | NULL                  |
      | Table Type:                   | MANAGED_TABLE                                                   | NULL                  |
      | Table Parameters:             | NULL                                                            | NULL                  |
      |                               | COLUMN_STATS_ACCURATE                                           | false                 |
      |                               | numFiles                                                        | 0                     |
      |                               | numRows                                                         | -1                    |
      |                               | rawDataSize                                                     | -1                    |
      |                               | totalSize                                                       | 0                     |
      |                               | transient_lastDdlTime                                           | 1462989060            |
      |                               | NULL                                                            | NULL                  |
      | # Storage Information         | NULL                                                            | NULL                  |
      | SerDe Library:                | org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe              | NULL                  |
      | InputFormat:                  | org.apache.hadoop.mapred.TextInputFormat                        | NULL                  |
      | OutputFormat:                 | org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat      | NULL                  |
      | Compressed:                   | No                                                              | NULL                  |
      | Num Buckets:                  | -1                                                              | NULL                  |
      | Bucket Columns:               | []                                                              | NULL                  |
      | Sort Columns:                 | []                                                              | NULL                  |
      | Storage Desc Params:          | NULL                                                            | NULL                  |
      |                               | serialization.format                                            | 1                     |
      +-------------------------------+-----------------------------------------------------------------+-----------------------+--+
      31 rows selected (0.105 seconds)
      0: jdbc:hive2://localhost:10000/default>
      

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ayubpathan Ayub Pathan
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: