asterixdb-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Taewoo Kim (Code Review)" <do-not-re...@asterixdb.incubator.apache.org>
Subject Change in asterixdb[master]: ASTERIXDB-1088: fixed a secondary index compact issue
Date Sun, 28 Aug 2016 04:21:21 GMT
Taewoo Kim has uploaded a new change for review.

  https://asterix-gerrit.ics.uci.edu/1123

Change subject: ASTERIXDB-1088: fixed a secondary index compact issue
......................................................................

ASTERIXDB-1088: fixed a secondary index compact issue

 - Secondary index is now properly compacted

Change-Id: Ide9191fce61b767c08d2298070e64d455ee34f0b
---
M asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
1 file changed, 8 insertions(+), 3 deletions(-)


  git pull ssh://asterix-gerrit.ics.uci.edu:29418/asterixdb refs/changes/23/1123/1

diff --git a/asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
index 24c678c..6390b9d 100644
--- a/asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
+++ b/asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
@@ -2487,9 +2487,14 @@
             if (ds.getDatasetType() == DatasetType.INTERNAL) {
                 for (int j = 0; j < indexes.size(); j++) {
                     if (indexes.get(j).isSecondaryIndex()) {
-                        jobsToExecute
-                                .add(DatasetOperations.compactDatasetJobSpec(
-                                        dataverse, datasetName, metadataProvider));
+                        CompiledIndexCompactStatement cics = new CompiledIndexCompactStatement(dataverseName,
+                                datasetName, indexes.get(j).getIndexName(), indexes.get(j).getKeyFieldNames(),
+                                indexes.get(j).getKeyFieldTypes(), indexes.get(j).isEnforcingKeyFileds(),
+                                indexes.get(j).getGramLength(), indexes.get(j).getIndexType());
+                        List<Integer> keySourceIndicators = indexes.get(j).getKeyFieldSourceIndicators();
+
+                        jobsToExecute.add(IndexOperations.buildSecondaryIndexCompactJobSpec(cics,
aRecordType,
+                                metaRecordType, keySourceIndicators, enforcedType, metadataProvider));
                     }
                 }
             } else {

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1123
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ide9191fce61b767c08d2298070e64d455ee34f0b
Gerrit-PatchSet: 1
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Taewoo Kim <wangsaeu@yahoo.com>

Mime
View raw message