You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by "Yingyi Bu (JIRA)" <ji...@apache.org> on 2016/04/19 02:47:25 UTC

[jira] [Created] (ASTERIXDB-1404) Field-level casting for loading enforced index

Yingyi Bu created ASTERIXDB-1404:
------------------------------------

             Summary: Field-level casting for loading enforced index
                 Key: ASTERIXDB-1404
                 URL: https://issues.apache.org/jira/browse/ASTERIXDB-1404
             Project: Apache AsterixDB
          Issue Type: Improvement
            Reporter: Yingyi Bu
            Assignee: Ildar Absalyamov


Currently loading an enforced secondary index needs to cast records [1] [2] [3] at the top level. It is not as efficient as only casting the indexed fields.

The utility is there [4]. We have cast-list [5] and cast-record [6], and adding a cast-flat is simple. The core code is shared. Then, the index load job can call those casts at field level instead of at the top-level.

[1] https://github.com/apache/incubator-asterixdb/blob/master/asterixdb/asterix-app/src/main/java/org/apache/asterix/file/SecondaryBTreeOperationsHelper.java#L148
[2] https://github.com/apache/incubator-asterixdb/blob/master/asterixdb/asterix-app/src/main/java/org/apache/asterix/file/SecondaryInvertedIndexOperationsHelper.java#L253
[3] https://github.com/apache/incubator-asterixdb/blob/master/asterixdb/asterix-app/src/main/java/org/apache/asterix/file/SecondaryRTreeOperationsHelper.java#L310
[4] https://github.com/apache/incubator-asterixdb/blob/master/asterixdb/asterix-om/src/main/java/org/apache/asterix/om/pointables/cast/ACastVisitor.java
[5] https://github.com/apache/incubator-asterixdb/blob/master/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/evaluators/functions/CastListDescriptor.java#L95
[6] https://github.com/apache/incubator-asterixdb/blob/master/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/evaluators/functions/CastRecordDescriptor.java#L89



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)