incubator-blur-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From amccu...@apache.org
Subject [9/11] git commit: Changes to the api to the schema objects, still broken.
Date Thu, 10 Jan 2013 19:49:57 GMT
Changes to the api to the schema objects, still broken.


Project: http://git-wip-us.apache.org/repos/asf/incubator-blur/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-blur/commit/b5ea6935
Tree: http://git-wip-us.apache.org/repos/asf/incubator-blur/tree/b5ea6935
Diff: http://git-wip-us.apache.org/repos/asf/incubator-blur/diff/b5ea6935

Branch: refs/heads/0.2-dev
Commit: b5ea6935b101b4d767818a1e675f870370ea744c
Parents: 0e4ecb1
Author: Aaron McCurry <amccurry@gmail.com>
Authored: Thu Jan 10 13:01:11 2013 -0500
Committer: Aaron McCurry <amccurry@gmail.com>
Committed: Thu Jan 10 13:01:11 2013 -0500

----------------------------------------------------------------------
 .../java/org/apache/blur/thrift/BlurServer.java    |   28 +-
 .../apache/blur/thrift/generated/LiveSchema.java   |  631 ---------------
 .../src/main/scripts/interface/Blur.thrift         |   58 +-
 .../src/main/scripts/interface/gen-html/Blur.html  |   40 +-
 .../src/main/scripts/interface/gen-html/index.html |    3 +-
 .../apache/blur/thrift/generated/LiveSchema.java   |  631 ---------------
 .../main/scripts/interface/gen-perl/Blur/Blur.pm   |  434 ++++++-----
 .../main/scripts/interface/gen-perl/Blur/Types.pm  |  426 ++++++----
 .../src/main/scripts/interface/gen-rb/blur.rb      |   18 +-
 .../main/scripts/interface/gen-rb/blur_types.rb    |   44 +-
 10 files changed, 618 insertions(+), 1695 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/b5ea6935/src/blur-core/src/main/java/org/apache/blur/thrift/BlurServer.java
----------------------------------------------------------------------
diff --git a/src/blur-core/src/main/java/org/apache/blur/thrift/BlurServer.java b/src/blur-core/src/main/java/org/apache/blur/thrift/BlurServer.java
index 4a0b21e..76d30f8 100644
--- a/src/blur-core/src/main/java/org/apache/blur/thrift/BlurServer.java
+++ b/src/blur-core/src/main/java/org/apache/blur/thrift/BlurServer.java
@@ -25,7 +25,6 @@ import java.io.IOException;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collection;
-import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
 import java.util.Map.Entry;
@@ -53,9 +52,7 @@ import org.apache.blur.thrift.generated.Blur.Client;
 import org.apache.blur.thrift.generated.Blur.Iface;
 import org.apache.blur.thrift.generated.BlurException;
 import org.apache.blur.thrift.generated.Document;
-import org.apache.blur.thrift.generated.Field;
 import org.apache.blur.thrift.generated.Generation;
-import org.apache.blur.thrift.generated.LiveSchema;
 import org.apache.blur.thrift.generated.MutateOptions;
 import org.apache.blur.thrift.generated.Query;
 import org.apache.blur.thrift.generated.QueryArgs;
@@ -63,6 +60,7 @@ import org.apache.blur.thrift.generated.QueryStatus;
 import org.apache.blur.thrift.generated.Session;
 import org.apache.blur.thrift.generated.ShardLayout;
 import org.apache.blur.thrift.generated.TableDescriptor;
+import org.apache.blur.thrift.generated.TableSchema;
 import org.apache.blur.thrift.generated.TableStats;
 import org.apache.blur.thrift.generated.Term;
 import org.apache.blur.thrift.generated.TopFieldDocs;
@@ -72,7 +70,6 @@ import org.apache.blur.utils.BlurUtil;
 import org.apache.blur.utils.BlurValidations;
 import org.apache.blur.utils.ThriftLuceneConversion;
 import org.apache.lucene.index.IndexReader;
-import org.apache.lucene.index.IndexableField;
 import org.apache.lucene.search.IndexSearcher;
 import org.apache.thrift.TException;
 
