From c644dc52c3238ddaa53cf43802ecbfda23453ecf Mon Sep 17 00:00:00 2001 From: Jon Janzen Date: Mon, 2 Dec 2024 10:12:04 -0800 Subject: [PATCH] Rewrite TARGETS files to BUCK files for facebook/wangle (#242) Summary: Pull Request resolved: https://github.com/facebook/wangle/pull/242 This diff migrates TARGETS file to BUCK files that are synced for an open source project. Differential Revision: D66561342 --- wangle/acceptor/test/BUCK | 114 -------------- wangle/bootstrap/BUCK | 108 -------------- wangle/bootstrap/test/BUCK | 47 ------ wangle/channel/BUCK | 125 ---------------- wangle/channel/broadcast/BUCK | 68 --------- wangle/channel/broadcast/test/BUCK | 45 ------ wangle/channel/test/BUCK | 75 ---------- wangle/client/persistence/BUCK | 82 ----------- wangle/client/persistence/test/BUCK | 64 -------- wangle/client/ssl/BUCK | 86 ----------- wangle/client/ssl/test/BUCK | 80 ---------- wangle/codec/BUCK | 80 ---------- wangle/codec/test/BUCK | 29 ---- wangle/example/accept_steering/BUCK | 16 -- wangle/example/broadcast/BUCK | 21 --- wangle/example/echo/BUCK | 30 ---- wangle/example/file/BUCK | 17 --- wangle/example/proxy/BUCK | 15 -- wangle/example/rpc/BUCK | 46 ------ wangle/example/ssl/BUCK | 38 ----- wangle/example/telnet/BUCK | 30 ---- wangle/service/BUCK | 58 -------- wangle/service/test/BUCK | 20 --- wangle/ssl/BUCK | 221 ---------------------------- wangle/ssl/test/BUCK | 124 ---------------- wangle/util/BUCK | 40 ----- wangle/util/test/BUCK | 38 ----- 27 files changed, 1717 deletions(-) delete mode 100644 wangle/acceptor/test/BUCK delete mode 100644 wangle/bootstrap/BUCK delete mode 100644 wangle/bootstrap/test/BUCK delete mode 100644 wangle/channel/BUCK delete mode 100644 wangle/channel/broadcast/BUCK delete mode 100644 wangle/channel/broadcast/test/BUCK delete mode 100644 wangle/channel/test/BUCK delete mode 100644 wangle/client/persistence/BUCK delete mode 100644 wangle/client/persistence/test/BUCK delete mode 100644 wangle/client/ssl/BUCK delete mode 100644 wangle/client/ssl/test/BUCK delete mode 100644 wangle/codec/BUCK delete mode 100644 wangle/codec/test/BUCK delete mode 100644 wangle/example/accept_steering/BUCK delete mode 100644 wangle/example/broadcast/BUCK delete mode 100644 wangle/example/echo/BUCK delete mode 100644 wangle/example/file/BUCK delete mode 100644 wangle/example/proxy/BUCK delete mode 100644 wangle/example/rpc/BUCK delete mode 100644 wangle/example/ssl/BUCK delete mode 100644 wangle/example/telnet/BUCK delete mode 100644 wangle/service/BUCK delete mode 100644 wangle/service/test/BUCK delete mode 100644 wangle/ssl/BUCK delete mode 100644 wangle/ssl/test/BUCK delete mode 100644 wangle/util/BUCK delete mode 100644 wangle/util/test/BUCK diff --git a/wangle/acceptor/test/BUCK b/wangle/acceptor/test/BUCK deleted file mode 100644 index e827838b4..000000000 --- a/wangle/acceptor/test/BUCK +++ /dev/null @@ -1,114 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load("@fbcode_macros//build_defs/lib:re_test_utils.bzl", "re_test_utils") - -oncall("fbcode_entropy_wardens_folly") - -cpp_unittest( - name = "ConnectionManagerTest", - srcs = ["ConnectionManagerTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly:network_address", - "//folly/portability:gflags", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/acceptor:managed", - ], -) - -cpp_unittest( - name = "EvbHandshakeHelperTest", - srcs = ["EvbHandshakeHelperTest.cpp"], - headers = ["AcceptorHelperMocks.h"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/futures:barrier", - "//folly/io/async:scoped_event_base_thread", - "//folly/io/async/test:mocks", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//folly/synchronization:baton", - "//wangle/acceptor:acceptor", - "//wangle/acceptor:evb_handshake_helper", - ], -) - -cpp_unittest( - name = "LoadShedConfigurationTest", - srcs = ["LoadShedConfigurationTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/portability:gtest", - "//wangle/acceptor:load_shed_configuration", - ], -) - -cpp_unittest( - name = "AcceptorTest", - srcs = ["AcceptorTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - supports_static_listing = False, - deps = [ - "//folly/io/async:async_base", - "//folly/io/async/test:async_ssl_socket_test_lib", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//folly/testing:test_util", - "//wangle/acceptor:accept_observer", - "//wangle/acceptor:acceptor", - ], - external_deps = [ - "glog", - ], -) - -cpp_unittest( - name = "PeekingAcceptorHandshakeHelperTest", - srcs = ["PeekingAcceptorHandshakeHelperTest.cpp"], - headers = ["AcceptorHelperMocks.h"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/io/async/test:mocks", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/acceptor:acceptor", - ], -) - -cpp_unittest( - name = "SecurityProtocolContextManagerTest", - srcs = ["SecurityProtocolContextManagerTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/acceptor:acceptor", - ], -) - -cpp_unittest( - name = "SocketPeekerTest", - srcs = ["SocketPeekerTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/io/async/test:mocks", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/acceptor:socket_peeker", - ], -) - -cpp_unittest( - name = "SharedSSLContextManagerTest", - srcs = ["SharedSSLContextManagerTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly:file_util", - "//folly/io/async:async_base", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//folly/testing:test_util", - "//wangle/acceptor:fizz_config_util", - "//wangle/acceptor:shared_ssl_context_manager", - ], -) diff --git a/wangle/bootstrap/BUCK b/wangle/bootstrap/BUCK deleted file mode 100644 index 0004f824e..000000000 --- a/wangle/bootstrap/BUCK +++ /dev/null @@ -1,108 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "bootstrap", - exported_deps = [ - ":accept_routing_handler", # @manual - ":base_client_bootstrap", # @manual - ":client_bootstrap", # @manual - ":routing_data_handler", # @manual - ":server_bootstrap", # @manual - ":server_socket_factory", # @manual - ], -) - -# Main Rules - -cpp_library( - name = "accept_routing_handler", - headers = [ - "AcceptRoutingHandler.h", - "AcceptRoutingHandler-inl.h", - ], - exported_deps = [ - ":routing_data_handler", - ":server_bootstrap", - "//wangle/channel:pipeline", - ], -) - -cpp_library( - name = "base_client_bootstrap", - headers = ["BaseClientBootstrap.h"], - exported_deps = [ - "//folly:network_address", - "//folly/futures:core", - "//folly/io:socket_option_map", - "//folly/io/async:async_socket", - "//folly/io/async:async_ssl_socket", - "//folly/ssl:ssl_session", - "//wangle/channel:pipeline", - ], -) - -cpp_library( - name = "client_bootstrap", - headers = ["ClientBootstrap.h"], - exported_deps = [ - ":base_client_bootstrap", - "//folly/executors:io_thread_pool_executor", - "//folly/io/async:async_socket", - "//folly/io/async:async_ssl_socket", - "//folly/io/async:destructor_check", - "//folly/io/async:event_base_manager", - "//wangle/channel:pipeline", - ], -) - -cpp_library( - name = "routing_data_handler", - headers = [ - "RoutingDataHandler.h", - "RoutingDataHandler-inl.h", - ], - exported_deps = [ - "//wangle/channel:async_socket_handler", - ], -) - -cpp_library( - name = "server_bootstrap", - srcs = ["ServerBootstrap.cpp"], - headers = [ - "ServerBootstrap.h", - "ServerBootstrap-inl.h", - ], - deps = [ - "//folly/executors/thread_factory:named_thread_factory", - ], - exported_deps = [ - ":server_socket_factory", - "//folly:exception_wrapper", - "//folly:shared_mutex", - "//folly/executors:io_thread_pool_executor", - "//folly/io/async:async_transport", - "//folly/io/async:delayed_destruction", - "//folly/io/async:event_base_manager", - "//folly/synchronization:baton", - "//wangle/acceptor:acceptor", - "//wangle/acceptor:managed", - "//wangle/acceptor:shared_ssl_context_manager", - "//wangle/channel:handler", - "//wangle/channel:pipeline", - "//wangle/ssl:ssl_stats", - ], -) - -cpp_library( - name = "server_socket_factory", - headers = ["ServerSocketFactory.h"], - exported_deps = [ - "//folly/io/async:async_udp_server_socket", - "//folly/io/async:event_base_manager", - "//folly/io/async:server_socket", - "//wangle/acceptor:acceptor", - ], -) diff --git a/wangle/bootstrap/test/BUCK b/wangle/bootstrap/test/BUCK deleted file mode 100644 index 0c4b1031c..000000000 --- a/wangle/bootstrap/test/BUCK +++ /dev/null @@ -1,47 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load("@fbcode_macros//build_defs/lib:re_test_utils.bzl", "re_test_utils") - -oncall("fbcode_entropy_wardens_folly") - -cpp_unittest( - name = "accept_routing_handler_test", - srcs = ["AcceptRoutingHandlerTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":mocks", - "//folly/synchronization:latch", - ], -) - -cpp_unittest( - name = "bootstrap_test", - srcs = ["BootstrapTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/portability:gtest", - "//folly/synchronization:latch", - "//folly/testing:test_util", - "//wangle/bootstrap:client_bootstrap", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:handler", - ], - external_deps = [ - "glog", - ], -) - -cpp_library( - name = "mocks", - headers = ["Mocks.h"], - exported_deps = [ - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/bootstrap:accept_routing_handler", - "//wangle/bootstrap:client_bootstrap", - "//wangle/bootstrap:routing_data_handler", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:pipeline", - "//wangle/channel/test:mocks", - ], -) diff --git a/wangle/channel/BUCK b/wangle/channel/BUCK deleted file mode 100644 index 44769dbde..000000000 --- a/wangle/channel/BUCK +++ /dev/null @@ -1,125 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "channel", - exported_deps = [ - ":async_socket_handler", # @manual - ":event_base_handler", # @manual - ":file_region", # @manual - ":handler", # @manual - ":handler_context", # @manual - ":output_buffering_handler", # @manual - ":pipeline", # @manual - ":static_pipeline", # @manual - ], -) - -# Main Rules - -cpp_library( - name = "async_socket_handler", - headers = ["AsyncSocketHandler.h"], - exported_deps = [ - ":handler", - "//folly/io:iobuf", - "//folly/io/async:async_base", - "//folly/io/async:async_socket", - "//folly/io/async:event_base_manager", - ], -) - -cpp_library( - name = "event_base_handler", - headers = ["EventBaseHandler.h"], - exported_deps = [ - ":handler", - "//folly/futures:core", - ], -) - -cpp_library( - name = "file_region", - srcs = ["FileRegion.cpp"], - headers = ["FileRegion.h"], - exported_deps = [ - "//folly:singleton", - "//folly/executors:io_thread_pool_executor", - "//folly/futures:core", - "//folly/io/async:async_base", - "//folly/io/async:async_socket", - "//folly/io/async:async_transport", - ], -) - -cpp_library( - name = "handler", - headers = ["Handler.h"], - exported_deps = [ - ":pipeline", - "//folly/futures:core", - "//folly/io:iobuf", - ], -) - -cpp_library( - name = "handler_context", - headers = [ - "HandlerContext.h", - "HandlerContext-inl.h", - ], - exported_deps = [ - "//folly:exception_wrapper", - "//folly:format", - "//folly/futures:core", - "//folly/io/async:async_transport", - ], -) - -cpp_library( - name = "output_buffering_handler", - headers = ["OutputBufferingHandler.h"], - exported_deps = [ - ":handler", - "//folly/futures:shared_promise", - "//folly/io:iobuf", - "//folly/io/async:async_base", - "//folly/io/async:event_base_manager", - ], -) - -cpp_library( - name = "pipeline", - srcs = ["Pipeline.cpp"], - headers = [ - "Pipeline.h", - "Pipeline-inl.h", - ], - exported_deps = [ - ":handler_context", - "//folly:exception_wrapper", - "//folly:memory", - "//folly:optional", - "//folly:unit", - "//folly/futures:core", - "//folly/io:iobuf", - "//folly/io/async:async_transport", - "//folly/io/async:async_udp_socket", - "//folly/io/async:delayed_destruction", - "//folly/io/async:request_context", - "//wangle/acceptor:secure_transport_type", - "//wangle/acceptor:transport_info", - ], - exported_external_deps = [ - "glog", - ], -) - -cpp_library( - name = "static_pipeline", - headers = ["StaticPipeline.h"], - exported_deps = [ - ":pipeline", - ], -) diff --git a/wangle/channel/broadcast/BUCK b/wangle/channel/broadcast/BUCK deleted file mode 100644 index e5ef659da..000000000 --- a/wangle/channel/broadcast/BUCK +++ /dev/null @@ -1,68 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "broadcast", - exported_deps = [ - ":broadcast_handler", # @manual - ":broadcast_pool", # @manual - ":observing_handler", # @manual - ":subscriber", # @manual - ], -) - -# Main Rules - -cpp_library( - name = "broadcast_handler", - headers = [ - "BroadcastHandler.h", - "BroadcastHandler-inl.h", - ], - exported_deps = [ - ":subscriber", - "//wangle/channel:async_socket_handler", - "//wangle/channel:handler", - "//wangle/channel:pipeline", - ], -) - -cpp_library( - name = "broadcast_pool", - headers = [ - "BroadcastPool.h", - "BroadcastPool-inl.h", - ], - exported_deps = [ - ":broadcast_handler", - "//folly:thread_local", - "//folly/futures:shared_promise", - "//folly/io/async:delayed_destruction", - "//wangle/bootstrap:base_client_bootstrap", - "//wangle/bootstrap:client_bootstrap", - "//wangle/channel:pipeline", - ], -) - -cpp_library( - name = "observing_handler", - headers = [ - "ObservingHandler.h", - "ObservingHandler-inl.h", - ], - exported_deps = [ - ":broadcast_pool", - ":subscriber", - "//wangle/bootstrap:accept_routing_handler", - "//wangle/bootstrap:server_bootstrap", - ], -) - -cpp_library( - name = "subscriber", - headers = ["Subscriber.h"], - exported_deps = [ - "//folly:exception_wrapper", - ], -) diff --git a/wangle/channel/broadcast/test/BUCK b/wangle/channel/broadcast/test/BUCK deleted file mode 100644 index a7fcb9f31..000000000 --- a/wangle/channel/broadcast/test/BUCK +++ /dev/null @@ -1,45 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load("@fbcode_macros//build_defs/lib:re_test_utils.bzl", "re_test_utils") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "mocks", - headers = ["Mocks.h"], - exported_deps = [ - "//folly:move_wrapper", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/channel/broadcast:broadcast_handler", - "//wangle/channel/broadcast:broadcast_pool", - "//wangle/channel/broadcast:observing_handler", - "//wangle/codec:byte_to_message_decoder", - "//wangle/codec:message_to_byte_encoder", - ], -) - -cpp_unittest( - name = "broadcast_test", - srcs = [ - "BroadcastHandlerTest.cpp", - "BroadcastPoolTest.cpp", - "ObservingClientPipelineTest.cpp", - "ObservingHandlerTest.cpp", - ], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":mocks", - "//folly/portability:gtest", - "//wangle/bootstrap:client_bootstrap", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:handler", - "//wangle/channel/broadcast:broadcast_pool", - "//wangle/channel/broadcast:observing_handler", - "//wangle/channel/test:mocks", - "//wangle/codec:message_to_byte_encoder", - ], - external_deps = [ - "glog", - ], -) diff --git a/wangle/channel/test/BUCK b/wangle/channel/test/BUCK deleted file mode 100644 index cd7c936bd..000000000 --- a/wangle/channel/test/BUCK +++ /dev/null @@ -1,75 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load("@fbcode_macros//build_defs/lib:re_test_utils.bzl", "re_test_utils") - -oncall("fbcode_entropy_wardens_folly") - -cpp_unittest( - name = "AsyncSocketHandlerTest", - srcs = ["AsyncSocketHandlerTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":mocks", - "//folly/portability:gtest", - "//wangle/channel:async_socket_handler", - "//wangle/channel:pipeline", - ], -) - -cpp_unittest( - name = "FileRegionTest", - srcs = ["FileRegionTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/io/async/test:async_socket_test_lib", - "//folly/portability:gtest", - "//wangle/channel:file_region", - ], -) - -cpp_library( - name = "mocks", - headers = [ - "MockHandler.h", - "MockPipeline.h", - ], - exported_deps = [ - "//folly:move_wrapper", - "//folly/portability:gmock", - "//wangle/channel:handler", - "//wangle/channel:pipeline", - ], -) - -cpp_unittest( - name = "OutputBufferingHandlerTest", - srcs = ["OutputBufferingHandlerTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":mocks", - "//folly/io/async:async_socket", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/channel:output_buffering_handler", - "//wangle/channel:static_pipeline", - ], -) - -cpp_unittest( - name = "PipelineTest", - srcs = ["PipelineTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":mocks", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/channel:async_socket_handler", - "//wangle/channel:handler", - "//wangle/channel:output_buffering_handler", - "//wangle/channel:pipeline", - "//wangle/channel:static_pipeline", - ], - external_deps = [ - ("boost", None, "boost_thread"), - ], -) diff --git a/wangle/client/persistence/BUCK b/wangle/client/persistence/BUCK deleted file mode 100644 index 870a68cb4..000000000 --- a/wangle/client/persistence/BUCK +++ /dev/null @@ -1,82 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "file", - srcs = [ - "FilePersistenceLayer.cpp", - ], - headers = [ - "FilePersistenceLayer.h", - "FilePersistentCache.h", - ], - exported_deps = [ - ":lru_persistent_cache", - "//folly:file_util", - "//folly:memory", - "//folly:scope_guard", - "//folly/json:dynamic", - "//folly/portability:unistd", - ], -) - -cpp_library( - name = "lru_in_memory_cache", - headers = [ - "LRUInMemoryCache.h", - "LRUInMemoryCache-inl.h", - ], - exported_deps = [ - ":persistent_cache_common", - "//folly:likely", - "//folly:optional", - "//folly/container:evicting_cache_map", - "//folly/json:dynamic", - "//folly/synchronization:lock", - ], - exported_external_deps = [ - "glog", - ], -) - -cpp_library( - name = "lru_persistent_cache", - headers = [ - "LRUPersistentCache.h", - "LRUPersistentCache-inl.h", - ], - exported_deps = [ - ":lru_in_memory_cache", - ":persistent_cache", - ":persistent_cache_common", - "//folly:executor", - "//folly:file_util", - "//folly:scope_guard", - "//folly/json:dynamic", - "//folly/portability:sys_time", - "//folly/synchronization:lock", - "//folly/synchronization:saturating_semaphore", - "//folly/system:thread_name", - ], -) - -cpp_library( - name = "persistent_cache", - headers = ["PersistentCache.h"], - exported_deps = [ - "//folly:optional", - ], -) - -cpp_library( - name = "persistent_cache_common", - srcs = [ - "PersistentCacheCommon.cpp", - ], - headers = ["PersistentCacheCommon.h"], - exported_deps = [ - "//folly:executor", - "//folly:optional", - ], -) diff --git a/wangle/client/persistence/test/BUCK b/wangle/client/persistence/test/BUCK deleted file mode 100644 index 0cb82a454..000000000 --- a/wangle/client/persistence/test/BUCK +++ /dev/null @@ -1,64 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load("@fbcode_macros//build_defs/lib:re_test_utils.bzl", "re_test_utils") - -oncall("fbcode_entropy_wardens_folly") - -cpp_unittest( - name = "FilePersistentCacheTest", - srcs = ["FilePersistentCacheTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":TestUtil", - "//folly/executors:manual_executor", - "//folly/futures:barrier", - "//wangle/client/persistence:file", - ], -) - -cpp_unittest( - name = "LRUPersistentCacheTest", - srcs = ["LRUPersistentCacheTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly:memory", - "//folly/executors:manual_executor", - "//folly/futures:core", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//folly/synchronization:baton", - "//wangle/client/persistence:lru_persistent_cache", - ], -) - -cpp_library( - name = "TestUtil", - srcs = ["TestUtil.cpp"], - headers = [ - "Mocks.h", - "TestUtil.h", - ], - deps = [ - "//folly/testing:test_util", - ], - exported_deps = [ - "//folly:memory", - "//folly:optional", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//folly/portability:unistd", - "//wangle/client/persistence:file", - "//wangle/client/persistence:persistent_cache", - ], -) - -cpp_unittest( - name = "PersistentCacheCommonTest", - srcs = ["PersistentCacheCommonTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/executors:manual_executor", - "//folly/portability:gtest", - "//wangle/client/persistence:persistent_cache_common", - ], -) diff --git a/wangle/client/ssl/BUCK b/wangle/client/ssl/BUCK deleted file mode 100644 index 14457a490..000000000 --- a/wangle/client/ssl/BUCK +++ /dev/null @@ -1,86 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "ssl_session_cache_data", - srcs = ["SSLSessionCacheData.cpp"], - headers = ["SSLSessionCacheData.h"], - exported_deps = [ - "//folly:fbstring", - "//folly/json:dynamic", - "//folly/ssl:openssl_ptr_types", - ], -) - -cpp_library( - name = "ssl_session_cache_utils", - srcs = ["SSLSessionCacheUtils.cpp"], - headers = ["SSLSessionCacheUtils.h"], - preprocessor_flags = [ - "-DWANGLE_HAVE_SSL_SESSION_DUP", - ], - deps = [ - "//folly/io:iobuf", - "//wangle/ssl:ssl_util", - ], - exported_deps = [ - ":ssl_session_cache_data", - "//folly:fbstring", - "//folly:optional", - ], - exported_external_deps = [ - ("openssl", None, "ssl"), - ], -) - -cpp_library( - name = "ssl_session_callbacks", - srcs = ["SSLSessionCallbacks.cpp"], - headers = ["SSLSessionCallbacks.h"], - exported_deps = [ - ":ssl_session_cache_utils", - "//folly/io/async:async_ssl_socket", - "//folly/io/async:ssl_context", - "//folly/ssl:openssl_ptr_types", - "//wangle/ssl:ssl_util", - ], - exported_external_deps = [ - ("openssl", None, "ssl"), - ], -) - -cpp_library( - name = "ssl_session_persistent_cache", - headers = [ - "SSLSessionPersistentCache.h", - "SSLSessionPersistentCache-inl.h", - ], - exported_deps = [ - ":ssl_session_cache_data", - ":ssl_session_cache_utils", - ":ssl_session_callbacks", - "//folly:executor", - "//folly:memory", - "//folly/io:iobuf", - "//folly/portability:openssl", - "//folly/ssl:openssl_ptr_types", - "//wangle/client/persistence:file", - "//wangle/client/persistence:persistent_cache", - "//wangle/client/persistence:persistent_cache_common", - ], - exported_external_deps = [ - ("openssl", None, "ssl"), - ], -) - -cpp_library( - name = "threadsafe_cache", - srcs = ["ThreadSafeSSLSessionCache.cpp"], - headers = ["ThreadSafeSSLSessionCache.h"], - exported_deps = [ - ":ssl_session_callbacks", - "//folly:shared_mutex", - "//folly/ssl:openssl_ptr_types", - ], -) diff --git a/wangle/client/ssl/test/BUCK b/wangle/client/ssl/test/BUCK deleted file mode 100644 index de4a8f5c5..000000000 --- a/wangle/client/ssl/test/BUCK +++ /dev/null @@ -1,80 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load("@fbcode_macros//build_defs/lib:re_test_utils.bzl", "re_test_utils") - -oncall("fbcode_entropy_wardens_folly") - -cpp_unittest( - name = "SSLSessionCacheDataTest", - srcs = ["SSLSessionCacheDataTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":TestUtil", - "//folly/json:dynamic", - "//folly/portability:gtest", - "//folly/ssl:openssl_ptr_types", - "//wangle/client/ssl:ssl_session_cache_data", - "//wangle/client/ssl:ssl_session_cache_utils", - "//wangle/ssl:ssl_util", - ], -) - -cpp_unittest( - name = "SSLSessionCallbackTest", - srcs = ["SSLSessionCallbackTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - test_main = "fbsource//third-party/googletest:gtest_main", - deps = [ - "//folly/io/async:ssl_context", - "//folly/portability:gtest", - "//wangle/client/ssl:ssl_session_callbacks", - ], -) - -cpp_unittest( - name = "SSLSessionPersistentCacheTest", - srcs = ["SSLSessionPersistentCacheTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - test_main = "fbsource//third-party/googletest:gtest_main", - deps = [ - ":TestUtil", - "//folly:format", - "//folly:memory", - "//folly/json:dynamic", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/client/persistence/test:TestUtil", - "//wangle/client/ssl:ssl_session_persistent_cache", - ], -) - -cpp_unittest( - name = "ThreadSafeSSLSessionCacheTest", - srcs = ["ThreadSafeSSLSessionCacheTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":TestUtil", - "//folly:conv", - "//folly:memory", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//wangle/client/ssl:threadsafe_cache", - ], -) - -cpp_library( - name = "TestUtil", - srcs = ["TestUtil.cpp"], - headers = [ - "Mocks.h", - "TestUtil.h", - ], - exported_deps = [ - "//folly/portability:gmock", - "//folly/ssl:openssl_ptr_types", - "//wangle/client/ssl:ssl_session_callbacks", - ], - exported_external_deps = [ - "glog", - ], -) diff --git a/wangle/codec/BUCK b/wangle/codec/BUCK deleted file mode 100644 index 61b925868..000000000 --- a/wangle/codec/BUCK +++ /dev/null @@ -1,80 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "codecs", - exported_deps = [ - ":byte_to_message_decoder", # @manual - ":fixed_length_frame_decoder", # @manual - ":length_field_based_frame_decoder", # @manual - ":length_field_prepender", # @manual - ":line_based_frame_decoder", # @manual - ":message_to_byte_encoder", # @manual - ":string_codec", # @manual - ], -) - -# Main Rules - -cpp_library( - name = "byte_to_message_decoder", - headers = ["ByteToMessageDecoder.h"], - exported_deps = [ - "//wangle/channel:handler", - ], -) - -cpp_library( - name = "fixed_length_frame_decoder", - headers = ["FixedLengthFrameDecoder.h"], - exported_deps = [ - ":byte_to_message_decoder", - ], -) - -cpp_library( - name = "length_field_based_frame_decoder", - srcs = ["LengthFieldBasedFrameDecoder.cpp"], - headers = ["LengthFieldBasedFrameDecoder.h"], - exported_deps = [ - ":byte_to_message_decoder", - "//folly/io:iobuf", - ], -) - -cpp_library( - name = "length_field_prepender", - srcs = ["LengthFieldPrepender.cpp"], - headers = ["LengthFieldPrepender.h"], - exported_deps = [ - "//folly/io:iobuf", - "//wangle/channel:handler", - ], -) - -cpp_library( - name = "line_based_frame_decoder", - srcs = ["LineBasedFrameDecoder.cpp"], - headers = ["LineBasedFrameDecoder.h"], - exported_deps = [ - ":byte_to_message_decoder", - "//folly/io:iobuf", - ], -) - -cpp_library( - name = "message_to_byte_encoder", - headers = ["MessageToByteEncoder.h"], - exported_deps = [ - "//wangle/channel:handler", - ], -) - -cpp_library( - name = "string_codec", - headers = ["StringCodec.h"], - exported_deps = [ - "//wangle/channel:handler", - ], -) diff --git a/wangle/codec/test/BUCK b/wangle/codec/test/BUCK deleted file mode 100644 index 146032309..000000000 --- a/wangle/codec/test/BUCK +++ /dev/null @@ -1,29 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load("@fbcode_macros//build_defs/lib:re_test_utils.bzl", "re_test_utils") - -oncall("fbcode_entropy_wardens_folly") - -cpp_unittest( - name = "CodecTest", - srcs = ["CodecTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":codec_test_utils", - "//folly/portability:gtest", - "//wangle/codec:fixed_length_frame_decoder", - "//wangle/codec:length_field_based_frame_decoder", - "//wangle/codec:length_field_prepender", - "//wangle/codec:line_based_frame_decoder", - ], -) - -cpp_library( - name = "codec_test_utils", - headers = ["CodecTestUtils.h"], - exported_deps = [ - "//folly:function", - "//folly/io:iobuf", - "//wangle/channel:handler", - ], -) diff --git a/wangle/example/accept_steering/BUCK b/wangle/example/accept_steering/BUCK deleted file mode 100644 index abdc62787..000000000 --- a/wangle/example/accept_steering/BUCK +++ /dev/null @@ -1,16 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_binary.bzl", "cpp_binary") - -oncall("fbcode_entropy_wardens_folly") - -cpp_binary( - name = "accept_server", - srcs = ["accept_steering_server.cpp"], - deps = [ - "//folly/init:init", - "//folly/portability:gflags", - "//wangle/bootstrap:accept_routing_handler", - "//wangle/bootstrap:routing_data_handler", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:async_socket_handler", - ], -) diff --git a/wangle/example/broadcast/BUCK b/wangle/example/broadcast/BUCK deleted file mode 100644 index 2212b6cae..000000000 --- a/wangle/example/broadcast/BUCK +++ /dev/null @@ -1,21 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_binary.bzl", "cpp_binary") - -oncall("fbcode_entropy_wardens_folly") - -cpp_binary( - name = "broadcast_proxy", - srcs = ["BroadcastProxy.cpp"], - deps = [ - "//folly/init:init", - "//folly/portability:gflags", - "//wangle/bootstrap:accept_routing_handler", - "//wangle/bootstrap:routing_data_handler", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/channel/broadcast:broadcast_handler", - "//wangle/channel/broadcast:broadcast_pool", - "//wangle/channel/broadcast:observing_handler", - "//wangle/codec:byte_to_message_decoder", - "//wangle/codec:message_to_byte_encoder", - ], -) diff --git a/wangle/example/echo/BUCK b/wangle/example/echo/BUCK deleted file mode 100644 index 88b18bffe..000000000 --- a/wangle/example/echo/BUCK +++ /dev/null @@ -1,30 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_binary.bzl", "cpp_binary") - -oncall("fbcode_entropy_wardens_folly") - -cpp_binary( - name = "echo_client", - srcs = ["EchoClient.cpp"], - deps = [ - "//folly/init:init", - "//folly/portability:gflags", - "//wangle/bootstrap:client_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/channel:event_base_handler", - "//wangle/codec:line_based_frame_decoder", - "//wangle/codec:string_codec", - ], -) - -cpp_binary( - name = "echo_server", - srcs = ["EchoServer.cpp"], - deps = [ - "//folly/init:init", - "//folly/portability:gflags", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/codec:line_based_frame_decoder", - "//wangle/codec:string_codec", - ], -) diff --git a/wangle/example/file/BUCK b/wangle/example/file/BUCK deleted file mode 100644 index 48c23dbb4..000000000 --- a/wangle/example/file/BUCK +++ /dev/null @@ -1,17 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_binary.bzl", "cpp_binary") - -oncall("fbcode_entropy_wardens_folly") - -cpp_binary( - name = "file_server", - srcs = ["FileServer.cpp"], - deps = [ - "//folly/init:init", - "//folly/portability:gflags", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/channel:file_region", - "//wangle/codec:line_based_frame_decoder", - "//wangle/codec:string_codec", - ], -) diff --git a/wangle/example/proxy/BUCK b/wangle/example/proxy/BUCK deleted file mode 100644 index 616a2fbba..000000000 --- a/wangle/example/proxy/BUCK +++ /dev/null @@ -1,15 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_binary.bzl", "cpp_binary") - -oncall("fbcode_entropy_wardens_folly") - -cpp_binary( - name = "proxy", - srcs = ["Proxy.cpp"], - deps = [ - "//folly/init:init", - "//folly/portability:gflags", - "//wangle/bootstrap:client_bootstrap", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:async_socket_handler", - ], -) diff --git a/wangle/example/rpc/BUCK b/wangle/example/rpc/BUCK deleted file mode 100644 index 4f33c0411..000000000 --- a/wangle/example/rpc/BUCK +++ /dev/null @@ -1,46 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_binary.bzl", "cpp_binary") - -oncall("fbcode_entropy_wardens_folly") - -cpp_binary( - name = "rpc_client", - srcs = ["RpcClient.cpp"], - headers = ["ClientSerializeHandler.h"], - deps = [ - "//folly/init:init", - "//folly/portability:gflags", - "//thrift/lib/cpp2/protocol:protocol", - "//thrift/test:thrift_test-cpp2-services", - "//wangle/bootstrap:client_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/channel:event_base_handler", - "//wangle/channel:handler", - "//wangle/codec:length_field_based_frame_decoder", - "//wangle/codec:length_field_prepender", - "//wangle/service:client_dispatcher", - "//wangle/service:expiring_filter", - "//wangle/service:service", - ], -) - -cpp_binary( - name = "rpc_server", - srcs = ["RpcServer.cpp"], - headers = ["ServerSerializeHandler.h"], - deps = [ - "//folly/executors:cpu_thread_pool_executor", - "//folly/init:init", - "//folly/portability:gflags", - "//thrift/lib/cpp2/protocol:protocol", - "//thrift/test:thrift_test-cpp2-services", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/channel:event_base_handler", - "//wangle/channel:handler", - "//wangle/codec:length_field_based_frame_decoder", - "//wangle/codec:length_field_prepender", - "//wangle/service:executor_filter", - "//wangle/service:server_dispatcher", - "//wangle/service:service", - ], -) diff --git a/wangle/example/ssl/BUCK b/wangle/example/ssl/BUCK deleted file mode 100644 index 0ef9f7cf1..000000000 --- a/wangle/example/ssl/BUCK +++ /dev/null @@ -1,38 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_binary.bzl", "cpp_binary") - -oncall("fbcode_entropy_wardens_folly") - -cpp_binary( - name = "server", - srcs = ["Server.cpp"], - deps = [ - "//folly/init:init", - "//folly/io/async:async_ssl_socket", - "//folly/portability:gflags", - "//wangle/acceptor:acceptor", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/codec:line_based_frame_decoder", - "//wangle/codec:string_codec", - "//wangle/ssl:tls_cred_processor", - ], -) - -cpp_binary( - name = "client", - srcs = ["Client.cpp"], - deps = [ - "//folly/init:init", - "//folly/io/async:async_ssl_socket", - "//folly/io/async:delayed_destruction", - "//folly/io/async:ssl_options", - "//folly/portability:gflags", - "//wangle/bootstrap:client_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/channel:event_base_handler", - "//wangle/client/persistence:lru_persistent_cache", - "//wangle/client/ssl:ssl_session_persistent_cache", - "//wangle/codec:line_based_frame_decoder", - "//wangle/codec:string_codec", - ], -) diff --git a/wangle/example/telnet/BUCK b/wangle/example/telnet/BUCK deleted file mode 100644 index 4043ad459..000000000 --- a/wangle/example/telnet/BUCK +++ /dev/null @@ -1,30 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_binary.bzl", "cpp_binary") - -oncall("fbcode_entropy_wardens_folly") - -cpp_binary( - name = "telnet_client", - srcs = ["TelnetClient.cpp"], - deps = [ - "//folly/init:init", - "//folly/portability:gflags", - "//wangle/bootstrap:client_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/channel:event_base_handler", - "//wangle/codec:line_based_frame_decoder", - "//wangle/codec:string_codec", - ], -) - -cpp_binary( - name = "telnet_server", - srcs = ["TelnetServer.cpp"], - deps = [ - "//folly/init:init", - "//folly/portability:gflags", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/codec:line_based_frame_decoder", - "//wangle/codec:string_codec", - ], -) diff --git a/wangle/service/BUCK b/wangle/service/BUCK deleted file mode 100644 index bce897114..000000000 --- a/wangle/service/BUCK +++ /dev/null @@ -1,58 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "client_dispatcher", - headers = ["ClientDispatcher.h"], - exported_deps = [ - ":service", - "//wangle/channel:handler", - ], -) - -cpp_library( - name = "close_on_release_filter", - headers = ["CloseOnReleaseFilter.h"], - exported_deps = [ - ":service", - ], -) - -cpp_library( - name = "executor_filter", - headers = ["ExecutorFilter.h"], - exported_deps = [ - ":service", - ], -) - -cpp_library( - name = "expiring_filter", - headers = ["ExpiringFilter.h"], - exported_deps = [ - ":service", - ], -) - -cpp_library( - name = "server_dispatcher", - headers = ["ServerDispatcher.h"], - exported_deps = [ - ":service", - "//wangle/channel:handler", - ], -) - -cpp_library( - name = "service", - headers = ["Service.h"], - exported_deps = [ - "//folly:memory", - "//folly/futures:core", - "//wangle/bootstrap:client_bootstrap", - "//wangle/bootstrap:server_bootstrap", - "//wangle/channel:async_socket_handler", - "//wangle/channel:pipeline", - ], -) diff --git a/wangle/service/test/BUCK b/wangle/service/test/BUCK deleted file mode 100644 index d874d76ad..000000000 --- a/wangle/service/test/BUCK +++ /dev/null @@ -1,20 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load("@fbcode_macros//build_defs/lib:re_test_utils.bzl", "re_test_utils") - -oncall("fbcode_entropy_wardens_folly") - -cpp_unittest( - name = "ServiceTest", - srcs = ["ServiceTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/portability:gtest", - "//wangle/codec:byte_to_message_decoder", - "//wangle/codec:string_codec", - "//wangle/service:client_dispatcher", - "//wangle/service:close_on_release_filter", - "//wangle/service:expiring_filter", - "//wangle/service:server_dispatcher", - "//wangle/service:service", - ], -) diff --git a/wangle/ssl/BUCK b/wangle/ssl/BUCK deleted file mode 100644 index c6ad6cf13..000000000 --- a/wangle/ssl/BUCK +++ /dev/null @@ -1,221 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "ssl", - exported_deps = [ - ":client_hello_ext_stats", # @manual - ":server_ssl_context", # @manual - ":ssl_cache_options", # @manual - ":ssl_cache_provider", # @manual - ":ssl_context_config", # @manual - ":ssl_context_manager", # @manual - ":ssl_session_cache_manager", # @manual - ":ssl_stats", # @manual - ":tls_ticket_key_manager", # @manual - ":tls_ticket_key_seeds", # @manual - ], -) - -# Main Rules - -cpp_library( - name = "client_hello_ext_stats", - headers = ["ClientHelloExtStats.h"], - exported_deps = [ - "//wangle/acceptor:util", - ], -) - -cpp_library( - name = "ssl_cache_options", - headers = ["SSLCacheOptions.h"], -) - -cpp_library( - name = "ssl_cache_provider", - headers = ["SSLCacheProvider.h"], - exported_deps = [ - "//folly/futures:core", - "//folly/io/async:async_ssl_socket", - ], -) - -cpp_library( - name = "ssl_context_config", - headers = ["SSLContextConfig.h"], - exported_deps = [ - "//folly:optional", - "//folly/io/async:ssl_context", - "//folly/io/async:ssl_options", - ], -) - -cpp_library( - name = "password_in_file_factory", - srcs = ["PasswordInFileFactory.cpp"], - headers = ["PasswordInFileFactory.h"], - exported_deps = [ - "//folly/io/async:password_in_file", - ], -) - -cpp_library( - name = "ssl_context_manager", - srcs = ["SSLContextManager.cpp"], - headers = ["SSLContextManager.h"], - deps = [ - ":client_hello_ext_stats", - ":server_ssl_context", - ":ssl_cache_options", - ":ssl_util", - ":tls_ticket_key_manager", - "//folly:conv", - "//folly:scope_guard", - "//folly:string", - "//folly/io/async:password_in_file", - "//folly/portability:openssl", - "//folly/ssl:openssl_cert_utils", - ], - exported_deps = [ - ":password_in_file_factory", - ":sni_config", - ":ssl_context_config", - ":ssl_session_cache_manager", - ":tls_ticket_key_seeds", - "//folly:shared_mutex", - "//folly/io/async:async_base", - "//folly/io/async:ssl_context", - "//wangle/acceptor:util", - ], - exported_external_deps = [ - "glog", - ], -) - -cpp_library( - name = "ssl_session_cache_manager", - srcs = ["SSLSessionCacheManager.cpp"], - headers = ["SSLSessionCacheManager.h"], - deps = [ - ":ssl_util", - "//folly/fibers:core_manager", - "//folly/portability:gflags", - "//folly/portability:openssl", - ], - exported_deps = [ - ":ssl_cache_provider", - ":ssl_stats", - "//folly/container:evicting_cache_map", - "//folly/hash:hash", - "//folly/io/async:async_ssl_socket", - ], -) - -cpp_library( - name = "ssl_stats", - headers = ["SSLStats.h"], -) - -cpp_library( - name = "ssl_util", - srcs = ["SSLUtil.cpp"], - headers = ["SSLUtil.h"], - deps = [ - "//folly:file_util", - "//folly:format", - "//folly:memory", - "//folly/io/async:async_ssl_socket", - "//folly/portability:openssl", - ], - exported_deps = [ - "//folly:string", - "//folly/ssl:openssl_ptr_types", - "//folly/ssl:password_collector", - ], -) - -cpp_library( - name = "server_ssl_context", - srcs = ["ServerSSLContext.cpp"], - headers = ["ServerSSLContext.h"], - deps = [ - ":ssl_cache_options", - ":ssl_context_config", - ":ssl_session_cache_manager", - ], - exported_deps = [ - "//folly/io/async:ssl_context", - ], -) - -cpp_library( - name = "tls_cred_processor", - srcs = ["TLSCredProcessor.cpp"], - headers = ["TLSCredProcessor.h"], - deps = [ - ":ssl_util", - "//folly:file_util", - "//folly:memory", - "//folly/json:dynamic", - ], - exported_deps = [ - ":tls_ticket_key_seeds", - "//folly:optional", - "//folly:synchronized", - "//folly/io/async:password_in_file", - "//wangle/util:file_poller", - ], -) - -cpp_library( - name = "tls_in_memory_ticket_processor", - srcs = ["TLSInMemoryTicketProcessor.cpp"], - headers = ["TLSInMemoryTicketProcessor.h"], - deps = [ - ":ssl_util", - "//folly:random", - ], - exported_deps = [ - ":tls_ticket_key_seeds", - "//folly:synchronized", - "//folly/executors:function_scheduler", - ], -) - -cpp_library( - name = "tls_ticket_key_manager", - srcs = ["TLSTicketKeyManager.cpp"], - headers = ["TLSTicketKeyManager.h"], - deps = [ - ":ssl_stats", - ":ssl_util", - ":tls_ticket_key_seeds", - "//folly:glog", - "//folly:random", - "//folly:string", - "//folly/portability:openssl", - ], - exported_deps = [ - "//folly/io/async:async_base", - "//folly/io/async:ssl_context", - "//folly/ssl:openssl_ticket_handler", - ], - external_deps = [ - ("openssl", None, "crypto"), - ], -) - -cpp_library( - name = "tls_ticket_key_seeds", - headers = ["TLSTicketKeySeeds.h"], -) - -cpp_library( - name = "sni_config", - headers = ["SNIConfig.h"], - exported_deps = [ - ":ssl_context_config", - ], -) diff --git a/wangle/ssl/test/BUCK b/wangle/ssl/test/BUCK deleted file mode 100644 index 4f18a08be..000000000 --- a/wangle/ssl/test/BUCK +++ /dev/null @@ -1,124 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_binary.bzl", "cpp_binary") -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load("@fbcode_macros//build_defs/lib:re_test_utils.bzl", "re_test_utils") - -oncall("fbcode_entropy_wardens_folly") - -cpp_unittest( - name = "ssl_context_manager_test", - srcs = ["SSLContextManagerTest.cpp"], - preprocessor_flags = [ - "-DWANGLE_USE_FOLLY_TESTUTIL=1", - ], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly/io/async:async_base", - "//folly/io/async:ssl_context", - "//folly/io/async/test:test_ssl_server", - "//folly/portability:gtest", - "//folly/testing:test_util", - "//wangle/acceptor:util", - "//wangle/ssl:server_ssl_context", - "//wangle/ssl:ssl_cache_options", - "//wangle/ssl:ssl_context_manager", - "//wangle/ssl:tls_ticket_key_manager", - ], - external_deps = [ - "glog", - ], -) - -cpp_unittest( - name = "ssl_ticket_key_manager_test", - srcs = ["TLSTicketKeyManagerTest.cpp"], - preprocessor_flags = [ - "-DWANGLE_USE_FOLLY_TESTUTIL=1", - ], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":mock_ssl_stats", - "//folly/io/async:async_base", - "//folly/io/async:async_ssl_socket", - "//folly/io/async:ssl_context", - "//folly/io/async/test:async_ssl_socket_test_lib", - "//folly/io/async/test:test_ssl_server", - "//folly/portability:gmock", - "//folly/portability:gtest", - "//folly/testing:test_util", - "//wangle/ssl:ssl_stats", - "//wangle/ssl:tls_ticket_key_manager", - ], -) - -cpp_unittest( - name = "ssl_session_cache_manager_test", - srcs = [ - "SSLSessionCacheManagerTest.cpp", - ], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - "//folly:random", - "//folly/portability:gtest", - "//wangle/ssl:ssl_session_cache_manager", - ], - external_deps = [ - "glog", - ], -) - -cpp_binary( - name = "sslcachetest", - srcs = ["SSLCacheTest.cpp"], - deps = [ - "//folly/io/async:async_base", - "//folly/io/async:async_socket", - "//folly/io/async:async_ssl_socket", - "//folly/portability:gflags", - "//folly/ssl:ssl_session", - ], -) - -cpp_library( - name = "ticket_util", - headers = ["TicketUtil.h"], - exported_deps = [ - "//folly:range", - "//folly/container:array", - ], -) - -cpp_library( - name = "mock_ssl_stats", - headers = ["MockSSLStats.h"], - exported_deps = [ - "//folly/portability:gmock", - "//wangle/ssl:ssl_stats", - ], -) - -cpp_unittest( - name = "tls_cred_processor_test", - srcs = ["TLSCredProcessorTest.cpp"], - remote_execution = re_test_utils.remote_execution_linux_default(), - deps = [ - ":ticket_util", - "//folly:file", - "//folly:file_util", - "//folly:range", - "//folly/portability:gtest", - "//folly/portability:stdlib", - "//folly/synchronization:baton", - "//wangle/ssl:tls_cred_processor", - ], -) - -cpp_unittest( - name = "tls_in_memory_ticket_processor_test", - srcs = ["TLSInMemoryTicketProcessorTest.cpp"], - deps = [ - "//folly/portability:gtest", - "//folly/synchronization:baton", - "//wangle/ssl:tls_in_memory_ticket_processor", - ], -) diff --git a/wangle/util/BUCK b/wangle/util/BUCK deleted file mode 100644 index f989447cd..000000000 --- a/wangle/util/BUCK +++ /dev/null @@ -1,40 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") - -oncall("fbcode_entropy_wardens_folly") - -cpp_library( - name = "file_poller", - srcs = ["FilePoller.cpp"], - headers = ["FilePoller.h"], - deps = [ - "//folly:conv", - "//folly:memory", - "//folly:singleton", - ], - exported_deps = [ - "//folly:shared_mutex", - "//folly:thread_local", - "//folly/executors:function_scheduler", - "//folly/io/async:async_base", - "//folly/io/async:scoped_event_base_thread", - ], -) - -cpp_library( - name = "multi_file_poller", - srcs = [ - "MultiFilePoller.cpp", - ], - headers = [ - "MultiFilePoller.h", - ], - deps = [ - "//folly:file_util", - "//folly:string", - ], - exported_deps = [ - ":file_poller", - "//folly:function", - "//folly:shared_mutex", - ], -) diff --git a/wangle/util/test/BUCK b/wangle/util/test/BUCK deleted file mode 100644 index 63585cc21..000000000 --- a/wangle/util/test/BUCK +++ /dev/null @@ -1,38 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") - -oncall("fbcode_entropy_wardens_folly") - -cpp_unittest( - name = "file_poller_test", - srcs = ["FilePollerTest.cpp"], - deps = [ - "//folly:file", - "//folly:file_util", - "//folly:singleton", - "//folly/portability:gtest", - "//folly/portability:sys_stat", - "//folly/synchronization:baton", - "//folly/testing:test_util", - "//wangle/util:file_poller", - ], - external_deps = [ - "glog", - ], -) - -cpp_unittest( - name = "multi_file_poller_test", - srcs = [ - "MultiFilePollerTest.cpp", - ], - deps = [ - "//folly:file_util", - "//folly:map_util", - "//folly:string", - "//folly/futures:core", - "//folly/portability:gtest", - "//folly/synchronization:saturating_semaphore", - "//folly/testing:test_util", - "//wangle/util:multi_file_poller", - ], -)