incubator-blur-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cr...@apache.org
Subject [42/53] [partial] Initial commit of console v2. Sorry for the large commit
Date Mon, 17 Feb 2014 16:07:18 GMT
http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/11a2529a/contrib/blur-console-v1/blur-admin/lib/thrift/blur_constants.rb
----------------------------------------------------------------------
diff --git a/contrib/blur-console-v1/blur-admin/lib/thrift/blur_constants.rb b/contrib/blur-console-v1/blur-admin/lib/thrift/blur_constants.rb
new file mode 100644
index 0000000..e455224
--- /dev/null
+++ b/contrib/blur-console-v1/blur-admin/lib/thrift/blur_constants.rb
@@ -0,0 +1,11 @@
+#
+# Autogenerated by Thrift Compiler (0.9.0)
+#
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+#
+
+require 'thrift'
+require 'blur_types'
+
+module Blur
+end

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/11a2529a/contrib/blur-console-v1/blur-admin/lib/thrift/blur_types.rb
----------------------------------------------------------------------
diff --git a/contrib/blur-console-v1/blur-admin/lib/thrift/blur_types.rb b/contrib/blur-console-v1/blur-admin/lib/thrift/blur_types.rb
new file mode 100644
index 0000000..40547a1
--- /dev/null
+++ b/contrib/blur-console-v1/blur-admin/lib/thrift/blur_types.rb
@@ -0,0 +1,801 @@
+#
+# Autogenerated by Thrift Compiler (0.9.0)
+#
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+#
+
+require 'thrift'
+
+module Blur
+  module ErrorType
+    UNKNOWN = 0
+    QUERY_CANCEL = 1
+    QUERY_TIMEOUT = 2
+    BACK_PRESSURE = 3
+    REQUEST_TIMEOUT = 4
+    VALUE_MAP = {0 => "UNKNOWN", 1 => "QUERY_CANCEL", 2 => "QUERY_TIMEOUT", 3 => "BACK_PRESSURE", 4 => "REQUEST_TIMEOUT"}
+    VALID_VALUES = Set.new([UNKNOWN, QUERY_CANCEL, QUERY_TIMEOUT, BACK_PRESSURE, REQUEST_TIMEOUT]).freeze
+  end
+
+  module ScoreType
+    SUPER = 0
+    AGGREGATE = 1
+    BEST = 2
+    CONSTANT = 3
+    VALUE_MAP = {0 => "SUPER", 1 => "AGGREGATE", 2 => "BEST", 3 => "CONSTANT"}
+    VALID_VALUES = Set.new([SUPER, AGGREGATE, BEST, CONSTANT]).freeze
+  end
+
+  module QueryState
+    RUNNING = 0
+    INTERRUPTED = 1
+    COMPLETE = 2
+    BACK_PRESSURE_INTERRUPTED = 3
+    VALUE_MAP = {0 => "RUNNING", 1 => "INTERRUPTED", 2 => "COMPLETE", 3 => "BACK_PRESSURE_INTERRUPTED"}
+    VALID_VALUES = Set.new([RUNNING, INTERRUPTED, COMPLETE, BACK_PRESSURE_INTERRUPTED]).freeze
+  end
+
+  module Status
+    NOT_FOUND = 0
+    FOUND = 1
+    VALUE_MAP = {0 => "NOT_FOUND", 1 => "FOUND"}
+    VALID_VALUES = Set.new([NOT_FOUND, FOUND]).freeze
+  end
+
+  module RowMutationType
+    DELETE_ROW = 0
+    REPLACE_ROW = 1
+    UPDATE_ROW = 2
+    VALUE_MAP = {0 => "DELETE_ROW", 1 => "REPLACE_ROW", 2 => "UPDATE_ROW"}
+    VALID_VALUES = Set.new([DELETE_ROW, REPLACE_ROW, UPDATE_ROW]).freeze
+  end
+
+  module RecordMutationType
+    DELETE_ENTIRE_RECORD = 0
+    REPLACE_ENTIRE_RECORD = 1
+    REPLACE_COLUMNS = 2
+    APPEND_COLUMN_VALUES = 3
+    VALUE_MAP = {0 => "DELETE_ENTIRE_RECORD", 1 => "REPLACE_ENTIRE_RECORD", 2 => "REPLACE_COLUMNS", 3 => "APPEND_COLUMN_VALUES"}
+    VALID_VALUES = Set.new([DELETE_ENTIRE_RECORD, REPLACE_ENTIRE_RECORD, REPLACE_COLUMNS, APPEND_COLUMN_VALUES]).freeze
+  end
+
+  module ShardState
+    OPENING = 0
+    OPEN = 1
+    OPENING_ERROR = 2
+    CLOSING = 3
+    CLOSED = 4
+    CLOSING_ERROR = 5
+    VALUE_MAP = {0 => "OPENING", 1 => "OPEN", 2 => "OPENING_ERROR", 3 => "CLOSING", 4 => "CLOSED", 5 => "CLOSING_ERROR"}
+    VALID_VALUES = Set.new([OPENING, OPEN, OPENING_ERROR, CLOSING, CLOSED, CLOSING_ERROR]).freeze
+  end
+
+  # BlurException that carries a message plus the original stack
+# trace (if any).
+  class BlurException < ::Thrift::Exception
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    MESSAGE = 1
+    STACKTRACESTR = 2
+    ERRORTYPE = 3
+
+    FIELDS = {
+      # The message in the exception.
+      MESSAGE => {:type => ::Thrift::Types::STRING, :name => 'message'},
+      # The original stack trace (if any).
+      STACKTRACESTR => {:type => ::Thrift::Types::STRING, :name => 'stackTraceStr'},
+      ERRORTYPE => {:type => ::Thrift::Types::I32, :name => 'errorType', :enum_class => ::Blur::ErrorType}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+      unless @errorType.nil? || ::Blur::ErrorType::VALID_VALUES.include?(@errorType)
+        raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field errorType!')
+      end
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # Column is the lowest storage element in Blur, it stores a single name and value pair.
+  class Column
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    NAME = 1
+    VALUE = 2
+
+    FIELDS = {
+      # The name of the column.
+      NAME => {:type => ::Thrift::Types::STRING, :name => 'name'},
+      # The value to be indexed and stored.
+      VALUE => {:type => ::Thrift::Types::STRING, :name => 'value'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # Records contain a list of columns, multiple columns with the same name are allowed.
+  class Record
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    RECORDID = 1
+    FAMILY = 2
+    COLUMNS = 3
+
+    FIELDS = {
+      # Record id uniquely identifies a record within a single row.
+      RECORDID => {:type => ::Thrift::Types::STRING, :name => 'recordId'},
+      # The family in which this record resides.
+      FAMILY => {:type => ::Thrift::Types::STRING, :name => 'family'},
+      # A list of columns, multiple columns with the same name are allowed.
+      COLUMNS => {:type => ::Thrift::Types::LIST, :name => 'columns', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Blur::Column}}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # Rows contain a list of records.
+  class Row
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    ID = 1
+    RECORDS = 2
+    RECORDCOUNT = 3
+
+    FIELDS = {
+      # The row id.
+      ID => {:type => ::Thrift::Types::STRING, :name => 'id'},
+      # The list records within the row.  If paging is used this list will only
+# reflect the paged records from the selector.
+      RECORDS => {:type => ::Thrift::Types::LIST, :name => 'records', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Blur::Record}},
+      # The total record count for the row.  If paging is used in a selector to page
+# through records of a row, this count will reflect the entire row.
+      RECORDCOUNT => {:type => ::Thrift::Types::I32, :name => 'recordCount'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The Query object holds the query string (normal Lucene syntax),
+# filters and type of scoring (used when super query is on).
+  class Query
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    QUERY = 1
+    ROWQUERY = 2
+    SCORETYPE = 3
+    ROWFILTER = 4
+    RECORDFILTER = 5
+
+    FIELDS = {
+      # A Lucene syntax based query.
+      QUERY => {:type => ::Thrift::Types::STRING, :name => 'query'},
+      # If the Row query is on, meaning the query will be perform against all the
+# Records (joining records in some cases) and the result will be Rows (groupings of Record).
+      ROWQUERY => {:type => ::Thrift::Types::BOOL, :name => 'rowQuery', :default => true},
+      # The scoring type, see the document on ScoreType for explanation of each score type.
+      SCORETYPE => {:type => ::Thrift::Types::I32, :name => 'scoreType', :default =>       0, :enum_class => ::Blur::ScoreType},
+      # The Row filter (normal Lucene syntax), is a filter performed
+# after the join to filter out entire Rows from the results.  This
+# field is ignored when rowQuery is false.
+      ROWFILTER => {:type => ::Thrift::Types::STRING, :name => 'rowFilter'},
+      # The Record filter (normal Lucene syntax), is a filter performed
+# before the join to filter out Records from the results.
+      RECORDFILTER => {:type => ::Thrift::Types::STRING, :name => 'recordFilter'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+      unless @scoreType.nil? || ::Blur::ScoreType::VALID_VALUES.include?(@scoreType)
+        raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field scoreType!')
+      end
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The HighlightOptions controls how the data is fetched and returned.
+  class HighlightOptions
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    QUERY = 1
+    PRETAG = 2
+    POSTTAG = 3
+
+    FIELDS = {
+      # The original query is required if used in the Blur.fetchRow call.  If
+# the highlightOptions is used in a call to Blur.query then the Query
+# passed into the call via the BlurQuery will be used if this query is
+# null.  So that means if you use highlighting from the query call you can
+# leave this attribute null and it will default to the normal behavior.
+      QUERY => {:type => ::Thrift::Types::STRUCT, :name => 'query', :class => ::Blur::Query},
+      # The pre tag is the tag that marks the beginning of the highlighting.
+      PRETAG => {:type => ::Thrift::Types::STRING, :name => 'preTag', :default => %q"<<<"},
+      # The post tag is the tag that marks the end of the highlighting.
+      POSTTAG => {:type => ::Thrift::Types::STRING, :name => 'postTag', :default => %q">>>"}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # Select carries the request for information to be retrieved from the stored columns.
+  class Selector
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    RECORDONLY = 1
+    LOCATIONID = 2
+    ROWID = 3
+    RECORDID = 4
+    COLUMNFAMILIESTOFETCH = 5
+    COLUMNSTOFETCH = 6
+    STARTRECORD = 8
+    MAXRECORDSTOFETCH = 9
+    HIGHLIGHTOPTIONS = 10
+
+    FIELDS = {
+      # Fetch the Record only, not the entire Row.
+      RECORDONLY => {:type => ::Thrift::Types::BOOL, :name => 'recordOnly'},
+      # WARNING: This is an internal only attribute and is not intended for use by clients.
+# The location id of the Record or Row to be fetched.
+      LOCATIONID => {:type => ::Thrift::Types::STRING, :name => 'locationId'},
+      # The row id of the Row to be fetched, not to be used with location id.
+      ROWID => {:type => ::Thrift::Types::STRING, :name => 'rowId'},
+      # The record id of the Record to be fetched, not to be used with location id.  However the row id needs to be provided to locate the correct Row with the requested Record.
+      RECORDID => {:type => ::Thrift::Types::STRING, :name => 'recordId'},
+      # The column families to fetch.  If null, fetch all.  If empty, fetch none.
+      COLUMNFAMILIESTOFETCH => {:type => ::Thrift::Types::LIST, :name => 'columnFamiliesToFetch', :element => {:type => ::Thrift::Types::STRING}},
+      # The columns in the families to fetch.  If null, fetch all.  If empty, fetch none.
+      COLUMNSTOFETCH => {:type => ::Thrift::Types::MAP, :name => 'columnsToFetch', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::SET, :element => {:type => ::Thrift::Types::STRING}}},
+      # Only valid for Row fetches, the record in the row to start fetching.  If the row contains 1000
+# records and you want the first 100, then this value is 0.  If you want records 300-400 then this
+# value would be 300.  If startRecord is beyond the end of the row, the row will be null in the
+# FetchResult.  Used in conjunction with maxRecordsToFetch.
+      STARTRECORD => {:type => ::Thrift::Types::I32, :name => 'startRecord', :default => 0},
+      # Only valid for Row fetches, the number of records to fetch.  If the row contains 1000 records
+# and you want the first 100, then this value is 100.  If you want records 300-400 then this value
+# would be 100.  Used in conjunction with maxRecordsToFetch. By default this will fetch the first
+# 1000 records of the row.
+      MAXRECORDSTOFETCH => {:type => ::Thrift::Types::I32, :name => 'maxRecordsToFetch', :default => 1000},
+      # The HighlightOptions object controls how the data is highlighted.  If null no highlighting will occur.
+      HIGHLIGHTOPTIONS => {:type => ::Thrift::Types::STRUCT, :name => 'highlightOptions', :class => ::Blur::HighlightOptions}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # FetchRowResult contains row result from a fetch.
+  class FetchRowResult
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    ROW = 1
+
+    FIELDS = {
+      # The row fetched.
+      ROW => {:type => ::Thrift::Types::STRUCT, :name => 'row', :class => ::Blur::Row}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # FetchRecordResult contains rowid of the record and the record result from a fetch.
+  class FetchRecordResult
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    ROWID = 1
+    RECORD = 2
+
+    FIELDS = {
+      # The row id of the record being fetched.
+      ROWID => {:type => ::Thrift::Types::STRING, :name => 'rowid'},
+      # The record fetched.
+      RECORD => {:type => ::Thrift::Types::STRUCT, :name => 'record', :class => ::Blur::Record}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # FetchResult contains the row or record fetch result based if the Selector
+# was going to fetch the entire row or a single record.
+  class FetchResult
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    EXISTS = 1
+    DELETED = 2
+    TABLE = 3
+    ROWRESULT = 4
+    RECORDRESULT = 5
+
+    FIELDS = {
+      # True if the result exists, false if it doesn't.
+      EXISTS => {:type => ::Thrift::Types::BOOL, :name => 'exists'},
+      # If the row was marked as deleted.
+      DELETED => {:type => ::Thrift::Types::BOOL, :name => 'deleted'},
+      # The table the fetch result came from.
+      TABLE => {:type => ::Thrift::Types::STRING, :name => 'table'},
+      # The row result if a row was selected form the Selector.
+      ROWRESULT => {:type => ::Thrift::Types::STRUCT, :name => 'rowResult', :class => ::Blur::FetchRowResult},
+      # The record result if a record was selected form the Selector.
+      RECORDRESULT => {:type => ::Thrift::Types::STRUCT, :name => 'recordResult', :class => ::Blur::FetchRecordResult}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # Blur facet.
+  class Facet
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    QUERYSTR = 1
+    MINIMUMNUMBEROFBLURRESULTS = 2
+
+    FIELDS = {
+      # The facet query.
+      QUERYSTR => {:type => ::Thrift::Types::STRING, :name => 'queryStr'},
+      # The minimum number of results before no longer processing the facet.  This
+# is a good way to decrease the strain on the system while using many facets. For
+# example if you set this attribute to 1000, then the shard server will stop
+# processing the facet at the 1000 mark.  However because this is processed at
+# the shard server level the controller will likely return more than the minimum
+# because it sums the answers from the shard servers.
+      MINIMUMNUMBEROFBLURRESULTS => {:type => ::Thrift::Types::I64, :name => 'minimumNumberOfBlurResults', :default => 9223372036854775807}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The Blur Query object that contains the query that needs to be executed along
+# with the query options.
+  class BlurQuery
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    QUERY = 1
+    FACETS = 3
+    SELECTOR = 4
+    USECACHEIFPRESENT = 6
+    START = 7
+    FETCH = 8
+    MINIMUMNUMBEROFRESULTS = 9
+    MAXQUERYTIME = 10
+    UUID = 11
+    USERCONTEXT = 12
+    CACHERESULT = 13
+    STARTTIME = 14
+
+    FIELDS = {
+      # The query information.
+      QUERY => {:type => ::Thrift::Types::STRUCT, :name => 'query', :class => ::Blur::Query},
+      # A list of Facets to execute with the given query.
+      FACETS => {:type => ::Thrift::Types::LIST, :name => 'facets', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Blur::Facet}},
+      # Selector is used to fetch data in the search results, if null only location ids will be fetched.
+      SELECTOR => {:type => ::Thrift::Types::STRUCT, :name => 'selector', :class => ::Blur::Selector},
+      # Enabled by default to use a cached result if the query matches a previous run query with the
+# configured amount of time.
+      USECACHEIFPRESENT => {:type => ::Thrift::Types::BOOL, :name => 'useCacheIfPresent', :default => true},
+      # The starting result position, 0 by default.
+      START => {:type => ::Thrift::Types::I64, :name => 'start', :default => 0},
+      # The number of fetched results, 10 by default.
+      FETCH => {:type => ::Thrift::Types::I32, :name => 'fetch', :default => 10},
+      # The minimum number of results to find before returning.
+      MINIMUMNUMBEROFRESULTS => {:type => ::Thrift::Types::I64, :name => 'minimumNumberOfResults', :default => 9223372036854775807},
+      # The maximum amount of time the query should execute before timing out.
+      MAXQUERYTIME => {:type => ::Thrift::Types::I64, :name => 'maxQueryTime', :default => 9223372036854775807},
+      # Sets the uuid of this query, this is normal set by the client so that the status
+# of a running query can be found or the query can be canceled.
+      UUID => {:type => ::Thrift::Types::STRING, :name => 'uuid'},
+      # Sets a user context, only used for logging at this point.
+      USERCONTEXT => {:type => ::Thrift::Types::STRING, :name => 'userContext'},
+      # Enabled by default to cache this result.  False would not cache the result.
+      CACHERESULT => {:type => ::Thrift::Types::BOOL, :name => 'cacheResult', :default => true},
+      # Sets the start time, if 0 the controller sets the time.
+      STARTTIME => {:type => ::Thrift::Types::I64, :name => 'startTime', :default => 0}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The BlurResult carries the score, the location id and the fetched result (if any) form each query.
+  class BlurResult
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    LOCATIONID = 1
+    SCORE = 2
+    FETCHRESULT = 3
+
+    FIELDS = {
+      # WARNING: This is an internal only attribute and is not intended for use by clients.
+      LOCATIONID => {:type => ::Thrift::Types::STRING, :name => 'locationId'},
+      # The score for the hit in the query.
+      SCORE => {:type => ::Thrift::Types::DOUBLE, :name => 'score'},
+      # The fetched result if any.
+      FETCHRESULT => {:type => ::Thrift::Types::STRUCT, :name => 'fetchResult', :class => ::Blur::FetchResult}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # BlurResults holds all information resulting from a query.
+  class BlurResults
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    TOTALRESULTS = 1
+    SHARDINFO = 2
+    RESULTS = 3
+    FACETCOUNTS = 4
+    EXCEPTIONS = 5
+    QUERY = 6
+
+    FIELDS = {
+      # The total number of hits in the query.
+      TOTALRESULTS => {:type => ::Thrift::Types::I64, :name => 'totalResults', :default => 0},
+      # Hit counts from each shard in the table.
+      SHARDINFO => {:type => ::Thrift::Types::MAP, :name => 'shardInfo', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::I64}},
+      # The query results.
+      RESULTS => {:type => ::Thrift::Types::LIST, :name => 'results', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Blur::BlurResult}},
+      # The faceted count.
+      FACETCOUNTS => {:type => ::Thrift::Types::LIST, :name => 'facetCounts', :element => {:type => ::Thrift::Types::I64}},
+      # Not currently used, a future feature could allow for partial results with errors.
+      EXCEPTIONS => {:type => ::Thrift::Types::LIST, :name => 'exceptions', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Blur::BlurException}},
+      # The original query.
+      QUERY => {:type => ::Thrift::Types::STRUCT, :name => 'query', :class => ::Blur::BlurQuery}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The RowMutation defines how the given Record is to be mutated.
+  class RecordMutation
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    RECORDMUTATIONTYPE = 1
+    RECORD = 2
+
+    FIELDS = {
+      # Define how to mutate the given Record.
+      RECORDMUTATIONTYPE => {:type => ::Thrift::Types::I32, :name => 'recordMutationType', :default =>       1, :enum_class => ::Blur::RecordMutationType},
+      # The Record to mutate.
+      RECORD => {:type => ::Thrift::Types::STRUCT, :name => 'record', :class => ::Blur::Record}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+      unless @recordMutationType.nil? || ::Blur::RecordMutationType::VALID_VALUES.include?(@recordMutationType)
+        raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field recordMutationType!')
+      end
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The RowMutation defines how the given Row is to be mutated.
+  class RowMutation
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    TABLE = 1
+    ROWID = 2
+    WAL = 3
+    ROWMUTATIONTYPE = 4
+    RECORDMUTATIONS = 5
+    WAITTOBEVISIBLE = 6
+
+    FIELDS = {
+      # The table that the row mutation is to act upon.
+      TABLE => {:type => ::Thrift::Types::STRING, :name => 'table'},
+      # The row id that the row mutation is to act upon.
+      ROWID => {:type => ::Thrift::Types::STRING, :name => 'rowId'},
+      # Write ahead log, by default all updates are written to a write ahead log before the update is applied.  That way if a failure occurs before the index is committed the WAL can be replayed to recover any data that could have been lost.
+      WAL => {:type => ::Thrift::Types::BOOL, :name => 'wal', :default => true},
+      # The RowMutationType to define how to mutate the given Row.
+      ROWMUTATIONTYPE => {:type => ::Thrift::Types::I32, :name => 'rowMutationType', :default =>       1, :enum_class => ::Blur::RowMutationType},
+      # The RecordMutations if any for this Row.
+      RECORDMUTATIONS => {:type => ::Thrift::Types::LIST, :name => 'recordMutations', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Blur::RecordMutation}},
+      # On mutate waits for the mutation to be visible to queries and fetch requests.
+      WAITTOBEVISIBLE => {:type => ::Thrift::Types::BOOL, :name => 'waitToBeVisible', :default => false}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+      unless @rowMutationType.nil? || ::Blur::RowMutationType::VALID_VALUES.include?(@rowMutationType)
+        raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field rowMutationType!')
+      end
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # Holds the cpu time for a query executing on a single shard in a table.
+  class CpuTime
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    CPUTIME = 1
+    REALTIME = 2
+
+    FIELDS = {
+      # The total cpu time for the query on the given shard.
+      CPUTIME => {:type => ::Thrift::Types::I64, :name => 'cpuTime'},
+      # The real time of the query execution for a given shard.
+      REALTIME => {:type => ::Thrift::Types::I64, :name => 'realTime'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The BlurQueryStatus object hold the status of BlurQueries.  The state of the query
+# (QueryState), the number of shards the query is executing against, the number of
+# shards that are complete, etc.
+  class BlurQueryStatus
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    QUERY = 1
+    CPUTIMES = 2
+    COMPLETESHARDS = 3
+    TOTALSHARDS = 4
+    STATE = 5
+    UUID = 6
+    STATUS = 7
+
+    FIELDS = {
+      # The original query.
+      QUERY => {:type => ::Thrift::Types::STRUCT, :name => 'query', :class => ::Blur::BlurQuery},
+      # A map of shard names to CpuTime, one for each shard in the table.
+      CPUTIMES => {:type => ::Thrift::Types::MAP, :name => 'cpuTimes', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRUCT, :class => ::Blur::CpuTime}},
+      # The number of completed shards.  The shard server will respond with
+# how many are complete on that server, while the controller will aggregate
+# all the shard server completed totals together.
+      COMPLETESHARDS => {:type => ::Thrift::Types::I32, :name => 'completeShards'},
+      # The total number of shards that the query is executing against.  The shard
+# server will respond with how many shards are being queried on that server, while
+# the controller will aggregate all the shard server totals together.
+      TOTALSHARDS => {:type => ::Thrift::Types::I32, :name => 'totalShards'},
+      # The state of the query.  e.g. RUNNING, INTERRUPTED, COMPLETE
+      STATE => {:type => ::Thrift::Types::I32, :name => 'state', :enum_class => ::Blur::QueryState},
+      # The uuid of the query.
+      UUID => {:type => ::Thrift::Types::STRING, :name => 'uuid'},
+      # The status of the query NOT_FOUND if uuid is not found else FOUND
+      STATUS => {:type => ::Thrift::Types::I32, :name => 'status', :enum_class => ::Blur::Status}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+      unless @state.nil? || ::Blur::QueryState::VALID_VALUES.include?(@state)
+        raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field state!')
+      end
+      unless @status.nil? || ::Blur::Status::VALID_VALUES.include?(@status)
+        raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field status!')
+      end
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # TableStats holds the statistics for a given table.
+  class TableStats
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    TABLENAME = 1
+    BYTES = 2
+    RECORDCOUNT = 3
+    ROWCOUNT = 4
+
+    FIELDS = {
+      # The table name.
+      TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName'},
+      # The size in bytes.
+      BYTES => {:type => ::Thrift::Types::I64, :name => 'bytes'},
+      # The record count.
+      RECORDCOUNT => {:type => ::Thrift::Types::I64, :name => 'recordCount'},
+      # The row count.
+      ROWCOUNT => {:type => ::Thrift::Types::I64, :name => 'rowCount'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The ColumnDefinition defines how a given Column should be interpreted (indexed/stored)
+  class ColumnDefinition
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    FAMILY = 1
+    COLUMNNAME = 2
+    SUBCOLUMNNAME = 3
+    FIELDLESSINDEXED = 4
+    FIELDTYPE = 5
+    PROPERTIES = 6
+
+    FIELDS = {
+      # Required. The family that this column exists within.
+      FAMILY => {:type => ::Thrift::Types::STRING, :name => 'family'},
+      # Required. The column name.
+      COLUMNNAME => {:type => ::Thrift::Types::STRING, :name => 'columnName'},
+      # If this column definition is for a sub column then provide the sub column name.  Otherwise leave this field null.
+      SUBCOLUMNNAME => {:type => ::Thrift::Types::STRING, :name => 'subColumnName'},
+      # If this column should be searchable without having to specify the name of the column in the query.
+# NOTE: This will index the column as a full text field in a default field, so that means it's going to be indexed twice.
+      FIELDLESSINDEXED => {:type => ::Thrift::Types::BOOL, :name => 'fieldLessIndexed'},
+      # The field type for the column.  The built in types are:
+# <ul>
+# <li>text - Full text indexing.</li>
+# <li>string - Indexed string literal</li>
+# <li>int - Converted to an integer and indexed numerically.</li>
+# <li>long - Converted to an long and indexed numerically.</li>
+# <li>float - Converted to an float and indexed numerically.</li>
+# <li>double - Converted to an double and indexed numerically.</li>
+# <li>stored - Not indexed, only stored.</li>
+# </ul>
+      FIELDTYPE => {:type => ::Thrift::Types::STRING, :name => 'fieldType'},
+      # For any custom field types, you can pass in configuration properties.
+      PROPERTIES => {:type => ::Thrift::Types::MAP, :name => 'properties', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The current schema of the table.
+  class Schema
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    TABLE = 1
+    FAMILIES = 2
+
+    FIELDS = {
+      # The table name.
+      TABLE => {:type => ::Thrift::Types::STRING, :name => 'table'},
+      # Families and the column definitions within them.
+      FAMILIES => {:type => ::Thrift::Types::MAP, :name => 'families', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::MAP, :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRUCT, :class => ::Blur::ColumnDefinition}}}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The table descriptor defines the base structure of the table as well as properties need for setup.
+  class TableDescriptor
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    ENABLED = 1
+    SHARDCOUNT = 3
+    TABLEURI = 4
+    CLUSTER = 7
+    NAME = 8
+    SIMILARITYCLASS = 9
+    BLOCKCACHING = 10
+    BLOCKCACHINGFILETYPES = 11
+    READONLY = 12
+    PRECACHECOLS = 13
+    TABLEPROPERTIES = 14
+    STRICTTYPES = 15
+    DEFAULTMISSINGFIELDTYPE = 16
+    DEFAULTMISSINGFIELDLESSINDEXING = 17
+    DEFAULTMISSINGFIELDPROPS = 18
+
+    FIELDS = {
+      # Is the table enabled or not, enabled by default.
+      ENABLED => {:type => ::Thrift::Types::BOOL, :name => 'enabled', :default => true},
+      # The number of shards within the given table.
+      SHARDCOUNT => {:type => ::Thrift::Types::I32, :name => 'shardCount', :default => 1},
+      # The location where the table should be stored this can be "file:///" for a local instance of Blur or "hdfs://" for a distributed installation of Blur.
+      TABLEURI => {:type => ::Thrift::Types::STRING, :name => 'tableUri'},
+      # The cluster where this table should be created.
+      CLUSTER => {:type => ::Thrift::Types::STRING, :name => 'cluster', :default => %q"default"},
+      # The table name.
+      NAME => {:type => ::Thrift::Types::STRING, :name => 'name'},
+      # Sets the similarity class in Lucene.
+      SIMILARITYCLASS => {:type => ::Thrift::Types::STRING, :name => 'similarityClass'},
+      # Should block cache be enable or disabled for this table.
+      BLOCKCACHING => {:type => ::Thrift::Types::BOOL, :name => 'blockCaching', :default => true},
+      # The files extensions that you would like to allow block cache to cache.  If null (default) everything is cached.
+      BLOCKCACHINGFILETYPES => {:type => ::Thrift::Types::SET, :name => 'blockCachingFileTypes', :element => {:type => ::Thrift::Types::STRING}},
+      # If a table is set to be readonly, that means that mutates through Thrift are NOT allowed.  However
+# updates through MapReduce are allowed and in fact they are only allowed if the table is in readOnly mode.
+      READONLY => {:type => ::Thrift::Types::BOOL, :name => 'readOnly', :default => false},
+      # This map sets what column families and columns to prefetch into block cache on shard open.
+      PRECACHECOLS => {:type => ::Thrift::Types::LIST, :name => 'preCacheCols', :element => {:type => ::Thrift::Types::STRING}},
+      # The table properties that can modify the default behavior of the table.  TODO: Document all options.
+      TABLEPROPERTIES => {:type => ::Thrift::Types::MAP, :name => 'tableProperties', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}},
+      # Whether strict types are enabled or not (default).  If they are enabled no column can be added without first having it's type defined.
+      STRICTTYPES => {:type => ::Thrift::Types::BOOL, :name => 'strictTypes', :default => false},
+      # If strict is not enabled, the default field type.
+      DEFAULTMISSINGFIELDTYPE => {:type => ::Thrift::Types::STRING, :name => 'defaultMissingFieldType', :default => %q"text"},
+      # If strict is not enabled, defines whether or not field less indexing is enabled on the newly created fields.
+      DEFAULTMISSINGFIELDLESSINDEXING => {:type => ::Thrift::Types::BOOL, :name => 'defaultMissingFieldLessIndexing', :default => true},
+      # If strict is not enabled, defines the properties to be used in the new field creation.
+      DEFAULTMISSINGFIELDPROPS => {:type => ::Thrift::Types::MAP, :name => 'defaultMissingFieldProps', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  # The Metric will hold all the information for a given Metric.
+  class Metric
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    NAME = 1
+    STRMAP = 2
+    LONGMAP = 3
+    DOUBLEMAP = 4
+
+    FIELDS = {
+      # metric name.
+      NAME => {:type => ::Thrift::Types::STRING, :name => 'name'},
+      # map of string values emitted by the Metric.
+      STRMAP => {:type => ::Thrift::Types::MAP, :name => 'strMap', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}},
+      # map of long values emitted by the Metric.
+      LONGMAP => {:type => ::Thrift::Types::MAP, :name => 'longMap', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::I64}},
+      # map of double values emitted by the Metric.
+      DOUBLEMAP => {:type => ::Thrift::Types::MAP, :name => 'doubleMap', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::DOUBLE}}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+end

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/11a2529a/contrib/blur-console-v1/blur-admin/lib/thrift/hadoopfs_constants.rb
----------------------------------------------------------------------
diff --git a/contrib/blur-console-v1/blur-admin/lib/thrift/hadoopfs_constants.rb b/contrib/blur-console-v1/blur-admin/lib/thrift/hadoopfs_constants.rb
new file mode 100644
index 0000000..b6517a8
--- /dev/null
+++ b/contrib/blur-console-v1/blur-admin/lib/thrift/hadoopfs_constants.rb
@@ -0,0 +1,23 @@
+# 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.
+
+#
+# Autogenerated by Thrift
+#
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+#
+
+require 'hadoopfs_types'
+

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/11a2529a/contrib/blur-console-v1/blur-admin/lib/thrift/hadoopfs_types.rb
----------------------------------------------------------------------
diff --git a/contrib/blur-console-v1/blur-admin/lib/thrift/hadoopfs_types.rb b/contrib/blur-console-v1/blur-admin/lib/thrift/hadoopfs_types.rb
new file mode 100644
index 0000000..396140a
--- /dev/null
+++ b/contrib/blur-console-v1/blur-admin/lib/thrift/hadoopfs_types.rb
@@ -0,0 +1,152 @@
+# 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.
+
+#
+# Autogenerated by Thrift
+#
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+#
+
+module ThriftHadoopFileSystem
+
+class ThriftHandle
+  include ::Thrift::Struct, ::Thrift::Struct_Union
+  ID = -1
+
+  FIELDS = {
+    ID => {:type => ::Thrift::Types::I64, :name => 'id'}
+  }
+
+  def struct_fields; FIELDS; end
+
+  def validate
+  end
+
+  ::Thrift::Struct.generate_accessors self
+end
+
+class Pathname
+  include ::Thrift::Struct, ::Thrift::Struct_Union
+  PATHNAME = -1
+
+  FIELDS = {
+    PATHNAME => {:type => ::Thrift::Types::STRING, :name => 'pathname'}
+  }
+
+  def struct_fields; FIELDS; end
+
+  def validate
+  end
+
+  ::Thrift::Struct.generate_accessors self
+end
+
+class FileStatus
+  include ::Thrift::Struct, ::Thrift::Struct_Union
+  PATH = 1
+  LENGTH = 2
+  ISDIR = 3
+  BLOCK_REPLICATION = 4
+  BLOCKSIZE = 5
+  MODIFICATION_TIME = 6
+  PERMISSION = 7
+  OWNER = 8
+  GROUP = 9
+
+  FIELDS = {
+    PATH => {:type => ::Thrift::Types::STRING, :name => 'path'},
+    LENGTH => {:type => ::Thrift::Types::I64, :name => 'length'},
+    ISDIR => {:type => ::Thrift::Types::BOOL, :name => 'isdir'},
+    BLOCK_REPLICATION => {:type => ::Thrift::Types::I16, :name => 'block_replication'},
+    BLOCKSIZE => {:type => ::Thrift::Types::I64, :name => 'blocksize'},
+    MODIFICATION_TIME => {:type => ::Thrift::Types::I64, :name => 'modification_time'},
+    PERMISSION => {:type => ::Thrift::Types::STRING, :name => 'permission'},
+    OWNER => {:type => ::Thrift::Types::STRING, :name => 'owner'},
+    GROUP => {:type => ::Thrift::Types::STRING, :name => 'group'}
+  }
+
+  def struct_fields; FIELDS; end
+
+  def validate
+  end
+
+  ::Thrift::Struct.generate_accessors self
+end
+
+class BlockLocation
+  include ::Thrift::Struct, ::Thrift::Struct_Union
+  HOSTS = 1
+  NAMES = 2
+  OFFSET = 3
+  LENGTH = 4
+
+  FIELDS = {
+    HOSTS => {:type => ::Thrift::Types::LIST, :name => 'hosts', :element => {:type => ::Thrift::Types::STRING}},
+    NAMES => {:type => ::Thrift::Types::LIST, :name => 'names', :element => {:type => ::Thrift::Types::STRING}},
+    OFFSET => {:type => ::Thrift::Types::I64, :name => 'offset'},
+    LENGTH => {:type => ::Thrift::Types::I64, :name => 'length'}
+  }
+
+  def struct_fields; FIELDS; end
+
+  def validate
+  end
+
+  ::Thrift::Struct.generate_accessors self
+end
+
+class MalformedInputException < ::Thrift::Exception
+  include ::Thrift::Struct, ::Thrift::Struct_Union
+  def initialize(message=nil)
+    super()
+    self.message = message
+  end
+
+  MESSAGE = -1
+
+  FIELDS = {
+    MESSAGE => {:type => ::Thrift::Types::STRING, :name => 'message'}
+  }
+
+  def struct_fields; FIELDS; end
+
+  def validate
+  end
+
+  ::Thrift::Struct.generate_accessors self
+end
+
+class ThriftIOException < ::Thrift::Exception
+  include ::Thrift::Struct, ::Thrift::Struct_Union
+  def initialize(message=nil)
+    super()
+    self.message = message
+  end
+
+  MESSAGE = -1
+
+  FIELDS = {
+    MESSAGE => {:type => ::Thrift::Types::STRING, :name => 'message'}
+  }
+
+  def struct_fields; FIELDS; end
+
+  def validate
+  end
+
+  ::Thrift::Struct.generate_accessors self
+end
+
+end

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/11a2529a/contrib/blur-console-v1/blur-admin/lib/thrift/thrift_hadoop_file_system.rb
----------------------------------------------------------------------
diff --git a/contrib/blur-console-v1/blur-admin/lib/thrift/thrift_hadoop_file_system.rb b/contrib/blur-console-v1/blur-admin/lib/thrift/thrift_hadoop_file_system.rb
new file mode 100644
index 0000000..bc0d149
--- /dev/null
+++ b/contrib/blur-console-v1/blur-admin/lib/thrift/thrift_hadoop_file_system.rb
@@ -0,0 +1,1203 @@
+# 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.
+
+#
+# Autogenerated by Thrift
+#
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+#
+
+require 'thrift'
+require 'hadoopfs_types'
+
+module ThriftHadoopFileSystem
+  class Client
+    include ::Thrift::Client
+
+    def setInactivityTimeoutPeriod(periodInSeconds)
+      send_setInactivityTimeoutPeriod(periodInSeconds)
+      recv_setInactivityTimeoutPeriod()
+    end
+
+    def send_setInactivityTimeoutPeriod(periodInSeconds)
+      send_message('setInactivityTimeoutPeriod', SetInactivityTimeoutPeriod_args, :periodInSeconds => periodInSeconds)
+    end
+
+    def recv_setInactivityTimeoutPeriod()
+      result = receive_message(SetInactivityTimeoutPeriod_result)
+      return
+    end
+
+    def shutdown(status)
+      send_shutdown(status)
+      recv_shutdown()
+    end
+
+    def send_shutdown(status)
+      send_message('shutdown', Shutdown_args, :status => status)
+    end
+
+    def recv_shutdown()
+      result = receive_message(Shutdown_result)
+      return
+    end
+
+    def create(path)
+      send_create(path)
+      return recv_create()
+    end
+
+    def send_create(path)
+      send_message('create', Create_args, :path => path)
+    end
+
+    def recv_create()
+      result = receive_message(Create_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'create failed: unknown result')
+    end
+
+    def createFile(path, mode, overwrite, bufferSize, block_replication, blocksize)
+      send_createFile(path, mode, overwrite, bufferSize, block_replication, blocksize)
+      return recv_createFile()
+    end
+
+    def send_createFile(path, mode, overwrite, bufferSize, block_replication, blocksize)
+      send_message('createFile', CreateFile_args, :path => path, :mode => mode, :overwrite => overwrite, :bufferSize => bufferSize, :block_replication => block_replication, :blocksize => blocksize)
+    end
+
+    def recv_createFile()
+      result = receive_message(CreateFile_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'createFile failed: unknown result')
+    end
+
+    def open(path)
+      send_open(path)
+      return recv_open()
+    end
+
+    def send_open(path)
+      send_message('open', Open_args, :path => path)
+    end
+
+    def recv_open()
+      result = receive_message(Open_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'open failed: unknown result')
+    end
+
+    def append(path)
+      send_append(path)
+      return recv_append()
+    end
+
+    def send_append(path)
+      send_message('append', Append_args, :path => path)
+    end
+
+    def recv_append()
+      result = receive_message(Append_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'append failed: unknown result')
+    end
+
+    def write(handle, data)
+      send_write(handle, data)
+      return recv_write()
+    end
+
+    def send_write(handle, data)
+      send_message('write', Write_args, :handle => handle, :data => data)
+    end
+
+    def recv_write()
+      result = receive_message(Write_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'write failed: unknown result')
+    end
+
+    def read(handle, offset, size)
+      send_read(handle, offset, size)
+      return recv_read()
+    end
+
+    def send_read(handle, offset, size)
+      send_message('read', Read_args, :handle => handle, :offset => offset, :size => size)
+    end
+
+    def recv_read()
+      result = receive_message(Read_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'read failed: unknown result')
+    end
+
+    def close(out)
+      send_close(out)
+      return recv_close()
+    end
+
+    def send_close(out)
+      send_message('close', Close_args, :out => out)
+    end
+
+    def recv_close()
+      result = receive_message(Close_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'close failed: unknown result')
+    end
+
+    def rm(path, recursive)
+      send_rm(path, recursive)
+      return recv_rm()
+    end
+
+    def send_rm(path, recursive)
+      send_message('rm', Rm_args, :path => path, :recursive => recursive)
+    end
+
+    def recv_rm()
+      result = receive_message(Rm_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'rm failed: unknown result')
+    end
+
+    def rename(path, dest)
+      send_rename(path, dest)
+      return recv_rename()
+    end
+
+    def send_rename(path, dest)
+      send_message('rename', Rename_args, :path => path, :dest => dest)
+    end
+
+    def recv_rename()
+      result = receive_message(Rename_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'rename failed: unknown result')
+    end
+
+    def mkdirs(path)
+      send_mkdirs(path)
+      return recv_mkdirs()
+    end
+
+    def send_mkdirs(path)
+      send_message('mkdirs', Mkdirs_args, :path => path)
+    end
+
+    def recv_mkdirs()
+      result = receive_message(Mkdirs_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'mkdirs failed: unknown result')
+    end
+
+    def exists(path)
+      send_exists(path)
+      return recv_exists()
+    end
+
+    def send_exists(path)
+      send_message('exists', Exists_args, :path => path)
+    end
+
+    def recv_exists()
+      result = receive_message(Exists_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'exists failed: unknown result')
+    end
+
+    def stat(path)
+      send_stat(path)
+      return recv_stat()
+    end
+
+    def send_stat(path)
+      send_message('stat', Stat_args, :path => path)
+    end
+
+    def recv_stat()
+      result = receive_message(Stat_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'stat failed: unknown result')
+    end
+
+    def listStatus(path)
+      send_listStatus(path)
+      return recv_listStatus()
+    end
+
+    def send_listStatus(path)
+      send_message('listStatus', ListStatus_args, :path => path)
+    end
+
+    def recv_listStatus()
+      result = receive_message(ListStatus_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'listStatus failed: unknown result')
+    end
+
+    def chmod(path, mode)
+      send_chmod(path, mode)
+      recv_chmod()
+    end
+
+    def send_chmod(path, mode)
+      send_message('chmod', Chmod_args, :path => path, :mode => mode)
+    end
+
+    def recv_chmod()
+      result = receive_message(Chmod_result)
+      raise result.ouch unless result.ouch.nil?
+      return
+    end
+
+    def chown(path, owner, group)
+      send_chown(path, owner, group)
+      recv_chown()
+    end
+
+    def send_chown(path, owner, group)
+      send_message('chown', Chown_args, :path => path, :owner => owner, :group => group)
+    end
+
+    def recv_chown()
+      result = receive_message(Chown_result)
+      raise result.ouch unless result.ouch.nil?
+      return
+    end
+
+    def setReplication(path, replication)
+      send_setReplication(path, replication)
+      recv_setReplication()
+    end
+
+    def send_setReplication(path, replication)
+      send_message('setReplication', SetReplication_args, :path => path, :replication => replication)
+    end
+
+    def recv_setReplication()
+      result = receive_message(SetReplication_result)
+      raise result.ouch unless result.ouch.nil?
+      return
+    end
+
+    def getFileBlockLocations(path, start, length)
+      send_getFileBlockLocations(path, start, length)
+      return recv_getFileBlockLocations()
+    end
+
+    def send_getFileBlockLocations(path, start, length)
+      send_message('getFileBlockLocations', GetFileBlockLocations_args, :path => path, :start => start, :length => length)
+    end
+
+    def recv_getFileBlockLocations()
+      result = receive_message(GetFileBlockLocations_result)
+      return result.success unless result.success.nil?
+      raise result.ouch unless result.ouch.nil?
+      raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'getFileBlockLocations failed: unknown result')
+    end
+
+  end
+
+  class Processor
+    include ::Thrift::Processor
+
+    def process_setInactivityTimeoutPeriod(seqid, iprot, oprot)
+      args = read_args(iprot, SetInactivityTimeoutPeriod_args)
+      result = SetInactivityTimeoutPeriod_result.new()
+      @handler.setInactivityTimeoutPeriod(args.periodInSeconds)
+      write_result(result, oprot, 'setInactivityTimeoutPeriod', seqid)
+    end
+
+    def process_shutdown(seqid, iprot, oprot)
+      args = read_args(iprot, Shutdown_args)
+      result = Shutdown_result.new()
+      @handler.shutdown(args.status)
+      write_result(result, oprot, 'shutdown', seqid)
+    end
+
+    def process_create(seqid, iprot, oprot)
+      args = read_args(iprot, Create_args)
+      result = Create_result.new()
+      begin
+        result.success = @handler.create(args.path)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'create', seqid)
+    end
+
+    def process_createFile(seqid, iprot, oprot)
+      args = read_args(iprot, CreateFile_args)
+      result = CreateFile_result.new()
+      begin
+        result.success = @handler.createFile(args.path, args.mode, args.overwrite, args.bufferSize, args.block_replication, args.blocksize)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'createFile', seqid)
+    end
+
+    def process_open(seqid, iprot, oprot)
+      args = read_args(iprot, Open_args)
+      result = Open_result.new()
+      begin
+        result.success = @handler.open(args.path)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'open', seqid)
+    end
+
+    def process_append(seqid, iprot, oprot)
+      args = read_args(iprot, Append_args)
+      result = Append_result.new()
+      begin
+        result.success = @handler.append(args.path)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'append', seqid)
+    end
+
+    def process_write(seqid, iprot, oprot)
+      args = read_args(iprot, Write_args)
+      result = Write_result.new()
+      begin
+        result.success = @handler.write(args.handle, args.data)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'write', seqid)
+    end
+
+    def process_read(seqid, iprot, oprot)
+      args = read_args(iprot, Read_args)
+      result = Read_result.new()
+      begin
+        result.success = @handler.read(args.handle, args.offset, args.size)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'read', seqid)
+    end
+
+    def process_close(seqid, iprot, oprot)
+      args = read_args(iprot, Close_args)
+      result = Close_result.new()
+      begin
+        result.success = @handler.close(args.out)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'close', seqid)
+    end
+
+    def process_rm(seqid, iprot, oprot)
+      args = read_args(iprot, Rm_args)
+      result = Rm_result.new()
+      begin
+        result.success = @handler.rm(args.path, args.recursive)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'rm', seqid)
+    end
+
+    def process_rename(seqid, iprot, oprot)
+      args = read_args(iprot, Rename_args)
+      result = Rename_result.new()
+      begin
+        result.success = @handler.rename(args.path, args.dest)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'rename', seqid)
+    end
+
+    def process_mkdirs(seqid, iprot, oprot)
+      args = read_args(iprot, Mkdirs_args)
+      result = Mkdirs_result.new()
+      begin
+        result.success = @handler.mkdirs(args.path)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'mkdirs', seqid)
+    end
+
+    def process_exists(seqid, iprot, oprot)
+      args = read_args(iprot, Exists_args)
+      result = Exists_result.new()
+      begin
+        result.success = @handler.exists(args.path)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'exists', seqid)
+    end
+
+    def process_stat(seqid, iprot, oprot)
+      args = read_args(iprot, Stat_args)
+      result = Stat_result.new()
+      begin
+        result.success = @handler.stat(args.path)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'stat', seqid)
+    end
+
+    def process_listStatus(seqid, iprot, oprot)
+      args = read_args(iprot, ListStatus_args)
+      result = ListStatus_result.new()
+      begin
+        result.success = @handler.listStatus(args.path)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'listStatus', seqid)
+    end
+
+    def process_chmod(seqid, iprot, oprot)
+      args = read_args(iprot, Chmod_args)
+      result = Chmod_result.new()
+      begin
+        @handler.chmod(args.path, args.mode)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'chmod', seqid)
+    end
+
+    def process_chown(seqid, iprot, oprot)
+      args = read_args(iprot, Chown_args)
+      result = Chown_result.new()
+      begin
+        @handler.chown(args.path, args.owner, args.group)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'chown', seqid)
+    end
+
+    def process_setReplication(seqid, iprot, oprot)
+      args = read_args(iprot, SetReplication_args)
+      result = SetReplication_result.new()
+      begin
+        @handler.setReplication(args.path, args.replication)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'setReplication', seqid)
+    end
+
+    def process_getFileBlockLocations(seqid, iprot, oprot)
+      args = read_args(iprot, GetFileBlockLocations_args)
+      result = GetFileBlockLocations_result.new()
+      begin
+        result.success = @handler.getFileBlockLocations(args.path, args.start, args.length)
+      rescue ThriftIOException => ouch
+        result.ouch = ouch
+      end
+      write_result(result, oprot, 'getFileBlockLocations', seqid)
+    end
+
+  end
+
+  # HELPER FUNCTIONS AND STRUCTURES
+
+  class SetInactivityTimeoutPeriod_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PERIODINSECONDS = 1
+
+    FIELDS = {
+      PERIODINSECONDS => {:type => ::Thrift::Types::I64, :name => 'periodInSeconds'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class SetInactivityTimeoutPeriod_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+
+    FIELDS = {
+
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Shutdown_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    STATUS = 1
+
+    FIELDS = {
+      STATUS => {:type => ::Thrift::Types::I32, :name => 'status'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Shutdown_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+
+    FIELDS = {
+
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Create_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Create_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::STRUCT, :name => 'success', :class => ThriftHandle},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class CreateFile_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+    MODE = 2
+    OVERWRITE = 3
+    BUFFERSIZE = 4
+    BLOCK_REPLICATION = 5
+    BLOCKSIZE = 6
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname},
+      MODE => {:type => ::Thrift::Types::I16, :name => 'mode'},
+      OVERWRITE => {:type => ::Thrift::Types::BOOL, :name => 'overwrite'},
+      BUFFERSIZE => {:type => ::Thrift::Types::I32, :name => 'bufferSize'},
+      BLOCK_REPLICATION => {:type => ::Thrift::Types::I16, :name => 'block_replication'},
+      BLOCKSIZE => {:type => ::Thrift::Types::I64, :name => 'blocksize'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class CreateFile_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::STRUCT, :name => 'success', :class => ThriftHandle},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Open_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Open_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::STRUCT, :name => 'success', :class => ThriftHandle},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Append_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Append_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::STRUCT, :name => 'success', :class => ThriftHandle},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Write_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    HANDLE = 1
+    DATA = -1
+
+    FIELDS = {
+      HANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'handle', :class => ThriftHandle},
+      DATA => {:type => ::Thrift::Types::STRING, :name => 'data'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Write_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::BOOL, :name => 'success'},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Read_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    HANDLE = 1
+    OFFSET = -1
+    SIZE = -2
+
+    FIELDS = {
+      HANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'handle', :class => ThriftHandle},
+      OFFSET => {:type => ::Thrift::Types::I64, :name => 'offset'},
+      SIZE => {:type => ::Thrift::Types::I32, :name => 'size'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Read_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::STRING, :name => 'success'},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Close_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    OUT = 1
+
+    FIELDS = {
+      OUT => {:type => ::Thrift::Types::STRUCT, :name => 'out', :class => ThriftHandle}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Close_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::BOOL, :name => 'success'},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Rm_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+    RECURSIVE = 2
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname},
+      RECURSIVE => {:type => ::Thrift::Types::BOOL, :name => 'recursive'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Rm_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::BOOL, :name => 'success'},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Rename_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+    DEST = 2
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname},
+      DEST => {:type => ::Thrift::Types::STRUCT, :name => 'dest', :class => Pathname}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Rename_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::BOOL, :name => 'success'},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Mkdirs_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Mkdirs_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::BOOL, :name => 'success'},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Exists_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Exists_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::BOOL, :name => 'success'},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Stat_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Stat_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::STRUCT, :name => 'success', :class => FileStatus},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class ListStatus_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class ListStatus_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::LIST, :name => 'success', :element => {:type => ::Thrift::Types::STRUCT, :class => FileStatus}},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Chmod_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+    MODE = 2
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname},
+      MODE => {:type => ::Thrift::Types::I16, :name => 'mode'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Chmod_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    OUCH = 1
+
+    FIELDS = {
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Chown_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+    OWNER = 2
+    GROUP = 3
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname},
+      OWNER => {:type => ::Thrift::Types::STRING, :name => 'owner'},
+      GROUP => {:type => ::Thrift::Types::STRING, :name => 'group'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class Chown_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    OUCH = 1
+
+    FIELDS = {
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class SetReplication_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+    REPLICATION = 2
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname},
+      REPLICATION => {:type => ::Thrift::Types::I16, :name => 'replication'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class SetReplication_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    OUCH = 1
+
+    FIELDS = {
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class GetFileBlockLocations_args
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    PATH = 1
+    START = 2
+    LENGTH = 3
+
+    FIELDS = {
+      PATH => {:type => ::Thrift::Types::STRUCT, :name => 'path', :class => Pathname},
+      START => {:type => ::Thrift::Types::I64, :name => 'start'},
+      LENGTH => {:type => ::Thrift::Types::I64, :name => 'length'}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+  class GetFileBlockLocations_result
+    include ::Thrift::Struct, ::Thrift::Struct_Union
+    SUCCESS = 0
+    OUCH = 1
+
+    FIELDS = {
+      SUCCESS => {:type => ::Thrift::Types::LIST, :name => 'success', :element => {:type => ::Thrift::Types::STRUCT, :class => BlockLocation}},
+      OUCH => {:type => ::Thrift::Types::STRUCT, :name => 'ouch', :class => ThriftIOException}
+    }
+
+    def struct_fields; FIELDS; end
+
+    def validate
+    end
+
+    ::Thrift::Struct.generate_accessors self
+  end
+
+end
+

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/11a2529a/contrib/blur-console-v1/blur-admin/public/robots.txt
----------------------------------------------------------------------
diff --git a/contrib/blur-console-v1/blur-admin/public/robots.txt b/contrib/blur-console-v1/blur-admin/public/robots.txt
new file mode 100644
index 0000000..76d8227
--- /dev/null
+++ b/contrib/blur-console-v1/blur-admin/public/robots.txt
@@ -0,0 +1,23 @@
+#  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.
+
+
+# See http://www.robotstxt.org/wc/norobots.html for documentation on how to use the robots.txt file
+#
+# To ban all spiders from the entire site uncomment the next two lines:
+# User-Agent: *
+# Disallow: /

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/11a2529a/contrib/blur-console-v1/blur-admin/script/rails
----------------------------------------------------------------------
diff --git a/contrib/blur-console-v1/blur-admin/script/rails b/contrib/blur-console-v1/blur-admin/script/rails
new file mode 100755
index 0000000..058f674
--- /dev/null
+++ b/contrib/blur-console-v1/blur-admin/script/rails
@@ -0,0 +1,27 @@
+#!/usr/bin/env ruby
+# Copyright (c) 2004-2013 David Heinemeier Hansson
+
+# Permission is hereby granted, free of charge, to any person obtaining
+# a copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sublicense, and/or sell copies of the Software, and to
+# permit persons to whom the Software is furnished to do so, subject to
+# the following conditions:
+# 
+# The above copyright notice and this permission notice shall be
+# included in all copies or substantial portions of the Software.
+# 
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+# This command will automatically be run when you run "rails" with Rails 3 gems installed from the root of your application.
+
+APP_PATH = File.expand_path('../../config/application',  __FILE__)
+require File.expand_path('../../config/boot',  __FILE__)
+require 'rails/commands'

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/11a2529a/contrib/blur-console-v1/blur-admin/spec/controllers/admin_settings_controller_spec.rb
----------------------------------------------------------------------
diff --git a/contrib/blur-console-v1/blur-admin/spec/controllers/admin_settings_controller_spec.rb b/contrib/blur-console-v1/blur-admin/spec/controllers/admin_settings_controller_spec.rb
new file mode 100644
index 0000000..98aceff
--- /dev/null
+++ b/contrib/blur-console-v1/blur-admin/spec/controllers/admin_settings_controller_spec.rb
@@ -0,0 +1,60 @@
+# 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.
+
+require 'spec_helper'
+
+describe AdminSettingsController do
+  describe "actions" do
+    before do
+      # Universal setup
+      setup_tests
+    end
+
+    describe 'PUT update' do
+      it 'should create a new admin setting when a previous one DNE' do
+        initial_count = AdminSetting.all.length
+        put :update, :setting => 'regex'
+        AdminSetting.all.length.should == initial_count + 1
+      end
+
+      it 'should find an admin setting when a previous one exists' do
+        setting = FactoryGirl.create :admin_setting
+        initial_count = AdminSetting.all.length
+        AdminSetting.should_receive(:find_or_create_by_setting).with('regex').and_return(setting)
+        put :update, :setting => 'regex'
+        AdminSetting.all.length.should == initial_count
+      end
+
+      it 'should update the setting to the given value' do
+        setting = FactoryGirl.create :admin_setting
+        AdminSetting.should_receive(:find_or_create_by_setting).with('regex').and_return(setting)
+        put :update, :setting => 'regex', :value => 'test'
+        setting.value.should == 'test'
+      end
+
+      it 'should succeed with a given setting' do
+        expect {
+          put :update, :setting => 'regex'
+        }.to_not raise_error
+      end
+
+      it 'should fail when a setting is not given' do
+        expect {
+          put :update
+        }.to raise_error
+      end
+    end
+  end
+end
\ No newline at end of file


Mime
View raw message