@@ -203,10 +200,6 @@ public class BlurServer extends TableAdmin implements Iface {
   @Override
   public List<TopFieldDocs> search(final Session session, final QueryArgs queryArgs) throws BlurException, TException {
     SessionInfo info = getSessionInfo(session);
-    if (info == null) {
-      newSession(session.getTableName(), session.getSessionId());
-      info = getSessionInfo(session);
-    }
     try {
       Map<Integer, IndexSearcher> searchers = info.getSearchers();
       List<Integer> shardIndexes = queryArgs.getShardIndexes();
@@ -233,7 +226,7 @@ public class BlurServer extends TableAdmin implements Iface {
           futures.add(future);
         } else if (action.type == ACTION.REMOTE) {
           // @TODO need to send only one call per server, instead of one for
-          // each shard server
+          // each shard in the table
           final Connection connection = action.remoteServer;
           Future<TopFieldDocs> future = _indexSearcherExecutor.submit(new Callable<TopFieldDocs>() {
             @Override
@@ -310,8 +303,13 @@ public class BlurServer extends TableAdmin implements Iface {
     return searchersToSearch;
   }
 
-  private SessionInfo getSessionInfo(Session session) {
-    return sessions.get(session.getSessionId());
+  private SessionInfo getSessionInfo(Session session) throws BlurException {
+    SessionInfo info = sessions.get(session.getSessionId());
+    if (info == null) {
+      newSession(session.getTableName(), session.getSessionId());
+      return getSessionInfo(session);
+    }
+    return info;
   }
 
   @Override
@@ -345,7 +343,6 @@ public class BlurServer extends TableAdmin implements Iface {
     // TODO Make more efficient by making a single call to a server for many
     // docLocations
     String table = session.getTableName();
-    System.out.println(table + " " + shardIndex);
     Connection connection = getConnection(table, shardIndex);
     return BlurClientManager.execute(connection, new BlurCommand<List<Document>>() {
       @Override
@@ -528,7 +525,12 @@ public class BlurServer extends TableAdmin implements Iface {
   }
 
   @Override
-  public LiveSchema schema(String table) throws BlurException, TException {
+  public TableSchema schema(Session session, List<Integer> shardIds) throws BlurException, TException {
+    SessionInfo info = getSessionInfo(session);
+    
+    
+    
+    
     throw new BlurException("Not implemented", null);
   }
 

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/b5ea6935/src/blur-thrift/src/main/java/org/apache/blur/thrift/generated/LiveSchema.java
----------------------------------------------------------------------
diff --git a/src/blur-thrift/src/main/java/org/apache/blur/thrift/generated/LiveSchema.java b/src/blur-thrift/src/main/java/org/apache/blur/thrift/generated/LiveSchema.java
deleted file mode 100644
index a00a3b8..0000000
--- a/src/blur-thrift/src/main/java/org/apache/blur/thrift/generated/LiveSchema.java
+++ /dev/null
@@ -1,631 +0,0 @@
-/**
- * Autogenerated by Thrift Compiler (0.9.0)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.blur.thrift.generated;
-
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * 
- */
-public class LiveSchema implements org.apache.thrift.TBase<LiveSchema, LiveSchema._Fields>, java.io.Serializable, Cloneable {
-  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("LiveSchema");
-
-  private static final org.apache.thrift.protocol.TField TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("table", org.apache.thrift.protocol.TType.STRING, (short)1);
-  private static final org.apache.thrift.protocol.TField COLUMN_FAMILIES_FIELD_DESC = new org.apache.thrift.protocol.TField("columnFamilies", org.apache.thrift.protocol.TType.MAP, (short)2);
-
-  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-  static {
-    schemes.put(StandardScheme.class, new LiveSchemaStandardSchemeFactory());
-    schemes.put(TupleScheme.class, new LiveSchemaTupleSchemeFactory());
-  }
-
-  /**
-   * 
-   */
-  public String table; // required
-  /**
-   * 
-   */
-  public Map<String,Set<String>> columnFamilies; // required
-
-  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-    /**
-     * 
-     */
-    TABLE((short)1, "table"),
-    /**
-     * 
-     */
-    COLUMN_FAMILIES((short)2, "columnFamilies");
-
-    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-    static {
-      for (_Fields field : EnumSet.allOf(_Fields.class)) {
-        byName.put(field.getFieldName(), field);
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, or null if its not found.
-     */
-    public static _Fields findByThriftId(int fieldId) {
-      switch(fieldId) {
-        case 1: // TABLE
-          return TABLE;
-        case 2: // COLUMN_FAMILIES
-          return COLUMN_FAMILIES;
-        default:
-          return null;
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, throwing an exception
-     * if it is not found.
-     */
-    public static _Fields findByThriftIdOrThrow(int fieldId) {
-      _Fields fields = findByThriftId(fieldId);
-      if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-      return fields;
-    }
-
-    /**
-     * Find the _Fields constant that matches name, or null if its not found.
-     */
-    public static _Fields findByName(String name) {
-      return byName.get(name);
-    }
-
-    private final short _thriftId;
-    private final String _fieldName;
-
-    _Fields(short thriftId, String fieldName) {
-      _thriftId = thriftId;
-      _fieldName = fieldName;
-    }
-
-    public short getThriftFieldId() {
-      return _thriftId;
-    }
-
-    public String getFieldName() {
-      return _fieldName;
-    }
-  }
-
-  // isset id assignments
-  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-  static {
-    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-    tmpMap.put(_Fields.TABLE, new org.apache.thrift.meta_data.FieldMetaData("table", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.COLUMN_FAMILIES, new org.apache.thrift.meta_data.FieldMetaData("columnFamilies", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-        new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
-            new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
-            new org.apache.thrift.meta_data.SetMetaData(org.apache.thrift.protocol.TType.SET, 
-                new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)))));
-    metaDataMap = Collections.unmodifiableMap(tmpMap);
-    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(LiveSchema.class, metaDataMap);
-  }
-
-  public LiveSchema() {
-  }
-
-  public LiveSchema(
-    String table,
-    Map<String,Set<String>> columnFamilies)
-  {
-    this();
-    this.table = table;
-    this.columnFamilies = columnFamilies;
-  }
-
-  /**
-   * Performs a deep copy on <i>other</i>.
-   */
-  public LiveSchema(LiveSchema other) {
-    if (other.isSetTable()) {
-      this.table = other.table;
-    }
-    if (other.isSetColumnFamilies()) {
-      Map<String,Set<String>> __this__columnFamilies = new HashMap<String,Set<String>>();
-      for (Map.Entry<String, Set<String>> other_element : other.columnFamilies.entrySet()) {
-
-        String other_element_key = other_element.getKey();
-        Set<String> other_element_value = other_element.getValue();
-
-        String __this__columnFamilies_copy_key = other_element_key;
-
-        Set<String> __this__columnFamilies_copy_value = new HashSet<String>();
-        for (String other_element_value_element : other_element_value) {
-          __this__columnFamilies_copy_value.add(other_element_value_element);
-        }
-
-        __this__columnFamilies.put(__this__columnFamilies_copy_key, __this__columnFamilies_copy_value);
-      }
-      this.columnFamilies = __this__columnFamilies;
-    }
-  }
-
-  public LiveSchema deepCopy() {
-    return new LiveSchema(this);
-  }
-
-  @Override
-  public void clear() {
-    this.table = null;
-    this.columnFamilies = null;
-  }
-
-  /**
-   * 
-   */
-  public String getTable() {
-    return this.table;
-  }
-
-  /**
-   * 
-   */
-  public LiveSchema setTable(String table) {
-    this.table = table;
-    return this;
-  }
-
-  public void unsetTable() {
-    this.table = null;
-  }
-
-  /** Returns true if field table is set (has been assigned a value) and false otherwise */
-  public boolean isSetTable() {
-    return this.table != null;
-  }
-
-  public void setTableIsSet(boolean value) {
-    if (!value) {
-      this.table = null;
-    }
-  }
-
-  public int getColumnFamiliesSize() {
-    return (this.columnFamilies == null) ? 0 : this.columnFamilies.size();
-  }
-
-  public void putToColumnFamilies(String key, Set<String> val) {
-    if (this.columnFamilies == null) {
-      this.columnFamilies = new HashMap<String,Set<String>>();
-    }
-    this.columnFamilies.put(key, val);
-  }
-
-  /**
-   * 
-   */
-  public Map<String,Set<String>> getColumnFamilies() {
-    return this.columnFamilies;
-  }
-
-  /**
-   * 
-   */
-  public LiveSchema setColumnFamilies(Map<String,Set<String>> columnFamilies) {
-    this.columnFamilies = columnFamilies;
-    return this;
-  }
-
-  public void unsetColumnFamilies() {
-    this.columnFamilies = null;
-  }
-
-  /** Returns true if field columnFamilies is set (has been assigned a value) and false otherwise */
-  public boolean isSetColumnFamilies() {
-    return this.columnFamilies != null;
-  }
-
-  public void setColumnFamiliesIsSet(boolean value) {
-    if (!value) {
-      this.columnFamilies = null;
-    }
-  }
-
-  public void setFieldValue(_Fields field, Object value) {
-    switch (field) {
-    case TABLE:
-      if (value == null) {
-        unsetTable();
-      } else {
-        setTable((String)value);
-      }
-      break;
-
-    case COLUMN_FAMILIES:
-      if (value == null) {
-        unsetColumnFamilies();
-      } else {
-        setColumnFamilies((Map<String,Set<String>>)value);
-      }
-      break;
-
-    }
-  }
-
-  public Object getFieldValue(_Fields field) {
-    switch (field) {
-    case TABLE:
-      return getTable();
-
-    case COLUMN_FAMILIES:
-      return getColumnFamilies();
-
-    }
-    throw new IllegalStateException();
-  }
-
-  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-  public boolean isSet(_Fields field) {
-    if (field == null) {
-      throw new IllegalArgumentException();
-    }
-
-    switch (field) {
-    case TABLE:
-      return isSetTable();
-    case COLUMN_FAMILIES:
-      return isSetColumnFamilies();
-    }
-    throw new IllegalStateException();
-  }
-
-  @Override
-  public boolean equals(Object that) {
-    if (that == null)
-      return false;
-    if (that instanceof LiveSchema)
-      return this.equals((LiveSchema)that);
-    return false;
-  }
-
-  public boolean equals(LiveSchema that) {
-    if (that == null)
-      return false;
-
-    boolean this_present_table = true && this.isSetTable();
-    boolean that_present_table = true && that.isSetTable();
-    if (this_present_table || that_present_table) {
-      if (!(this_present_table && that_present_table))
-        return false;
-      if (!this.table.equals(that.table))
-        return false;
-    }
-
-    boolean this_present_columnFamilies = true && this.isSetColumnFamilies();
-    boolean that_present_columnFamilies = true && that.isSetColumnFamilies();
-    if (this_present_columnFamilies || that_present_columnFamilies) {
-      if (!(this_present_columnFamilies && that_present_columnFamilies))
-        return false;
-      if (!this.columnFamilies.equals(that.columnFamilies))
-        return false;
-    }
-
-    return true;
-  }
-
-  @Override
-  public int hashCode() {
-    return 0;
-  }
-
-  public int compareTo(LiveSchema other) {
-    if (!getClass().equals(other.getClass())) {
-      return getClass().getName().compareTo(other.getClass().getName());
-    }
-
-    int lastComparison = 0;
-    LiveSchema typedOther = (LiveSchema)other;
-
-    lastComparison = Boolean.valueOf(isSetTable()).compareTo(typedOther.isSetTable());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetTable()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.table, typedOther.table);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetColumnFamilies()).compareTo(typedOther.isSetColumnFamilies());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetColumnFamilies()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.columnFamilies, typedOther.columnFamilies);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    return 0;
-  }
-
-  public _Fields fieldForId(int fieldId) {
-    return _Fields.findByThriftId(fieldId);
-  }
-
-  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-    schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-  }
-
-  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-    schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-  }
-
-  @Override
-  public String toString() {
-    StringBuilder sb = new StringBuilder("LiveSchema(");
-    boolean first = true;
-
-    sb.append("table:");
-    if (this.table == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.table);
-    }
-    first = false;
-    if (!first) sb.append(", ");
-    sb.append("columnFamilies:");
-    if (this.columnFamilies == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.columnFamilies);
-    }
-    first = false;
-    sb.append(")");
-    return sb.toString();
-  }
-
-  public void validate() throws org.apache.thrift.TException {
-    // check for required fields
-    // check for sub-struct validity
-  }
-
-  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-    try {
-      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-    try {
-      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private static class LiveSchemaStandardSchemeFactory implements SchemeFactory {
-    public LiveSchemaStandardScheme getScheme() {
-      return new LiveSchemaStandardScheme();
-    }
-  }
-
-  private static class LiveSchemaStandardScheme extends StandardScheme<LiveSchema> {
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot, LiveSchema struct) throws org.apache.thrift.TException {
-      org.apache.thrift.protocol.TField schemeField;
-      iprot.readStructBegin();
-      while (true)
-      {
-        schemeField = iprot.readFieldBegin();
-        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
-          break;
-        }
-        switch (schemeField.id) {
-          case 1: // TABLE
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.table = iprot.readString();
-              struct.setTableIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 2: // COLUMN_FAMILIES
-            if (schemeField.type == org.apache.thrift.protocol.TType.MAP) {
-              {
-                org.apache.thrift.protocol.TMap _map10 = iprot.readMapBegin();
-                struct.columnFamilies = new HashMap<String,Set<String>>(2*_map10.size);
-                for (int _i11 = 0; _i11 < _map10.size; ++_i11)
-                {
-                  String _key12; // required
-                  Set<String> _val13; // optional
-                  _key12 = iprot.readString();
-                  {
-                    org.apache.thrift.protocol.TSet _set14 = iprot.readSetBegin();
-                    _val13 = new HashSet<String>(2*_set14.size);
-                    for (int _i15 = 0; _i15 < _set14.size; ++_i15)
-                    {
-                      String _elem16; // required
-                      _elem16 = iprot.readString();
-                      _val13.add(_elem16);
-                    }
-                    iprot.readSetEnd();
-                  }
-                  struct.columnFamilies.put(_key12, _val13);
-                }
-                iprot.readMapEnd();
-              }
-              struct.setColumnFamiliesIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          default:
-            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-        }
-        iprot.readFieldEnd();
-      }
-      iprot.readStructEnd();
-
-      // check for required fields of primitive type, which can't be checked in the validate method
-      struct.validate();
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot, LiveSchema struct) throws org.apache.thrift.TException {
-      struct.validate();
-
-      oprot.writeStructBegin(STRUCT_DESC);
-      if (struct.table != null) {
-        oprot.writeFieldBegin(TABLE_FIELD_DESC);
-        oprot.writeString(struct.table);
-        oprot.writeFieldEnd();
-      }
-      if (struct.columnFamilies != null) {
-        oprot.writeFieldBegin(COLUMN_FAMILIES_FIELD_DESC);
-        {
-          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.SET, struct.columnFamilies.size()));
-          for (Map.Entry<String, Set<String>> _iter17 : struct.columnFamilies.entrySet())
-          {
-            oprot.writeString(_iter17.getKey());
-            {
-              oprot.writeSetBegin(new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.STRING, _iter17.getValue().size()));
-              for (String _iter18 : _iter17.getValue())
-              {
-                oprot.writeString(_iter18);
-              }
-              oprot.writeSetEnd();
-            }
-          }
-          oprot.writeMapEnd();
-        }
-        oprot.writeFieldEnd();
-      }
-      oprot.writeFieldStop();
-      oprot.writeStructEnd();
-    }
-
-  }
-
-  private static class LiveSchemaTupleSchemeFactory implements SchemeFactory {
-    public LiveSchemaTupleScheme getScheme() {
-      return new LiveSchemaTupleScheme();
-    }
-  }
-
-  private static class LiveSchemaTupleScheme extends TupleScheme<LiveSchema> {
-
-    @Override
-    public void write(org.apache.thrift.protocol.TProtocol prot, LiveSchema struct) throws org.apache.thrift.TException {
-      TTupleProtocol oprot = (TTupleProtocol) prot;
-      BitSet optionals = new BitSet();
-      if (struct.isSetTable()) {
-        optionals.set(0);
-      }
-      if (struct.isSetColumnFamilies()) {
-        optionals.set(1);
-      }
-      oprot.writeBitSet(optionals, 2);
-      if (struct.isSetTable()) {
-        oprot.writeString(struct.table);
-      }
-      if (struct.isSetColumnFamilies()) {
-        {
-          oprot.writeI32(struct.columnFamilies.size());
-          for (Map.Entry<String, Set<String>> _iter19 : struct.columnFamilies.entrySet())
-          {
-            oprot.writeString(_iter19.getKey());
-            {
-              oprot.writeI32(_iter19.getValue().size());
-              for (String _iter20 : _iter19.getValue())
-              {
-                oprot.writeString(_iter20);
-              }
-            }
-          }
-        }
-      }
-    }
-
-    @Override
-    public void read(org.apache.thrift.protocol.TProtocol prot, LiveSchema struct) throws org.apache.thrift.TException {
-      TTupleProtocol iprot = (TTupleProtocol) prot;
-      BitSet incoming = iprot.readBitSet(2);
-      if (incoming.get(0)) {
-        struct.table = iprot.readString();
-        struct.setTableIsSet(true);
-      }
-      if (incoming.get(1)) {
-        {
-          org.apache.thrift.protocol.TMap _map21 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.SET, iprot.readI32());
-          struct.columnFamilies = new HashMap<String,Set<String>>(2*_map21.size);
-          for (int _i22 = 0; _i22 < _map21.size; ++_i22)
-          {
-            String _key23; // required
-            Set<String> _val24; // optional
-            _key23 = iprot.readString();
-            {
-              org.apache.thrift.protocol.TSet _set25 = new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
-              _val24 = new HashSet<String>(2*_set25.size);
-              for (int _i26 = 0; _i26 < _set25.size; ++_i26)
-              {
-                String _elem27; // required
-                _elem27 = iprot.readString();
-                _val24.add(_elem27);
-              }
-            }
-            struct.columnFamilies.put(_key23, _val24);
-          }
-        }
-        struct.setColumnFamiliesIsSet(true);
-      }
-    }
-  }
-
-}
-

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/b5ea6935/src/distribution/src/main/scripts/interface/Blur.thrift
----------------------------------------------------------------------
diff --git a/src/distribution/src/main/scripts/interface/Blur.thrift b/src/distribution/src/main/scripts/interface/Blur.thrift
index f88dbf2..ba97f88 100644
--- a/src/distribution/src/main/scripts/interface/Blur.thrift
+++ b/src/distribution/src/main/scripts/interface/Blur.thrift
@@ -201,17 +201,36 @@ struct TableStats {
 }
 
 /**
- *
+ * The field schema contains the name the type and some simple statistics about the field.
  */
-struct LiveSchema {
-  /**
-   *
-   */
-  1:string table,
-  /**
-   *
-   */
-  2:map<string,set<string>> columnFamilies
+struct FieldSchema {
+ /**
+  * The name of the field.
+  */
+ 1:string name,
+ /**
+  * The type of the field.
+  */
+ 2:TYPE type,
+ /**
+  * This is an estimate of the number of terms present in the index.  This is a naive 
+  * estimate, it is a sum of all the terms in each of the segments in each of the shards.
+  */
+ 3:i64 numberOfTermsEstimate,
+ /**
+  * The number of shards in which this field exists.
+  */
+ 4:i32 shardExistence
+}
+
+/**
+ * TableSchema contains field information that describes the a table.
+ */
+struct TableSchema {
+ /**
+  * List of field information for a table.
+  */
+ 1:list<FieldSchema> fields
 }
 
 struct ClassDefinition {
@@ -682,28 +701,33 @@ service Blur {
   /**
    * Cancels a query that is executing against the given table with the given uuid.
    * NOTE, the cancel call maybe take some time for the query actually stops executing.
-   * @param table the table name.
-   * @param uuid the uuid of the query.
+   * @param session the Session.
+   * @param id the uuid of the query.
    */
   void cancelQuery(1:Session session, 2:i64 id) throws (1:BlurException ex)
 
   /**
    * Returns a list of the query ids of queries that have recently been executed for the given table.
-   * @param table the table name.
+   * @param session the Session.
    * @return the uuids of the query status objects.
    */
   list<i64> queryStatusIdList(1:Session session) throws (1:BlurException ex)
 
   /**
    * Returns the query status for the given table and query uuid.
-   * @param table the table name.
-   * @param uuid the uuid of the query.
+   * @param session the Session.
+   * @param id the uuid of the query.
    * @return the query status for the given.
    */
   QueryStatus queryStatus(1:Session session, 2:i64 id) throws (1:BlurException ex)
 
-  //TODO
-  LiveSchema schema(1:string table) throws (1:BlurException ex)
+  /**
+   * Returns the the schema for the given session.
+   * @param session the Session.
+   * @param list of shard ids to fetch the schema.
+   * @return the table schema.
+   */
+  TableSchema schema(1:Session session, 2:list<i32> shardsIds) throws (1:BlurException ex)
 
   //TODO
   TableStats tableStats(1:string table) throws (1:BlurException ex)

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/b5ea6935/src/distribution/src/main/scripts/interface/gen-html/Blur.html
----------------------------------------------------------------------
diff --git a/src/distribution/src/main/scripts/interface/gen-html/Blur.html b/src/distribution/src/main/scripts/interface/gen-html/Blur.html
index e69ab15..1757951 100644
--- a/src/distribution/src/main/scripts/interface/gen-html/Blur.html
+++ b/src/distribution/src/main/scripts/interface/gen-html/Blur.html
@@ -45,8 +45,8 @@
 <a href="Blur.html#Struct_CpuTime">CpuTime</a><br/>
 <a href="Blur.html#Struct_Document">Document</a><br/>
 <a href="Blur.html#Struct_Field">Field</a><br/>
+<a href="Blur.html#Struct_FieldSchema">FieldSchema</a><br/>
 <a href="Blur.html#Struct_Generation">Generation</a><br/>
-<a href="Blur.html#Struct_LiveSchema">LiveSchema</a><br/>
 <a href="Blur.html#Struct_MutateOptions">MutateOptions</a><br/>
 <a href="Blur.html#Struct_Query">Query</a><br/>
 <a href="Blur.html#Struct_QueryArgs">QueryArgs</a><br/>
@@ -61,6 +61,7 @@
 <a href="Blur.html#Enum_SortType">SortType</a><br/>
 <a href="Blur.html#Enum_TYPE">TYPE</a><br/>
 <a href="Blur.html#Struct_TableDescriptor">TableDescriptor</a><br/>
+<a href="Blur.html#Struct_TableSchema">TableSchema</a><br/>
 <a href="Blur.html#Struct_TableStats">TableStats</a><br/>
 <a href="Blur.html#Struct_Term">Term</a><br/>
 <a href="Blur.html#Struct_TopFieldDocs">TopFieldDocs</a><br/>
@@ -146,13 +147,23 @@ trace (if any).
 <tr><td>3</td><td>queries</td><td><code>i64</code></td><td>
 </td><td>default</td><td></td></tr>
 </table><br/><p/>
-<br/></div><div class="definition"><h3 id="Struct_LiveSchema">Struct: LiveSchema</h3>
+<br/></div><div class="definition"><h3 id="Struct_FieldSchema">Struct: FieldSchema</h3>
 <table class="table-bordered table-striped table-condensed"><thead><th>Key</th><th>Field</th><th>Type</th><th>Description</th><th>Requiredness</th><th>Default value</th></thead>
-<tr><td>1</td><td>table</td><td><code>string</code></td><td>
+<tr><td>1</td><td>name</td><td><code>string</code></td><td>The name of the field.
 </td><td>default</td><td></td></tr>
-<tr><td>2</td><td>columnFamilies</td><td><code>map&lt;<code>string</code>, <code>set&lt;<code>string</code>&gt;</code>&gt;</code></td><td>
+<tr><td>2</td><td>type</td><td><code><a href="Blur.html#Enum_TYPE">TYPE</a></code></td><td>The type of the field.
 </td><td>default</td><td></td></tr>
-</table><br/><p/>
+<tr><td>3</td><td>numberOfTermsEstimate</td><td><code>i64</code></td><td>This is an estimate of the number of terms present in the index.  This is a naive
+estimate, it is a sum of all the terms in each of the segments in each of the shards.
+</td><td>default</td><td></td></tr>
+<tr><td>4</td><td>shardExistence</td><td><code>i32</code></td><td>The number of shards in which this field exists.
+</td><td>default</td><td></td></tr>
+</table><br/>The field schema contains the name the type and some simple statistics about the field.
+<br/></div><div class="definition"><h3 id="Struct_TableSchema">Struct: TableSchema</h3>
+<table class="table-bordered table-striped table-condensed"><thead><th>Key</th><th>Field</th><th>Type</th><th>Description</th><th>Requiredness</th><th>Default value</th></thead>
+<tr><td>1</td><td>fields</td><td><code>list&lt;<code><a href="Blur.html#Struct_FieldSchema">FieldSchema</a></code>&gt;</code></td><td>List of field information for a table.
+</td><td>default</td><td></td></tr>
+</table><br/>TableSchema contains field information that describes the a table.
 <br/></div><div class="definition"><h3 id="Struct_ClassDefinition">Struct: ClassDefinition</h3>
 <table class="table-bordered table-striped table-condensed"><thead><th>Key</th><th>Field</th><th>Type</th><th>Description</th><th>Requiredness</th><th>Default value</th></thead>
 <tr><td>1</td><td>className</td><td><code>string</code></td><td></td><td>default</td><td></td></tr>
@@ -467,26 +478,31 @@ block until natural refresh occurs.
     throws <code><a href="Blur.html#Struct_BlurException">BlurException</a></code>
 </pre>Cancels a query that is executing against the given table with the given uuid.
 NOTE, the cancel call maybe take some time for the query actually stops executing.
-@param table the table name.
-@param uuid the uuid of the query.
+@param session the Session.
+@param id the uuid of the query.
 <br/></div><div class="definition"><h4 id="Fn_Blur_queryStatusIdList">Function: Blur.queryStatusIdList</h4>
 <pre><code>list&lt;<code>i64</code>&gt;</code> queryStatusIdList(<code><a href="Blur.html#Struct_Session">Session</a></code> session)
     throws <code><a href="Blur.html#Struct_BlurException">BlurException</a></code>
 </pre>Returns a list of the query ids of queries that have recently been executed for the given table.
-@param table the table name.
+@param session the Session.
 @return the uuids of the query status objects.
 <br/></div><div class="definition"><h4 id="Fn_Blur_queryStatus">Function: Blur.queryStatus</h4>
 <pre><code><a href="Blur.html#Struct_QueryStatus">QueryStatus</a></code> queryStatus(<code><a href="Blur.html#Struct_Session">Session</a></code> session,
                         <code>i64</code> id)
     throws <code><a href="Blur.html#Struct_BlurException">BlurException</a></code>
 </pre>Returns the query status for the given table and query uuid.
-@param table the table name.
-@param uuid the uuid of the query.
+@param session the Session.
+@param id the uuid of the query.
 @return the query status for the given.
 <br/></div><div class="definition"><h4 id="Fn_Blur_schema">Function: Blur.schema</h4>
-<pre><code><a href="Blur.html#Struct_LiveSchema">LiveSchema</a></code> schema(<code>string</code> table)
+<pre><code><a href="Blur.html#Struct_TableSchema">TableSchema</a></code> schema(<code><a href="Blur.html#Struct_Session">Session</a></code> session,
+                   <code>list&lt;<code>i32</code>&gt;</code> shardsIds)
     throws <code><a href="Blur.html#Struct_BlurException">BlurException</a></code>
-</pre></div><div class="definition"><h4 id="Fn_Blur_tableStats">Function: Blur.tableStats</h4>
+</pre>Returns the the schema for the given session.
+@param session the Session.
+@param list of shard ids to fetch the schema.
+@return the table schema.
+<br/></div><div class="definition"><h4 id="Fn_Blur_tableStats">Function: Blur.tableStats</h4>
 <pre><code><a href="Blur.html#Struct_TableStats">TableStats</a></code> tableStats(<code>string</code> table)
     throws <code><a href="Blur.html#Struct_BlurException">BlurException</a></code>
 </pre></div></div></body></html>

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/b5ea6935/src/distribution/src/main/scripts/interface/gen-html/index.html
----------------------------------------------------------------------
diff --git a/src/distribution/src/main/scripts/interface/gen-html/index.html b/src/distribution/src/main/scripts/interface/gen-html/index.html
index 45d5a40..d2c0701 100644
--- a/src/distribution/src/main/scripts/interface/gen-html/index.html
+++ b/src/distribution/src/main/scripts/interface/gen-html/index.html
@@ -41,8 +41,8 @@
 <a href="Blur.html#Struct_CpuTime">CpuTime</a><br/>
 <a href="Blur.html#Struct_Document">Document</a><br/>
 <a href="Blur.html#Struct_Field">Field</a><br/>
+<a href="Blur.html#Struct_FieldSchema">FieldSchema</a><br/>
 <a href="Blur.html#Struct_Generation">Generation</a><br/>
-<a href="Blur.html#Struct_LiveSchema">LiveSchema</a><br/>
 <a href="Blur.html#Struct_MutateOptions">MutateOptions</a><br/>
 <a href="Blur.html#Struct_Query">Query</a><br/>
 <a href="Blur.html#Struct_QueryArgs">QueryArgs</a><br/>
@@ -57,6 +57,7 @@
 <a href="Blur.html#Enum_SortType">SortType</a><br/>
 <a href="Blur.html#Enum_TYPE">TYPE</a><br/>
 <a href="Blur.html#Struct_TableDescriptor">TableDescriptor</a><br/>
+<a href="Blur.html#Struct_TableSchema">TableSchema</a><br/>
 <a href="Blur.html#Struct_TableStats">TableStats</a><br/>
 <a href="Blur.html#Struct_Term">Term</a><br/>
 <a href="Blur.html#Struct_TopFieldDocs">TopFieldDocs</a><br/>

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/b5ea6935/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/LiveSchema.java
----------------------------------------------------------------------
diff --git a/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/LiveSchema.java b/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/LiveSchema.java
deleted file mode 100644
index a00a3b8..0000000
--- a/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/LiveSchema.java
+++ /dev/null
@@ -1,631 +0,0 @@
-/**
- * Autogenerated by Thrift Compiler (0.9.0)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.blur.thrift.generated;
-
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * 
- */
-public class LiveSchema implements org.apache.thrift.TBase<LiveSchema, LiveSchema._Fields>, java.io.Serializable, Cloneable {
-  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("LiveSchema");
-
-  private static final org.apache.thrift.protocol.TField TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("table", org.apache.thrift.protocol.TType.STRING, (short)1);
-  private static final org.apache.thrift.protocol.TField COLUMN_FAMILIES_FIELD_DESC = new org.apache.thrift.protocol.TField("columnFamilies", org.apache.thrift.protocol.TType.MAP, (short)2);
-
-  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-  static {
-    schemes.put(StandardScheme.class, new LiveSchemaStandardSchemeFactory());
-    schemes.put(TupleScheme.class, new LiveSchemaTupleSchemeFactory());
-  }
-
-  /**
-   * 
-   */
-  public String table; // required
-  /**
-   * 
-   */
-  public Map<String,Set<String>> columnFamilies; // required
-
-  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-    /**
-     * 
-     */
-    TABLE((short)1, "table"),
-    /**
-     * 
-     */
-    COLUMN_FAMILIES((short)2, "columnFamilies");
-
-    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-    static {
-      for (_Fields field : EnumSet.allOf(_Fields.class)) {
-        byName.put(field.getFieldName(), field);
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, or null if its not found.
-     */
-    public static _Fields findByThriftId(int fieldId) {
-      switch(fieldId) {
-        case 1: // TABLE
-          return TABLE;
-        case 2: // COLUMN_FAMILIES
-          return COLUMN_FAMILIES;
-        default:
-          return null;
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, throwing an exception
-     * if it is not found.
-     */
-    public static _Fields findByThriftIdOrThrow(int fieldId) {
-      _Fields fields = findByThriftId(fieldId);
-      if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-      return fields;
-    }
-
-    /**
-     * Find the _Fields constant that matches name, or null if its not found.
-     */
-    public static _Fields findByName(String name) {
-      return byName.get(name);
-    }
-
-    private final short _thriftId;
-    private final String _fieldName;
-
-    _Fields(short thriftId, String fieldName) {
-      _thriftId = thriftId;
-      _fieldName = fieldName;
-    }
-
-    public short getThriftFieldId() {
-      return _thriftId;
-    }
-
-    public String getFieldName() {
-      return _fieldName;
-    }
-  }
-
-  // isset id assignments
-  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-  static {
-    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-    tmpMap.put(_Fields.TABLE, new org.apache.thrift.meta_data.FieldMetaData("table", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.COLUMN_FAMILIES, new org.apache.thrift.meta_data.FieldMetaData("columnFamilies", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-        new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
-            new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
-            new org.apache.thrift.meta_data.SetMetaData(org.apache.thrift.protocol.TType.SET, 
-                new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)))));
-    metaDataMap = Collections.unmodifiableMap(tmpMap);
-    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(LiveSchema.class, metaDataMap);
-  }
-
-  public LiveSchema() {
-  }
-
-  public LiveSchema(
-    String table,
-    Map<String,Set<String>> columnFamilies)
-  {
-    this();
-    this.table = table;
-    this.columnFamilies = columnFamilies;
-  }
-
-  /**
-   * Performs a deep copy on <i>other</i>.
-   */
-  public LiveSchema(LiveSchema other) {
-    if (other.isSetTable()) {
-      this.table = other.table;
-    }
-    if (other.isSetColumnFamilies()) {
-      Map<String,Set<String>> __this__columnFamilies = new HashMap<String,Set<String>>();
-      for (Map.Entry<String, Set<String>> other_element : other.columnFamilies.entrySet()) {
-
-        String other_element_key = other_element.getKey();
-        Set<String> other_element_value = other_element.getValue();
-
-        String __this__columnFamilies_copy_key = other_element_key;
-
-        Set<String> __this__columnFamilies_copy_value = new HashSet<String>();
-        for (String other_element_value_element : other_element_value) {
-          __this__columnFamilies_copy_value.add(other_element_value_element);
-        }
-
-        __this__columnFamilies.put(__this__columnFamilies_copy_key, __this__columnFamilies_copy_value);
-      }
-      this.columnFamilies = __this__columnFamilies;
-    }
-  }
-
-  public LiveSchema deepCopy() {
-    return new LiveSchema(this);
-  }
-
-  @Override
-  public void clear() {
-    this.table = null;
-    this.columnFamilies = null;
-  }
-
-  /**
-   * 
-   */
-  public String getTable() {
-    return this.table;
-  }
-
-  /**
-   * 
-   */
-  public LiveSchema setTable(String table) {
-    this.table = table;
-    return this;
-  }
-
-  public void unsetTable() {
-    this.table = null;
-  }
-
-  /** Returns true if field table is set (has been assigned a value) and false otherwise */
-  public boolean isSetTable() {
-    return this.table != null;
-  }
-
-  public void setTableIsSet(boolean value) {
-    if (!value) {
-      this.table = null;
-    }
-  }
-
-  public int getColumnFamiliesSize() {
-    return (this.columnFamilies == null) ? 0 : this.columnFamilies.size();
-  }
-
-  public void putToColumnFamilies(String key, Set<String> val) {
-    if (this.columnFamilies == null) {
-      this.columnFamilies = new HashMap<String,Set<String>>();
-    }
-    this.columnFamilies.put(key, val);
-  }
-
-  /**
-   * 
-   */
-  public Map<String,Set<String>> getColumnFamilies() {
-    return this.columnFamilies;
-  }
-
-  /**
-   * 
-   */
-  public LiveSchema setColumnFamilies(Map<String,Set<String>> columnFamilies) {
-    this.columnFamilies = columnFamilies;
-    return this;
-  }
-
-  public void unsetColumnFamilies() {
-    this.columnFamilies = null;
-  }
-
-  /** Returns true if field columnFamilies is set (has been assigned a value) and false otherwise */
-  public boolean isSetColumnFamilies() {
-    return this.columnFamilies != null;
-  }
-
-  public void setColumnFamiliesIsSet(boolean value) {
-    if (!value) {
-      this.columnFamilies = null;
-    }
-  }
-
-  public void setFieldValue(_Fields field, Object value) {
-    switch (field) {
-    case TABLE:
-      if (value == null) {
-        unsetTable();
-      } else {
-        setTable((String)value);
-      }
-      break;
-
-    case COLUMN_FAMILIES:
-      if (value == null) {
-        unsetColumnFamilies();
-      } else {
-        setColumnFamilies((Map<String,Set<String>>)value);
-      }
-      break;
-
-    }
-  }
-
-  public Object getFieldValue(_Fields field) {
-    switch (field) {
-    case TABLE:
-      return getTable();
-
-    case COLUMN_FAMILIES:
-      return getColumnFamilies();
-
-    }
-    throw new IllegalStateException();
-  }
-
-  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-  public boolean isSet(_Fields field) {
-    if (field == null) {
-      throw new IllegalArgumentException();
-    }
-
-    switch (field) {
-    case TABLE:
-      return isSetTable();
-    case COLUMN_FAMILIES:
-      return isSetColumnFamilies();
-    }
-    throw new IllegalStateException();
-  }
-
-  @Override
-  public boolean equals(Object that) {
-    if (that == null)
-      return false;
-    if (that instanceof LiveSchema)
-      return this.equals((LiveSchema)that);
-    return false;
-  }
-
-  public boolean equals(LiveSchema that) {
-    if (that == null)
-      return false;
-
-    boolean this_present_table = true && this.isSetTable();
-    boolean that_present_table = true && that.isSetTable();
-    if (this_present_table || that_present_table) {
-      if (!(this_present_table && that_present_table))
-        return false;
-      if (!this.table.equals(that.table))
-        return false;
-    }
-
-    boolean this_present_columnFamilies = true && this.isSetColumnFamilies();
-    boolean that_present_columnFamilies = true && that.isSetColumnFamilies();
-    if (this_present_columnFamilies || that_present_columnFamilies) {
-      if (!(this_present_columnFamilies && that_present_columnFamilies))
-        return false;
-      if (!this.columnFamilies.equals(that.columnFamilies))
-        return false;
-    }
-
-    return true;
-  }
-
-  @Override
-  public int hashCode() {
-    return 0;
-  }
-
-  public int compareTo(LiveSchema other) {
-    if (!getClass().equals(other.getClass())) {
-      return getClass().getName().compareTo(other.getClass().getName());
-    }
-
-    int lastComparison = 0;
-    LiveSchema typedOther = (LiveSchema)other;
-
-    lastComparison = Boolean.valueOf(isSetTable()).compareTo(typedOther.isSetTable());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetTable()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.table, typedOther.table);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetColumnFamilies()).compareTo(typedOther.isSetColumnFamilies());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetColumnFamilies()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.columnFamilies, typedOther.columnFamilies);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    return 0;
-  }
-
-  public _Fields fieldForId(int fieldId) {
-    return _Fields.findByThriftId(fieldId);
-  }
-
-  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-    schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-  }
-
-  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-    schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-  }
-
-  @Override
-  public String toString() {
-    StringBuilder sb = new StringBuilder("LiveSchema(");
-    boolean first = true;
-
-    sb.append("table:");
-    if (this.table == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.table);
-    }
-    first = false;
-    if (!first) sb.append(", ");
-    sb.append("columnFamilies:");
-    if (this.columnFamilies == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.columnFamilies);
-    }
-    first = false;
-    sb.append(")");
-    return sb.toString();
-  }
-
-  public void validate() throws org.apache.thrift.TException {
-    // check for required fields
-    // check for sub-struct validity
-  }
-
-  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-    try {
-      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-    try {
-      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private static class LiveSchemaStandardSchemeFactory implements SchemeFactory {
-    public LiveSchemaStandardScheme getScheme() {
-      return new LiveSchemaStandardScheme();
-    }
-  }
-
-  private static class LiveSchemaStandardScheme extends StandardScheme<LiveSchema> {
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot, LiveSchema struct) throws org.apache.thrift.TException {
-      org.apache.thrift.protocol.TField schemeField;
-      iprot.readStructBegin();
-      while (true)
-      {
-        schemeField = iprot.readFieldBegin();
-        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
-          break;
-        }
-        switch (schemeField.id) {
-          case 1: // TABLE
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.table = iprot.readString();
-              struct.setTableIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 2: // COLUMN_FAMILIES
-            if (schemeField.type == org.apache.thrift.protocol.TType.MAP) {
-              {
-                org.apache.thrift.protocol.TMap _map10 = iprot.readMapBegin();
-                struct.columnFamilies = new HashMap<String,Set<String>>(2*_map10.size);
-                for (int _i11 = 0; _i11 < _map10.size; ++_i11)
-                {
-                  String _key12; // required
-                  Set<String> _val13; // optional
-                  _key12 = iprot.readString();
-                  {
-                    org.apache.thrift.protocol.TSet _set14 = iprot.readSetBegin();
-                    _val13 = new HashSet<String>(2*_set14.size);
-                    for (int _i15 = 0; _i15 < _set14.size; ++_i15)
-                    {
-                      String _elem16; // required
-                      _elem16 = iprot.readString();
-                      _val13.add(_elem16);
-                    }
-                    iprot.readSetEnd();
-                  }
-                  struct.columnFamilies.put(_key12, _val13);
-                }
-                iprot.readMapEnd();
-              }
-              struct.setColumnFamiliesIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          default:
-            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-        }
-        iprot.readFieldEnd();
-      }
-      iprot.readStructEnd();
-
-      // check for required fields of primitive type, which can't be checked in the validate method
-      struct.validate();
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot, LiveSchema struct) throws org.apache.thrift.TException {
-      struct.validate();
-
-      oprot.writeStructBegin(STRUCT_DESC);
-      if (struct.table != null) {
-        oprot.writeFieldBegin(TABLE_FIELD_DESC);
-        oprot.writeString(struct.table);
-        oprot.writeFieldEnd();
-      }
-      if (struct.columnFamilies != null) {
-        oprot.writeFieldBegin(COLUMN_FAMILIES_FIELD_DESC);
-        {
-          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.SET, struct.columnFamilies.size()));
-          for (Map.Entry<String, Set<String>> _iter17 : struct.columnFamilies.entrySet())
-          {
-            oprot.writeString(_iter17.getKey());
-            {
-              oprot.writeSetBegin(new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.STRING, _iter17.getValue().size()));
-              for (String _iter18 : _iter17.getValue())
-              {
-                oprot.writeString(_iter18);
-              }
-              oprot.writeSetEnd();
-            }
-          }
-          oprot.writeMapEnd();
-        }
-        oprot.writeFieldEnd();
-      }
-      oprot.writeFieldStop();
-      oprot.writeStructEnd();
-    }
-
-  }
-
-  private static class LiveSchemaTupleSchemeFactory implements SchemeFactory {
-    public LiveSchemaTupleScheme getScheme() {
-      return new LiveSchemaTupleScheme();
-    }
-  }
-
-  private static class LiveSchemaTupleScheme extends TupleScheme<LiveSchema> {
-
-    @Override
-    public void write(org.apache.thrift.protocol.TProtocol prot, LiveSchema struct) throws org.apache.thrift.TException {
-      TTupleProtocol oprot = (TTupleProtocol) prot;
-      BitSet optionals = new BitSet();
-      if (struct.isSetTable()) {
-        optionals.set(0);
-      }
-      if (struct.isSetColumnFamilies()) {
-        optionals.set(1);
-      }
-      oprot.writeBitSet(optionals, 2);
-      if (struct.isSetTable()) {
-        oprot.writeString(struct.table);
-      }
-      if (struct.isSetColumnFamilies()) {
-        {
-          oprot.writeI32(struct.columnFamilies.size());
-          for (Map.Entry<String, Set<String>> _iter19 : struct.columnFamilies.entrySet())
-          {
-            oprot.writeString(_iter19.getKey());
-            {
-              oprot.writeI32(_iter19.getValue().size());
-              for (String _iter20 : _iter19.getValue())
-              {
-                oprot.writeString(_iter20);
-              }
-            }
-          }
-        }
-      }
-    }
-
-    @Override
-    public void read(org.apache.thrift.protocol.TProtocol prot, LiveSchema struct) throws org.apache.thrift.TException {
-      TTupleProtocol iprot = (TTupleProtocol) prot;
-      BitSet incoming = iprot.readBitSet(2);
-      if (incoming.get(0)) {
-        struct.table = iprot.readString();
-        struct.setTableIsSet(true);
-      }
-      if (incoming.get(1)) {
-        {
-          org.apache.thrift.protocol.TMap _map21 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.SET, iprot.readI32());
-          struct.columnFamilies = new HashMap<String,Set<String>>(2*_map21.size);
-          for (int _i22 = 0; _i22 < _map21.size; ++_i22)
-          {
-            String _key23; // required
-            Set<String> _val24; // optional
-            _key23 = iprot.readString();
-            {
-              org.apache.thrift.protocol.TSet _set25 = new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
-              _val24 = new HashSet<String>(2*_set25.size);
-              for (int _i26 = 0; _i26 < _set25.size; ++_i26)
-              {
-                String _elem27; // required
-                _elem27 = iprot.readString();
-                _val24.add(_elem27);
-              }
-            }
-            struct.columnFamilies.put(_key23, _val24);
-          }
-        }
-        struct.setColumnFamiliesIsSet(true);
-      }
-    }
-  }
-
-}
-

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/b5ea6935/src/distribution/src/main/scripts/interface/gen-perl/Blur/Blur.pm
----------------------------------------------------------------------
diff --git a/src/distribution/src/main/scripts/interface/gen-perl/Blur/Blur.pm b/src/distribution/src/main/scripts/interface/gen-perl/Blur/Blur.pm
index a87ba8c..4afb02a 100644
--- a/src/distribution/src/main/scripts/interface/gen-perl/Blur/Blur.pm
+++ b/src/distribution/src/main/scripts/interface/gen-perl/Blur/Blur.pm
@@ -280,16 +280,16 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size113 = 0;
+          my $_size104 = 0;
           $self->{success} = [];
