Skip to content

Commit 86a70bc

Browse files
authored
Move admin/ to client/ (#298)
This fixes #103. Moved the files from `bigtable/admin` to `bigtable/client`. Thanks to @paprat for catching the include guard changes.
1 parent 2c9ef33 commit 86a70bc

34 files changed

Lines changed: 77 additions & 241 deletions

bigtable/CMakeLists.txt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,6 @@ add_dependencies(depends-local gmock bigtable_protos)
156156
# All tests get added to this target below.
157157
add_custom_target(tests-local)
158158
add_subdirectory(client)
159-
add_subdirectory(admin)
160159
add_subdirectory(tests)
161160

162161
if (GOOGLE_CLOUD_CPP_ENABLE_CXX_EXCEPTIONS)
@@ -173,10 +172,6 @@ if (CLANG_TIDY_EXE AND BIGTABLE_CLIENT_CLANG_TIDY)
173172
bigtable_client PROPERTIES
174173
CXX_CLANG_TIDY "${CLANG_TIDY_EXE}"
175174
)
176-
set_target_properties(
177-
bigtable_admin_client PROPERTIES
178-
CXX_CLANG_TIDY "${CLANG_TIDY_EXE}"
179-
)
180175
endif ()
181176

182177
# Install the libraries and headers in the locations determined by

bigtable/admin/CMakeLists.txt

Lines changed: 0 additions & 80 deletions
This file was deleted.

bigtable/admin/config-version.cmake.in

Lines changed: 0 additions & 37 deletions
This file was deleted.

bigtable/admin/config.cmake.in

Lines changed: 0 additions & 19 deletions
This file was deleted.

bigtable/admin/config.pc.in

Lines changed: 0 additions & 25 deletions
This file was deleted.

bigtable/benchmarks/CMakeLists.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ add_library(bigtable_benchmark_common
2323
setup.h
2424
setup.cc)
2525
target_link_libraries(bigtable_benchmark_common
26-
bigtable_admin_client bigtable_client bigtable_protos
26+
bigtable_client bigtable_protos
2727
gRPC::grpc++ gRPC::grpc protobuf::libprotobuf)
2828

2929
# List the unit tests, then setup the targets and dependencies.
@@ -39,7 +39,7 @@ foreach (fname ${bigtable_benchmarks_unit_tests})
3939
set(target "bigtable_benchmarks_${target}")
4040
add_executable(${target} ${fname})
4141
target_link_libraries(${target} PRIVATE
42-
bigtable_benchmark_common bigtable_admin_client bigtable_client
42+
bigtable_benchmark_common bigtable_client
4343
bigtable_protos bigtable_common_options
4444
gmock gRPC::grpc++ gRPC::grpc protobuf::libprotobuf)
4545
add_test(NAME ${target} COMMAND ${target})
@@ -49,20 +49,20 @@ endforeach ()
4949
# Benchmark Table::ReadRows().
5050
add_executable(scan_throughput_benchmark scan_throughput_benchmark.cc)
5151
target_link_libraries(scan_throughput_benchmark PRIVATE
52-
bigtable_benchmark_common bigtable_admin_client bigtable_client
52+
bigtable_benchmark_common bigtable_client
5353
bigtable_protos bigtable_common_options
5454
gRPC::grpc++ gRPC::grpc protobuf::libprotobuf)
5555

5656
# Benchmark for Table::Apply() and Table::ReadRow().
5757
add_executable(apply_read_latency_benchmark apply_read_latency_benchmark.cc)
5858
target_link_libraries(apply_read_latency_benchmark PRIVATE
59-
bigtable_benchmark_common bigtable_admin_client bigtable_client
59+
bigtable_benchmark_common bigtable_client
6060
bigtable_protos bigtable_common_options
6161
gRPC::grpc++ gRPC::grpc protobuf::libprotobuf)
6262

6363
# A benchmark to measure performance of long running programs.
6464
add_executable(endurance_benchmark endurance_benchmark.cc)
6565
target_link_libraries(endurance_benchmark PRIVATE
66-
bigtable_benchmark_common bigtable_admin_client bigtable_client
66+
bigtable_benchmark_common bigtable_client
6767
bigtable_protos bigtable_common_options
6868
gRPC::grpc++ gRPC::grpc protobuf::libprotobuf)

bigtable/benchmarks/embedded_server_test.cc

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,10 @@
1313
// limitations under the License.
1414

1515
#include "bigtable/benchmarks/embedded_server.h"
16-
17-
#include <thread>
18-
1916
#include <gmock/gmock.h>
20-
21-
#include "bigtable/admin/table_admin.h"
17+
#include <thread>
2218
#include "bigtable/client/table.h"
19+
#include "bigtable/client/table_admin.h"
2320

2421
using namespace bigtable::benchmarks;
2522

bigtable/benchmarks/random.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717

1818
#include <algorithm>
1919
#include <random>
20-
#include "bigtable/admin/table_admin.h"
2120
#include "bigtable/client/table.h"
21+
#include "bigtable/client/table_admin.h"
2222

2323
namespace bigtable {
2424
namespace benchmarks {

bigtable/client/CMakeLists.txt

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,18 +17,25 @@ configure_file(version_info.h.in version_info.h)
1717

1818
# the client library
1919
add_library(bigtable_client
20+
admin_client.h
21+
admin_client.cc
2022
${CMAKE_CURRENT_BINARY_DIR}/build_info.cc
2123
${CMAKE_CURRENT_BINARY_DIR}/version_info.h
2224
build_info.h
2325
cell.h
2426
client_options.h
2527
client_options.cc
28+
column_family.h
2629
data_client.h
2730
data_client.cc
2831
filters.h
2932
filters.cc
3033
grpc_error.h
3134
grpc_error.cc
35+
instance_admin_client.h
36+
instance_admin_client.cc
37+
instance_admin.h
38+
instance_admin.cc
3239
internal/bulk_mutator.h
3340
internal/bulk_mutator.cc
3441
internal/common_client.h
@@ -64,6 +71,10 @@ add_library(bigtable_client
6471
rpc_retry_policy.cc
6572
table.h
6673
table.cc
74+
table_admin.h
75+
table_admin.cc
76+
table_config.h
77+
table_config.cc
6778
version.h
6879
version.cc)
6980
target_link_libraries(bigtable_client PUBLIC
@@ -92,20 +103,26 @@ target_link_libraries(bigtable_client_testing PUBLIC
92103

93104
# List the unit tests, then setup the targets and dependencies.
94105
set(bigtable_client_unit_tests
106+
admin_client_test.cc
95107
cell_test.cc
96108
client_options_test.cc
109+
column_family_test.cc
97110
data_client_test.cc
98111
filters_test.cc
99112
force_sanitizer_failures_test.cc
100113
grpc_error_test.cc
101114
idempotent_mutation_policy_test.cc
115+
instance_admin_client_test.cc
116+
instance_admin_test.cc
102117
internal/bulk_mutator_test.cc
103118
internal/prefix_range_end_test.cc
104119
internal/readrowsparser_test.cc
105120
mutations_test.cc
121+
table_admin_test.cc
106122
table_apply_test.cc
107123
table_bulk_apply_test.cc
108124
table_check_and_mutate_row_test.cc
125+
table_config_test.cc
109126
table_readrow_test.cc
110127
table_readrows_test.cc
111128
table_test.cc
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
1414

15-
#include "bigtable/admin/admin_client.h"
15+
#include "bigtable/client/admin_client.h"
1616
#include "bigtable/client/internal/common_client.h"
1717

1818
namespace {

0 commit comments

Comments
 (0)