Updated Branches: refs/heads/0.1.5 2546a8d93 -> e3699254b
New util program. Project: http://git-wip-us.apache.org/repos/asf/incubator-blur/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-blur/commit/c19fa07b Tree: http://git-wip-us.apache.org/repos/asf/incubator-blur/tree/c19fa07b Diff: http://git-wip-us.apache.org/repos/asf/incubator-blur/diff/c19fa07b Branch: refs/heads/0.1.5 Commit: c19fa07bbf55c037d8f91b2d4e793afe1d2eb6bf Parents: 2546a8d Author: Aaron McCurry <[email protected]> Authored: Tue May 14 12:20:10 2013 -0400 Committer: Aaron McCurry <[email protected]> Committed: Tue May 14 12:20:10 2013 -0400 ---------------------------------------------------------------------- .../java/org/apache/blur/testsuite/StatsTable.java | 38 +++++++++++++++ 1 files changed, 38 insertions(+), 0 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/c19fa07b/src/blur-testsuite/src/main/java/org/apache/blur/testsuite/StatsTable.java ---------------------------------------------------------------------- diff --git a/src/blur-testsuite/src/main/java/org/apache/blur/testsuite/StatsTable.java b/src/blur-testsuite/src/main/java/org/apache/blur/testsuite/StatsTable.java new file mode 100644 index 0000000..0f824c8 --- /dev/null +++ b/src/blur-testsuite/src/main/java/org/apache/blur/testsuite/StatsTable.java @@ -0,0 +1,38 @@ +package org.apache.blur.testsuite; + +/** + * 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 java.io.IOException; + +import org.apache.blur.thrift.BlurClient; +import org.apache.blur.thrift.generated.BlurException; +import org.apache.blur.thrift.generated.Blur.Iface; +import org.apache.blur.thrift.generated.TableStats; +import org.apache.thrift.TException; + + +public class StatsTable { + + public static void main(String[] args) throws BlurException, TException, IOException { + String connectionStr = args[0]; + final String tableName = args[1]; + + Iface client = BlurClient.getClient(connectionStr); + TableStats tableStats = client.getTableStats(tableName); + System.out.println(tableStats); + } +}