-          my $_etype116 = 0;
-          $xfer += $input->readListBegin(\$_etype116, \$_size113);
-          for (my $_i117 = 0; $_i117 < $_size113; ++$_i117)
+          my $_etype107 = 0;
+          $xfer += $input->readListBegin(\$_etype107, \$_size104);
+          for (my $_i108 = 0; $_i108 < $_size104; ++$_i108)
           {
-            my $elem118 = undef;
-            $elem118 = new Blur::TopFieldDocs();
-            $xfer += $elem118->read($input);
-            push(@{$self->{success}},$elem118);
+            my $elem109 = undef;
+            $elem109 = new Blur::TopFieldDocs();
+            $xfer += $elem109->read($input);
+            push(@{$self->{success}},$elem109);
           }
           $xfer += $input->readListEnd();
         }
@@ -321,9 +321,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{success}}));
       {
-        foreach my $iter119 (@{$self->{success}}) 
+        foreach my $iter110 (@{$self->{success}}) 
         {
-          $xfer += ${iter119}->write($output);
+          $xfer += ${iter110}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -393,15 +393,15 @@ sub read {
       last; };
       /^2$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size120 = 0;
+          my $_size111 = 0;
           $self->{docLocations} = [];
-          my $_etype123 = 0;
-          $xfer += $input->readListBegin(\$_etype123, \$_size120);
-          for (my $_i124 = 0; $_i124 < $_size120; ++$_i124)
+          my $_etype114 = 0;
+          $xfer += $input->readListBegin(\$_etype114, \$_size111);
+          for (my $_i115 = 0; $_i115 < $_size111; ++$_i115)
           {
-            my $elem125 = undef;
-            $xfer += $input->readI64(\$elem125);
-            push(@{$self->{docLocations}},$elem125);
+            my $elem116 = undef;
+            $xfer += $input->readI64(\$elem116);
+            push(@{$self->{docLocations}},$elem116);
           }
           $xfer += $input->readListEnd();
         }
@@ -411,15 +411,15 @@ sub read {
       last; };
       /^4$/ && do{      if ($ftype == TType::SET) {
         {
-          my $_size126 = 0;
+          my $_size117 = 0;
           $self->{fields} = {};
-          my $_etype129 = 0;
-          $xfer += $input->readSetBegin(\$_etype129, \$_size126);
-          for (my $_i130 = 0; $_i130 < $_size126; ++$_i130)
+          my $_etype120 = 0;
+          $xfer += $input->readSetBegin(\$_etype120, \$_size117);
+          for (my $_i121 = 0; $_i121 < $_size117; ++$_i121)
           {
-            my $elem131 = undef;
-            $xfer += $input->readString(\$elem131);
-            $self->{fields}->{$elem131} = 1;
+            my $elem122 = undef;
+            $xfer += $input->readString(\$elem122);
+            $self->{fields}->{$elem122} = 1;
           }
           $xfer += $input->readSetEnd();
         }
@@ -449,9 +449,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::I64, scalar(@{$self->{docLocations}}));
       {
-        foreach my $iter132 (@{$self->{docLocations}}) 
+        foreach my $iter123 (@{$self->{docLocations}}) 
         {
-          $xfer += $output->writeI64($iter132);
+          $xfer += $output->writeI64($iter123);
         }
       }
       $xfer += $output->writeListEnd();
@@ -463,9 +463,9 @@ sub write {
     {
       $xfer += $output->writeSetBegin(TType::STRING, scalar(@{$self->{fields}}));
       {
-        foreach my $iter133 (@{$self->{fields}})
+        foreach my $iter124 (@{$self->{fields}})
         {
-          $xfer += $output->writeString($iter133);
+          $xfer += $output->writeString($iter124);
         }
       }
       $xfer += $output->writeSetEnd();
@@ -519,16 +519,16 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size134 = 0;
+          my $_size125 = 0;
           $self->{success} = [];
-          my $_etype137 = 0;
-          $xfer += $input->readListBegin(\$_etype137, \$_size134);
-          for (my $_i138 = 0; $_i138 < $_size134; ++$_i138)
+          my $_etype128 = 0;
+          $xfer += $input->readListBegin(\$_etype128, \$_size125);
+          for (my $_i129 = 0; $_i129 < $_size125; ++$_i129)
           {
-            my $elem139 = undef;
-            $elem139 = new Blur::Document();
-            $xfer += $elem139->read($input);
-            push(@{$self->{success}},$elem139);
+            my $elem130 = undef;
+            $elem130 = new Blur::Document();
+            $xfer += $elem130->read($input);
+            push(@{$self->{success}},$elem130);
           }
           $xfer += $input->readListEnd();
         }
@@ -560,9 +560,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{success}}));
       {
-        foreach my $iter140 (@{$self->{success}}) 
+        foreach my $iter131 (@{$self->{success}}) 
         {
-          $xfer += ${iter140}->write($output);
+          $xfer += ${iter131}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -758,16 +758,16 @@ sub read {
       last; };
       /^2$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size141 = 0;
+          my $_size132 = 0;
           $self->{documents} = [];
-          my $_etype144 = 0;
-          $xfer += $input->readListBegin(\$_etype144, \$_size141);
-          for (my $_i145 = 0; $_i145 < $_size141; ++$_i145)
+          my $_etype135 = 0;
+          $xfer += $input->readListBegin(\$_etype135, \$_size132);
+          for (my $_i136 = 0; $_i136 < $_size132; ++$_i136)
           {
-            my $elem146 = undef;
-            $elem146 = new Blur::Document();
-            $xfer += $elem146->read($input);
-            push(@{$self->{documents}},$elem146);
+            my $elem137 = undef;
+            $elem137 = new Blur::Document();
+            $xfer += $elem137->read($input);
+            push(@{$self->{documents}},$elem137);
           }
           $xfer += $input->readListEnd();
         }
@@ -797,9 +797,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{documents}}));
       {
-        foreach my $iter147 (@{$self->{documents}}) 
+        foreach my $iter138 (@{$self->{documents}}) 
         {
-          $xfer += ${iter147}->write($output);
+          $xfer += ${iter138}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -853,16 +853,16 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size148 = 0;
+          my $_size139 = 0;
           $self->{success} = [];
-          my $_etype151 = 0;
-          $xfer += $input->readListBegin(\$_etype151, \$_size148);
-          for (my $_i152 = 0; $_i152 < $_size148; ++$_i152)
+          my $_etype142 = 0;
+          $xfer += $input->readListBegin(\$_etype142, \$_size139);
+          for (my $_i143 = 0; $_i143 < $_size139; ++$_i143)
           {
-            my $elem153 = undef;
-            $elem153 = new Blur::Generation();
-            $xfer += $elem153->read($input);
-            push(@{$self->{success}},$elem153);
+            my $elem144 = undef;
+            $elem144 = new Blur::Generation();
+            $xfer += $elem144->read($input);
+            push(@{$self->{success}},$elem144);
           }
           $xfer += $input->readListEnd();
         }
@@ -894,9 +894,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{success}}));
       {
-        foreach my $iter154 (@{$self->{success}}) 
+        foreach my $iter145 (@{$self->{success}}) 
         {
-          $xfer += ${iter154}->write($output);
+          $xfer += ${iter145}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -962,16 +962,16 @@ sub read {
       last; };
       /^2$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size155 = 0;
+          my $_size146 = 0;
           $self->{queries} = [];
-          my $_etype158 = 0;
-          $xfer += $input->readListBegin(\$_etype158, \$_size155);
-          for (my $_i159 = 0; $_i159 < $_size155; ++$_i159)
+          my $_etype149 = 0;
+          $xfer += $input->readListBegin(\$_etype149, \$_size146);
+          for (my $_i150 = 0; $_i150 < $_size146; ++$_i150)
           {
-            my $elem160 = undef;
-            $elem160 = new Blur::Query();
-            $xfer += $elem160->read($input);
-            push(@{$self->{queries}},$elem160);
+            my $elem151 = undef;
+            $elem151 = new Blur::Query();
+            $xfer += $elem151->read($input);
+            push(@{$self->{queries}},$elem151);
           }
           $xfer += $input->readListEnd();
         }
@@ -1001,9 +1001,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{queries}}));
       {
-        foreach my $iter161 (@{$self->{queries}}) 
+        foreach my $iter152 (@{$self->{queries}}) 
         {
-          $xfer += ${iter161}->write($output);
+          $xfer += ${iter152}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -1057,16 +1057,16 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size162 = 0;
+          my $_size153 = 0;
           $self->{success} = [];
-          my $_etype165 = 0;
-          $xfer += $input->readListBegin(\$_etype165, \$_size162);
-          for (my $_i166 = 0; $_i166 < $_size162; ++$_i166)
+          my $_etype156 = 0;
+          $xfer += $input->readListBegin(\$_etype156, \$_size153);
+          for (my $_i157 = 0; $_i157 < $_size153; ++$_i157)
           {
-            my $elem167 = undef;
-            $elem167 = new Blur::Generation();
-            $xfer += $elem167->read($input);
-            push(@{$self->{success}},$elem167);
+            my $elem158 = undef;
+            $elem158 = new Blur::Generation();
+            $xfer += $elem158->read($input);
+            push(@{$self->{success}},$elem158);
           }
           $xfer += $input->readListEnd();
         }
@@ -1098,9 +1098,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{success}}));
       {
-        foreach my $iter168 (@{$self->{success}}) 
+        foreach my $iter159 (@{$self->{success}}) 
         {
-          $xfer += ${iter168}->write($output);
+          $xfer += ${iter159}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -1166,16 +1166,16 @@ sub read {
       last; };
       /^2$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size169 = 0;
+          my $_size160 = 0;
           $self->{terms} = [];
-          my $_etype172 = 0;
-          $xfer += $input->readListBegin(\$_etype172, \$_size169);
-          for (my $_i173 = 0; $_i173 < $_size169; ++$_i173)
+          my $_etype163 = 0;
+          $xfer += $input->readListBegin(\$_etype163, \$_size160);
+          for (my $_i164 = 0; $_i164 < $_size160; ++$_i164)
           {
-            my $elem174 = undef;
-            $elem174 = new Blur::Term();
-            $xfer += $elem174->read($input);
-            push(@{$self->{terms}},$elem174);
+            my $elem165 = undef;
+            $elem165 = new Blur::Term();
+            $xfer += $elem165->read($input);
+            push(@{$self->{terms}},$elem165);
           }
           $xfer += $input->readListEnd();
         }
@@ -1205,9 +1205,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{terms}}));
       {
-        foreach my $iter175 (@{$self->{terms}}) 
+        foreach my $iter166 (@{$self->{terms}}) 
         {
-          $xfer += ${iter175}->write($output);
+          $xfer += ${iter166}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -1261,16 +1261,16 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size176 = 0;
+          my $_size167 = 0;
           $self->{success} = [];
-          my $_etype179 = 0;
-          $xfer += $input->readListBegin(\$_etype179, \$_size176);
-          for (my $_i180 = 0; $_i180 < $_size176; ++$_i180)
+          my $_etype170 = 0;
+          $xfer += $input->readListBegin(\$_etype170, \$_size167);
+          for (my $_i171 = 0; $_i171 < $_size167; ++$_i171)
           {
-            my $elem181 = undef;
-            $elem181 = new Blur::Generation();
-            $xfer += $elem181->read($input);
-            push(@{$self->{success}},$elem181);
+            my $elem172 = undef;
+            $elem172 = new Blur::Generation();
+            $xfer += $elem172->read($input);
+            push(@{$self->{success}},$elem172);
           }
           $xfer += $input->readListEnd();
         }
@@ -1302,9 +1302,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{success}}));
       {
-        foreach my $iter182 (@{$self->{success}}) 
+        foreach my $iter173 (@{$self->{success}}) 
         {
-          $xfer += ${iter182}->write($output);
+          $xfer += ${iter173}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -1370,16 +1370,16 @@ sub read {
       last; };
       /^2$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size183 = 0;
+          my $_size174 = 0;
           $self->{updatePackages} = [];
-          my $_etype186 = 0;
-          $xfer += $input->readListBegin(\$_etype186, \$_size183);
-          for (my $_i187 = 0; $_i187 < $_size183; ++$_i187)
+          my $_etype177 = 0;
+          $xfer += $input->readListBegin(\$_etype177, \$_size174);
+          for (my $_i178 = 0; $_i178 < $_size174; ++$_i178)
           {
-            my $elem188 = undef;
-            $elem188 = new Blur::UpdatePackage();
-            $xfer += $elem188->read($input);
-            push(@{$self->{updatePackages}},$elem188);
+            my $elem179 = undef;
+            $elem179 = new Blur::UpdatePackage();
+            $xfer += $elem179->read($input);
+            push(@{$self->{updatePackages}},$elem179);
           }
           $xfer += $input->readListEnd();
         }
@@ -1409,9 +1409,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{updatePackages}}));
       {
-        foreach my $iter189 (@{$self->{updatePackages}}) 
+        foreach my $iter180 (@{$self->{updatePackages}}) 
         {
-          $xfer += ${iter189}->write($output);
+          $xfer += ${iter180}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -1465,16 +1465,16 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size190 = 0;
+          my $_size181 = 0;
           $self->{success} = [];
-          my $_etype193 = 0;
-          $xfer += $input->readListBegin(\$_etype193, \$_size190);
-          for (my $_i194 = 0; $_i194 < $_size190; ++$_i194)
+          my $_etype184 = 0;
+          $xfer += $input->readListBegin(\$_etype184, \$_size181);
+          for (my $_i185 = 0; $_i185 < $_size181; ++$_i185)
           {
-            my $elem195 = undef;
-            $elem195 = new Blur::Generation();
-            $xfer += $elem195->read($input);
-            push(@{$self->{success}},$elem195);
+            my $elem186 = undef;
+            $elem186 = new Blur::Generation();
+            $xfer += $elem186->read($input);
+            push(@{$self->{success}},$elem186);
           }
           $xfer += $input->readListEnd();
         }
@@ -1506,9 +1506,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{success}}));
       {
-        foreach my $iter196 (@{$self->{success}}) 
+        foreach my $iter187 (@{$self->{success}}) 
         {
-          $xfer += ${iter196}->write($output);
+          $xfer += ${iter187}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -1567,16 +1567,16 @@ sub read {
     {
       /^1$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size197 = 0;
+          my $_size188 = 0;
           $self->{generations} = [];
-          my $_etype200 = 0;
-          $xfer += $input->readListBegin(\$_etype200, \$_size197);
-          for (my $_i201 = 0; $_i201 < $_size197; ++$_i201)
+          my $_etype191 = 0;
+          $xfer += $input->readListBegin(\$_etype191, \$_size188);
+          for (my $_i192 = 0; $_i192 < $_size188; ++$_i192)
           {
-            my $elem202 = undef;
-            $elem202 = new Blur::Generation();
-            $xfer += $elem202->read($input);
-            push(@{$self->{generations}},$elem202);
+            my $elem193 = undef;
+            $elem193 = new Blur::Generation();
+            $xfer += $elem193->read($input);
+            push(@{$self->{generations}},$elem193);
           }
           $xfer += $input->readListEnd();
         }
@@ -1607,9 +1607,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRUCT, scalar(@{$self->{generations}}));
       {
-        foreach my $iter203 (@{$self->{generations}}) 
+        foreach my $iter194 (@{$self->{generations}}) 
         {
-          $xfer += ${iter203}->write($output);
+          $xfer += ${iter194}->write($output);
         }
       }
       $xfer += $output->writeListEnd();
@@ -1779,15 +1779,15 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size204 = 0;
+          my $_size195 = 0;
           $self->{success} = [];
-          my $_etype207 = 0;
-          $xfer += $input->readListBegin(\$_etype207, \$_size204);
-          for (my $_i208 = 0; $_i208 < $_size204; ++$_i208)
+          my $_etype198 = 0;
+          $xfer += $input->readListBegin(\$_etype198, \$_size195);
+          for (my $_i199 = 0; $_i199 < $_size195; ++$_i199)
           {
-            my $elem209 = undef;
-            $xfer += $input->readString(\$elem209);
-            push(@{$self->{success}},$elem209);
+            my $elem200 = undef;
+            $xfer += $input->readString(\$elem200);
+            push(@{$self->{success}},$elem200);
           }
           $xfer += $input->readListEnd();
         }
@@ -1819,9 +1819,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRING, scalar(@{$self->{success}}));
       {
-        foreach my $iter210 (@{$self->{success}}) 
+        foreach my $iter201 (@{$self->{success}}) 
         {
-          $xfer += $output->writeString($iter210);
+          $xfer += $output->writeString($iter201);
         }
       }
       $xfer += $output->writeListEnd();
@@ -1959,15 +1959,15 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size211 = 0;
+          my $_size202 = 0;
           $self->{success} = [];
-          my $_etype214 = 0;
-          $xfer += $input->readListBegin(\$_etype214, \$_size211);
-          for (my $_i215 = 0; $_i215 < $_size211; ++$_i215)
+          my $_etype205 = 0;
+          $xfer += $input->readListBegin(\$_etype205, \$_size202);
+          for (my $_i206 = 0; $_i206 < $_size202; ++$_i206)
           {
-            my $elem216 = undef;
-            $xfer += $input->readI32(\$elem216);
-            push(@{$self->{success}},$elem216);
+            my $elem207 = undef;
+            $xfer += $input->readI32(\$elem207);
+            push(@{$self->{success}},$elem207);
           }
           $xfer += $input->readListEnd();
         }
@@ -1999,9 +1999,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::I32, scalar(@{$self->{success}}));
       {
-        foreach my $iter217 (@{$self->{success}}) 
+        foreach my $iter208 (@{$self->{success}}) 
         {
-          $xfer += $output->writeI32($iter217);
+          $xfer += $output->writeI32($iter208);
         }
       }
       $xfer += $output->writeListEnd();
@@ -2124,19 +2124,19 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::MAP) {
         {
-          my $_size218 = 0;
+          my $_size209 = 0;
           $self->{success} = {};
-          my $_ktype219 = 0;
-          my $_vtype220 = 0;
-          $xfer += $input->readMapBegin(\$_ktype219, \$_vtype220, \$_size218);
-          for (my $_i222 = 0; $_i222 < $_size218; ++$_i222)
+          my $_ktype210 = 0;
+          my $_vtype211 = 0;
+          $xfer += $input->readMapBegin(\$_ktype210, \$_vtype211, \$_size209);
+          for (my $_i213 = 0; $_i213 < $_size209; ++$_i213)
           {
-            my $key223 = '';
-            my $val224 = new Blur::ShardLayout();
-            $xfer += $input->readString(\$key223);
-            $val224 = new Blur::ShardLayout();
-            $xfer += $val224->read($input);
-            $self->{success}->{$key223} = $val224;
+            my $key214 = '';
+            my $val215 = new Blur::ShardLayout();
+            $xfer += $input->readString(\$key214);
+            $val215 = new Blur::ShardLayout();
+            $xfer += $val215->read($input);
+            $self->{success}->{$key214} = $val215;
           }
           $xfer += $input->readMapEnd();
         }
@@ -2168,10 +2168,10 @@ sub write {
     {
       $xfer += $output->writeMapBegin(TType::STRING, TType::STRUCT, scalar(keys %{$self->{success}}));
       {
-        while( my ($kiter225,$viter226) = each %{$self->{success}}) 
+        while( my ($kiter216,$viter217) = each %{$self->{success}}) 
         {
-          $xfer += $output->writeString($kiter225);
-          $xfer += ${viter226}->write($output);
+          $xfer += $output->writeString($kiter216);
+          $xfer += ${viter217}->write($output);
         }
       }
       $xfer += $output->writeMapEnd();
@@ -2276,15 +2276,15 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size227 = 0;
+          my $_size218 = 0;
           $self->{success} = [];
-          my $_etype230 = 0;
-          $xfer += $input->readListBegin(\$_etype230, \$_size227);
-          for (my $_i231 = 0; $_i231 < $_size227; ++$_i231)
+          my $_etype221 = 0;
+          $xfer += $input->readListBegin(\$_etype221, \$_size218);
+          for (my $_i222 = 0; $_i222 < $_size218; ++$_i222)
           {
-            my $elem232 = undef;
-            $xfer += $input->readString(\$elem232);
-            push(@{$self->{success}},$elem232);
+            my $elem223 = undef;
+            $xfer += $input->readString(\$elem223);
+            push(@{$self->{success}},$elem223);
           }
           $xfer += $input->readListEnd();
         }
@@ -2316,9 +2316,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::STRING, scalar(@{$self->{success}}));
       {
-        foreach my $iter233 (@{$self->{success}}) 
+        foreach my $iter224 (@{$self->{success}}) 
         {
-          $xfer += $output->writeString($iter233);
+          $xfer += $output->writeString($iter224);
         }
       }
       $xfer += $output->writeListEnd();
@@ -3390,15 +3390,15 @@ sub read {
     {
       /^0$/ && do{      if ($ftype == TType::LIST) {
         {
-          my $_size234 = 0;
+          my $_size225 = 0;
           $self->{success} = [];
-          my $_etype237 = 0;
-          $xfer += $input->readListBegin(\$_etype237, \$_size234);
-          for (my $_i238 = 0; $_i238 < $_size234; ++$_i238)
+          my $_etype228 = 0;
+          $xfer += $input->readListBegin(\$_etype228, \$_size225);
+          for (my $_i229 = 0; $_i229 < $_size225; ++$_i229)
           {
-            my $elem239 = undef;
-            $xfer += $input->readI64(\$elem239);
-            push(@{$self->{success}},$elem239);
+            my $elem230 = undef;
+            $xfer += $input->readI64(\$elem230);
+            push(@{$self->{success}},$elem230);
           }
           $xfer += $input->readListEnd();
         }
@@ -3430,9 +3430,9 @@ sub write {
     {
       $xfer += $output->writeListBegin(TType::I64, scalar(@{$self->{success}}));
       {
-        foreach my $iter240 (@{$self->{success}}) 
+        foreach my $iter231 (@{$self->{success}}) 
         {
-          $xfer += $output->writeI64($iter240);
+          $xfer += $output->writeI64($iter231);
         }
       }
       $xfer += $output->writeListEnd();
@@ -3612,16 +3612,20 @@ sub write {
 
 package Blur::Blur_schema_args;
 use base qw(Class::Accessor);
-Blur::Blur_schema_args->mk_accessors( qw( table ) );
+Blur::Blur_schema_args->mk_accessors( qw( session shardsIds ) );
 
 sub new {
   my $classname = shift;
   my $self      = {};
   my $vals      = shift || {};
-  $self->{table} = undef;
+  $self->{session} = undef;
+  $self->{shardsIds} = undef;
   if (UNIVERSAL::isa($vals,'HASH')) {
-    if (defined $vals->{table}) {
-      $self->{table} = $vals->{table};
+    if (defined $vals->{session}) {
+      $self->{session} = $vals->{session};
+    }
+    if (defined $vals->{shardsIds}) {
+      $self->{shardsIds} = $vals->{shardsIds};
     }
   }
   return bless ($self, $classname);
@@ -3646,8 +3650,27 @@ sub read {
     }
     SWITCH: for($fid)
     {
-      /^1$/ && do{      if ($ftype == TType::STRING) {
-        $xfer += $input->readString(\$self->{table});
+      /^1$/ && do{      if ($ftype == TType::STRUCT) {
+        $self->{session} = new Blur::Session();
+        $xfer += $self->{session}->read($input);
+      } else {
+        $xfer += $input->skip($ftype);
+      }
+      last; };
+      /^2$/ && do{      if ($ftype == TType::LIST) {
+        {
+          my $_size232 = 0;
+          $self->{shardsIds} = [];
+          my $_etype235 = 0;
+          $xfer += $input->readListBegin(\$_etype235, \$_size232);
+          for (my $_i236 = 0; $_i236 < $_size232; ++$_i236)
+          {
+            my $elem237 = undef;
+            $xfer += $input->readI32(\$elem237);
+            push(@{$self->{shardsIds}},$elem237);
+          }
+          $xfer += $input->readListEnd();
+        }
       } else {
         $xfer += $input->skip($ftype);
       }
@@ -3664,9 +3687,23 @@ sub write {
   my ($self, $output) = @_;
   my $xfer   = 0;
   $xfer += $output->writeStructBegin('Blur_schema_args');
-  if (defined $self->{table}) {
-    $xfer += $output->writeFieldBegin('table', TType::STRING, 1);
-    $xfer += $output->writeString($self->{table});
+  if (defined $self->{session}) {
+    $xfer += $output->writeFieldBegin('session', TType::STRUCT, 1);
+    $xfer += $self->{session}->write($output);
+    $xfer += $output->writeFieldEnd();
+  }
+  if (defined $self->{shardsIds}) {
+    $xfer += $output->writeFieldBegin('shardsIds', TType::LIST, 2);
+    {
+      $xfer += $output->writeListBegin(TType::I32, scalar(@{$self->{shardsIds}}));
+      {
+        foreach my $iter238 (@{$self->{shardsIds}}) 
+        {
+          $xfer += $output->writeI32($iter238);
+        }
+      }
+      $xfer += $output->writeListEnd();
+    }
     $xfer += $output->writeFieldEnd();
   }
   $xfer += $output->writeFieldStop();
@@ -3715,7 +3752,7 @@ sub read {
     SWITCH: for($fid)
     {
       /^0$/ && do{      if ($ftype == TType::STRUCT) {
-        $self->{success} = new Blur::LiveSchema();
+        $self->{success} = new Blur::TableSchema();
         $xfer += $self->{success}->read($input);
       } else {
         $xfer += $input->skip($ftype);
@@ -4070,7 +4107,8 @@ sub queryStatus{
 
 sub schema{
   my $self = shift;
-  my $table = shift;
+  my $session = shift;
+  my $shardsIds = shift;
 
   die 'implement interface';
 }
@@ -4260,8 +4298,9 @@ sub queryStatus{
 sub schema{
   my ($self, $request) = @_;
 
-  my $table = ($request->{'table'}) ? $request->{'table'} : undef;
-  return $self->{impl}->schema($table);
+  my $session = ($request->{'session'}) ? $request->{'session'} : undef;
+  my $shardsIds = ($request->{'shardsIds'}) ? $request->{'shardsIds'} : undef;
+  return $self->{impl}->schema($session, $shardsIds);
 }
 
 sub tableStats{
@@ -5304,19 +5343,22 @@ sub recv_queryStatus{
 }
 sub schema{
   my $self = shift;
-  my $table = shift;
+  my $session = shift;
+  my $shardsIds = shift;
 
-    $self->send_schema($table);
+    $self->send_schema($session, $shardsIds);
   return $self->recv_schema();
 }
 
 sub send_schema{
   my $self = shift;
-  my $table = shift;
+  my $session = shift;
+  my $shardsIds = shift;
 
   $self->{output}->writeMessageBegin('schema', TMessageType::CALL, $self->{seqid});
   my $args = new Blur::Blur_schema_args();
-  $args->{table} = $table;
+  $args->{session} = $session;
+  $args->{shardsIds} = $shardsIds;
   $args->write($self->{output});
   $self->{output}->writeMessageEnd();
   $self->{output}->getTransport()->flush();
@@ -5809,7 +5851,7 @@ sub process_schema {
     $input->readMessageEnd();
     my $result = new Blur::Blur_schema_result();
     eval {
-      $result->{success} = $self->{handler}->schema($args->table);
+      $result->{success} = $self->{handler}->schema($args->session, $args->shardsIds);
     }; if( UNIVERSAL::isa($@,'Blur::BlurException') ){ 
       $result->{ex} = $@;
     }


Mime
View raw message