couchbase 4.4.2 → 4.4.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/BUILDING.md +182 -0
- package/CMakeLists.txt +13 -0
- package/CONTRIBUTING.md +1 -1
- package/README.md +4 -2
- package/deps/couchbase-cxx-cache/boringssl/e31ea00c1ea52052d2d78d44006cc88c80fa24a9/boringssl/src/BUILDING.md +206 -0
- package/deps/couchbase-cxx-client/CMakeLists.txt +18 -13
- package/deps/couchbase-cxx-client/README.md +2 -2
- package/deps/couchbase-cxx-client/cmake/APKBUILD.in +54 -0
- package/deps/couchbase-cxx-client/cmake/CompilerWarnings.cmake +0 -5
- package/deps/couchbase-cxx-client/cmake/Packaging.cmake +177 -10
- package/deps/couchbase-cxx-client/cmake/RPath.cmake +10 -0
- package/deps/couchbase-cxx-client/cmake/Testing.cmake +1 -1
- package/deps/couchbase-cxx-client/cmake/VersionInfo.cmake +28 -2
- package/deps/couchbase-cxx-client/cmake/build_version.hxx.in +1 -0
- package/deps/couchbase-cxx-client/cmake/couchbase-cxx-client.spec.in +45 -6
- package/deps/couchbase-cxx-client/cmake/couchbase_cxx_client.pc.in +2 -2
- package/deps/couchbase-cxx-client/cmake/debian/changelog.in +5 -0
- package/deps/couchbase-cxx-client/cmake/debian/compat +1 -0
- package/deps/couchbase-cxx-client/cmake/debian/control +40 -0
- package/deps/couchbase-cxx-client/cmake/debian/rules +41 -0
- package/deps/couchbase-cxx-client/cmake/debian/source/format +1 -0
- package/deps/couchbase-cxx-client/core/agent_group.cxx +8 -0
- package/deps/couchbase-cxx-client/core/agent_group.hxx +4 -0
- package/deps/couchbase-cxx-client/core/bucket.cxx +16 -20
- package/deps/couchbase-cxx-client/core/bucket.hxx +12 -12
- package/deps/couchbase-cxx-client/core/cluster.cxx +44 -52
- package/deps/couchbase-cxx-client/core/cluster_agent.cxx +8 -0
- package/deps/couchbase-cxx-client/core/cluster_agent.hxx +4 -0
- package/deps/couchbase-cxx-client/core/collections_component.cxx +2 -2
- package/deps/couchbase-cxx-client/core/columnar/agent.cxx +2 -2
- package/deps/couchbase-cxx-client/core/columnar/agent.hxx +1 -1
- package/deps/couchbase-cxx-client/core/columnar/management_component.cxx +3 -3
- package/deps/couchbase-cxx-client/core/columnar/query_component.cxx +103 -45
- package/deps/couchbase-cxx-client/core/columnar/query_component.hxx +1 -0
- package/deps/couchbase-cxx-client/core/free_form_http_request.hxx +8 -0
- package/deps/couchbase-cxx-client/core/http_component.cxx +55 -24
- package/deps/couchbase-cxx-client/core/http_component.hxx +4 -0
- package/deps/couchbase-cxx-client/core/impl/analytics.cxx +1 -0
- package/deps/couchbase-cxx-client/core/impl/analytics_index_manager.cxx +15 -15
- package/deps/couchbase-cxx-client/core/impl/bootstrap_error.hxx +10 -2
- package/deps/couchbase-cxx-client/core/impl/bucket.cxx +1 -1
- package/deps/couchbase-cxx-client/core/impl/bucket_manager.cxx +6 -6
- package/deps/couchbase-cxx-client/core/impl/cluster.cxx +36 -40
- package/deps/couchbase-cxx-client/core/impl/collection.cxx +29 -5
- package/deps/couchbase-cxx-client/core/impl/collection_manager.cxx +5 -5
- package/deps/couchbase-cxx-client/core/impl/error.cxx +24 -3
- package/deps/couchbase-cxx-client/core/impl/get_replica.hxx +2 -0
- package/deps/couchbase-cxx-client/core/impl/lookup_in_replica.hxx +2 -0
- package/deps/couchbase-cxx-client/core/impl/observe_poll.cxx +13 -5
- package/deps/couchbase-cxx-client/core/impl/observe_poll.hxx +1 -3
- package/deps/couchbase-cxx-client/core/impl/observe_seqno.hxx +2 -0
- package/deps/couchbase-cxx-client/core/impl/query.cxx +1 -0
- package/deps/couchbase-cxx-client/core/impl/query_index_manager.cxx +6 -6
- package/deps/couchbase-cxx-client/core/impl/scan_result.cxx +1 -1
- package/deps/couchbase-cxx-client/core/impl/search.cxx +2 -0
- package/deps/couchbase-cxx-client/core/impl/search_index_manager.cxx +12 -12
- package/deps/couchbase-cxx-client/core/io/http_command.hxx +31 -20
- package/deps/couchbase-cxx-client/core/io/http_session.cxx +5 -0
- package/deps/couchbase-cxx-client/core/io/http_session.hxx +17 -4
- package/deps/couchbase-cxx-client/core/io/http_session_manager.hxx +97 -49
- package/deps/couchbase-cxx-client/core/io/mcbp_command.hxx +15 -14
- package/deps/couchbase-cxx-client/core/io/mcbp_session.cxx +48 -33
- package/deps/couchbase-cxx-client/core/io/streams.cxx +256 -0
- package/deps/couchbase-cxx-client/core/io/streams.hxx +31 -155
- package/deps/couchbase-cxx-client/core/logger/configuration.hxx +5 -0
- package/deps/couchbase-cxx-client/core/logger/custom_rotating_file_sink.cxx +2 -3
- package/deps/couchbase-cxx-client/core/logger/logger.cxx +39 -7
- package/deps/couchbase-cxx-client/core/logger/logger.hxx +7 -0
- package/deps/couchbase-cxx-client/core/meta/features.hxx +11 -0
- package/deps/couchbase-cxx-client/core/meta/version.cxx +47 -6
- package/deps/couchbase-cxx-client/core/metrics/meter_wrapper.cxx +188 -0
- package/deps/couchbase-cxx-client/core/metrics/meter_wrapper.hxx +73 -0
- package/deps/couchbase-cxx-client/core/operations/document_analytics.cxx +23 -17
- package/deps/couchbase-cxx-client/core/operations/document_analytics.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/document_append.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_decrement.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_exists.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_all_replicas.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_and_lock.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_and_touch.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_any_replica.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_get_projected.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_increment.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_insert.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_lookup_in.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_lookup_in_all_replicas.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_lookup_in_any_replica.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_mutate_in.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_prepend.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_query.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/document_remove.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_replace.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_search.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/document_touch.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_unlock.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_upsert.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/document_view.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/http_noop.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataset_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataset_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataset_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataverse_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_dataverse_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_get_pending_mutations.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_index_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_index_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_index_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_connect.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_disconnect.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_get_all.cxx +23 -15
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_get_all.hxx +4 -3
- package/deps/couchbase-cxx-client/core/operations/management/analytics_link_replace.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_describe.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_describe.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_drop.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_flush.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_flush.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_get.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/bucket_update.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/bucket_update.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/change_password.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/cluster_describe.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/cluster_developer_preview_enable.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/collection_create.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/collection_create.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/collection_drop.cxx +5 -2
- package/deps/couchbase-cxx-client/core/operations/management/collection_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/collection_update.cxx +4 -2
- package/deps/couchbase-cxx-client/core/operations/management/collection_update.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/collections_manifest_get.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/eventing_deploy_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_drop_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_get_all_functions.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_get_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_get_status.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_pause_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_resume_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_undeploy_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/eventing_upsert_function.hxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/freeform.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/group_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/group_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/group_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/group_upsert.cxx +3 -3
- package/deps/couchbase-cxx-client/core/operations/management/group_upsert.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_build.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_build_deferred.hxx +3 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_get_all.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/query_index_get_all_deferred.hxx +3 -0
- package/deps/couchbase-cxx-client/core/operations/management/role_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/scope_create.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/scope_create.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/scope_drop.cxx +4 -1
- package/deps/couchbase-cxx-client/core/operations/management/scope_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/scope_get_all.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/scope_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_get_stats.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_analyze_document.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_analyze_document.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_ingest.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_ingest.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_plan_freeze.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_plan_freeze.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_query.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_control_query.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_drop.cxx +5 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get.cxx +5 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_all.cxx +4 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_documents_count.cxx +3 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_documents_count.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_get_stats.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/search_index_upsert.cxx +5 -2
- package/deps/couchbase-cxx-client/core/operations/management/search_index_upsert.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/user_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/user_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/user_get_all.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/user_upsert.cxx +3 -3
- package/deps/couchbase-cxx-client/core/operations/management/user_upsert.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/view_index_drop.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/view_index_drop.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/view_index_get.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/view_index_get.hxx +1 -0
- package/deps/couchbase-cxx-client/core/operations/management/view_index_get_all.cxx +3 -1
- package/deps/couchbase-cxx-client/core/operations/management/view_index_get_all.hxx +2 -0
- package/deps/couchbase-cxx-client/core/operations/management/view_index_upsert.cxx +2 -1
- package/deps/couchbase-cxx-client/core/operations/management/view_index_upsert.hxx +1 -0
- package/deps/couchbase-cxx-client/core/origin.cxx +37 -17
- package/deps/couchbase-cxx-client/core/platform/base64.cc +1 -1
- package/deps/couchbase-cxx-client/core/platform/random.cc +2 -0
- package/deps/couchbase-cxx-client/core/platform/uuid.h +6 -6
- package/deps/couchbase-cxx-client/core/row_streamer.cxx +1 -1
- package/deps/couchbase-cxx-client/core/sasl/scram-sha/stringutils.cc +1 -1
- package/deps/couchbase-cxx-client/core/sasl/scram-sha/stringutils.h +4 -4
- package/deps/couchbase-cxx-client/core/topology/configuration.hxx +2 -0
- package/deps/couchbase-cxx-client/core/topology/configuration_json.hxx +8 -0
- package/deps/couchbase-cxx-client/core/tracing/constants.hxx +3 -0
- package/deps/couchbase-cxx-client/core/tracing/tracer_wrapper.cxx +87 -0
- package/deps/couchbase-cxx-client/core/tracing/tracer_wrapper.hxx +57 -0
- package/deps/couchbase-cxx-client/core/transactions/async_attempt_context.hxx +9 -21
- package/deps/couchbase-cxx-client/core/transactions/attempt_context.hxx +6 -33
- package/deps/couchbase-cxx-client/core/transactions/attempt_context_impl.cxx +57 -56
- package/deps/couchbase-cxx-client/core/transactions/attempt_context_impl.hxx +17 -18
- package/deps/couchbase-cxx-client/core/transactions/staged_mutation.cxx +2 -2
- package/deps/couchbase-cxx-client/core/transactions/transaction_context.cxx +2 -2
- package/deps/couchbase-cxx-client/core/transactions/transaction_get_result.hxx +0 -20
- package/deps/couchbase-cxx-client/core/transactions/transactions.cxx +2 -2
- package/deps/couchbase-cxx-client/core/utils/connection_string.cxx +128 -52
- package/deps/couchbase-cxx-client/couchbase/analytics_options.hxx +4 -3
- package/deps/couchbase-cxx-client/couchbase/codec/tao_json_serializer.hxx +1 -1
- package/deps/couchbase-cxx-client/couchbase/common_options.hxx +16 -1
- package/deps/couchbase-cxx-client/couchbase/metrics/otel_meter.hxx +16 -20
- package/deps/couchbase-cxx-client/couchbase/mutate_in_specs.hxx +2 -2
- package/deps/couchbase-cxx-client/couchbase/query_options.hxx +4 -3
- package/deps/couchbase-cxx-client/couchbase/search_options.hxx +1 -1
- package/dist/analyticsindexmanager.d.ts +98 -14
- package/dist/analyticsindexmanager.js +452 -411
- package/dist/binding.d.ts +53 -4
- package/dist/bindingutilities.d.ts +26 -1
- package/dist/bindingutilities.js +108 -1
- package/dist/couchbase.d.ts +3 -1
- package/dist/couchbase.js +2 -0
- package/dist/rangeScan.d.ts +1 -1
- package/dist/rangeScan.js +1 -1
- package/dist/transactions.d.ts +34 -3
- package/dist/transactions.js +25 -18
- package/dist/transcoders.d.ts +68 -0
- package/dist/transcoders.js +194 -1
- package/dist/usermanager.d.ts +14 -14
- package/dist/usermanager.js +178 -228
- package/dist/utilities.js +4 -6
- package/dist/utilities_internal.js +1 -2
- package/package.json +9 -8
- package/src/binding.cpp +13 -13
- package/src/connection.cpp +22 -0
- package/src/connection.hpp +12 -0
- package/src/connection_autogen.cpp +100 -0
- package/src/jstocbpp_autogen.hpp +315 -8
- package/src/jstocbpp_transactions.hpp +1 -2
- package/tools/gen-bindings-js.js +38 -3
- package/tools/gen-bindings-json.py +575 -328
|
@@ -38,13 +38,14 @@ struct eventing_upsert_function_request {
|
|
|
38
38
|
using encoded_response_type = io::http_response;
|
|
39
39
|
using error_context_type = error_context::http;
|
|
40
40
|
|
|
41
|
+
static const inline service_type type = service_type::eventing;
|
|
42
|
+
static const inline std::string observability_identifier = "manager_eventing_upsert_function";
|
|
43
|
+
|
|
41
44
|
couchbase::core::management::eventing::function function{};
|
|
42
45
|
|
|
43
46
|
std::optional<std::string> bucket_name{};
|
|
44
47
|
std::optional<std::string> scope_name{};
|
|
45
48
|
|
|
46
|
-
static const inline service_type type = service_type::eventing;
|
|
47
|
-
|
|
48
49
|
std::optional<std::string> client_context_id{};
|
|
49
50
|
std::optional<std::chrono::milliseconds> timeout{};
|
|
50
51
|
|
|
@@ -39,6 +39,8 @@ struct freeform_request {
|
|
|
39
39
|
using encoded_response_type = io::http_response;
|
|
40
40
|
using error_context_type = error_context::http;
|
|
41
41
|
|
|
42
|
+
static const inline std::string observability_identifier = "freeform_http";
|
|
43
|
+
|
|
42
44
|
service_type type{};
|
|
43
45
|
std::string method;
|
|
44
46
|
std::string path;
|
|
@@ -35,6 +35,7 @@ struct group_drop_request {
|
|
|
35
35
|
using encoded_response_type = io::http_response;
|
|
36
36
|
using error_context_type = error_context::http;
|
|
37
37
|
|
|
38
|
+
static const inline std::string observability_identifier = "manager_users_drop_group";
|
|
38
39
|
static const inline service_type type = service_type::management;
|
|
39
40
|
|
|
40
41
|
std::string name{};
|
|
@@ -37,6 +37,7 @@ struct group_get_request {
|
|
|
37
37
|
using encoded_response_type = io::http_response;
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
|
+
static const inline std::string observability_identifier = "manager_users_get_group";
|
|
40
41
|
static const inline service_type type = service_type::management;
|
|
41
42
|
|
|
42
43
|
std::string name{};
|
|
@@ -37,6 +37,7 @@ struct group_get_all_request {
|
|
|
37
37
|
using encoded_response_type = io::http_response;
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
|
+
static const inline std::string observability_identifier = "manager_users_get_all_groups";
|
|
40
41
|
static const inline service_type type = service_type::management;
|
|
41
42
|
|
|
42
43
|
std::optional<std::string> client_context_id{};
|
|
@@ -46,11 +46,11 @@ group_upsert_request::encode_to(encoded_request_type& encoded,
|
|
|
46
46
|
for (const auto& role : group.roles) {
|
|
47
47
|
std::string spec = role.name;
|
|
48
48
|
if (role.bucket) {
|
|
49
|
-
spec += fmt::format("[{}", role.bucket.value());
|
|
49
|
+
spec += fmt::format("[{}", utils::string_codec::v2::path_escape(role.bucket.value()));
|
|
50
50
|
if (role.scope) {
|
|
51
|
-
spec += fmt::format(":{}", role.scope.value());
|
|
51
|
+
spec += fmt::format(":{}", utils::string_codec::v2::path_escape(role.scope.value()));
|
|
52
52
|
if (role.collection) {
|
|
53
|
-
spec += fmt::format(":{}", role.collection.value());
|
|
53
|
+
spec += fmt::format(":{}", utils::string_codec::v2::path_escape(role.collection.value()));
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
56
|
spec += "]";
|
|
@@ -37,6 +37,7 @@ struct group_upsert_request {
|
|
|
37
37
|
using encoded_response_type = io::http_response;
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
|
+
static const inline std::string observability_identifier = "manager_users_upsert_group";
|
|
40
41
|
static const inline service_type type = service_type::management;
|
|
41
42
|
|
|
42
43
|
couchbase::core::management::rbac::group group{};
|
|
@@ -43,6 +43,8 @@ struct query_index_build_request {
|
|
|
43
43
|
using error_context_type = error_context::http;
|
|
44
44
|
|
|
45
45
|
static const inline service_type type = service_type::query;
|
|
46
|
+
static const inline std::string observability_identifier = "manager_query_build_indexes";
|
|
47
|
+
|
|
46
48
|
static constexpr auto namespace_id = "default";
|
|
47
49
|
|
|
48
50
|
std::string bucket_name;
|
|
@@ -44,6 +44,9 @@ struct query_index_build_deferred_request {
|
|
|
44
44
|
using encoded_response_type = io::http_response;
|
|
45
45
|
using error_context_type = error_context::http;
|
|
46
46
|
|
|
47
|
+
static const inline service_type type = service_type::query;
|
|
48
|
+
static const inline std::string observability_identifier = "manager_query_build_deferred_indexes";
|
|
49
|
+
|
|
47
50
|
static constexpr auto namespace_id = "default";
|
|
48
51
|
|
|
49
52
|
std::string bucket_name;
|
|
@@ -43,6 +43,7 @@ struct query_index_create_request {
|
|
|
43
43
|
using error_context_type = error_context::http;
|
|
44
44
|
|
|
45
45
|
static const inline service_type type = service_type::query;
|
|
46
|
+
static const inline std::string observability_identifier = "manager_query_create_index";
|
|
46
47
|
|
|
47
48
|
static constexpr auto namespace_id = "default";
|
|
48
49
|
std::string bucket_name;
|
|
@@ -43,6 +43,7 @@ struct query_index_drop_request {
|
|
|
43
43
|
using error_context_type = error_context::http;
|
|
44
44
|
|
|
45
45
|
static const inline service_type type = service_type::query;
|
|
46
|
+
static const inline std::string observability_identifier = "manager_query_drop_index";
|
|
46
47
|
|
|
47
48
|
static constexpr auto namespace_id = "default";
|
|
48
49
|
std::string bucket_name;
|
|
@@ -40,6 +40,8 @@ struct query_index_get_all_request {
|
|
|
40
40
|
using error_context_type = error_context::http;
|
|
41
41
|
|
|
42
42
|
static const inline service_type type = service_type::query;
|
|
43
|
+
static const inline std::string observability_identifier = "manager_query_get_all_indexes";
|
|
44
|
+
|
|
43
45
|
static constexpr auto namespace_id = "default";
|
|
44
46
|
|
|
45
47
|
std::string bucket_name;
|
package/deps/couchbase-cxx-client/core/operations/management/query_index_get_all_deferred.hxx
CHANGED
|
@@ -40,6 +40,9 @@ struct query_index_get_all_deferred_request {
|
|
|
40
40
|
using error_context_type = error_context::http;
|
|
41
41
|
|
|
42
42
|
static const inline service_type type = service_type::query;
|
|
43
|
+
static const inline std::string observability_identifier =
|
|
44
|
+
"manager_query_get_all_deferred_indexes";
|
|
45
|
+
|
|
43
46
|
static constexpr auto namespace_id = "default";
|
|
44
47
|
|
|
45
48
|
std::string bucket_name;
|
|
@@ -37,6 +37,7 @@ struct role_get_all_request {
|
|
|
37
37
|
using encoded_response_type = io::http_response;
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
|
+
static const inline std::string observability_identifier = "manager_users_get_roles";
|
|
40
41
|
static const inline service_type type = service_type::management;
|
|
41
42
|
|
|
42
43
|
std::optional<std::string> client_context_id{};
|
|
@@ -33,7 +33,8 @@ scope_create_request::encode_to(encoded_request_type& encoded,
|
|
|
33
33
|
http_context& /* context */) const -> std::error_code
|
|
34
34
|
{
|
|
35
35
|
encoded.method = "POST";
|
|
36
|
-
encoded.path = fmt::format("/pools/default/buckets/{}/scopes",
|
|
36
|
+
encoded.path = fmt::format("/pools/default/buckets/{}/scopes",
|
|
37
|
+
utils::string_codec::v2::path_escape(bucket_name));
|
|
37
38
|
encoded.headers["content-type"] = "application/x-www-form-urlencoded";
|
|
38
39
|
encoded.body = fmt::format("name={}", utils::string_codec::form_encode(scope_name));
|
|
39
40
|
return {};
|
|
@@ -37,6 +37,7 @@ struct scope_create_request {
|
|
|
37
37
|
using error_context_type = error_context::http;
|
|
38
38
|
|
|
39
39
|
static const inline service_type type = service_type::management;
|
|
40
|
+
static const inline std::string observability_identifier = "manager_collections_create_scope";
|
|
40
41
|
|
|
41
42
|
std::string bucket_name;
|
|
42
43
|
std::string scope_name;
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
#include "scope_drop.hxx"
|
|
19
19
|
|
|
20
20
|
#include "core/utils/json.hxx"
|
|
21
|
+
#include "core/utils/url_codec.hxx"
|
|
21
22
|
#include "error_utils.hxx"
|
|
22
23
|
|
|
23
24
|
#include <fmt/core.h>
|
|
@@ -32,7 +33,9 @@ scope_drop_request::encode_to(encoded_request_type& encoded,
|
|
|
32
33
|
http_context& /* context */) const -> std::error_code
|
|
33
34
|
{
|
|
34
35
|
encoded.method = "DELETE";
|
|
35
|
-
encoded.path = fmt::format("/pools/default/buckets/{}/scopes/{}",
|
|
36
|
+
encoded.path = fmt::format("/pools/default/buckets/{}/scopes/{}",
|
|
37
|
+
utils::string_codec::v2::path_escape(bucket_name),
|
|
38
|
+
utils::string_codec::v2::path_escape(scope_name));
|
|
36
39
|
return {};
|
|
37
40
|
}
|
|
38
41
|
|
|
@@ -37,6 +37,7 @@ struct scope_drop_request {
|
|
|
37
37
|
using error_context_type = error_context::http;
|
|
38
38
|
|
|
39
39
|
static const inline service_type type = service_type::management;
|
|
40
|
+
static const inline std::string observability_identifier = "manager_collections_drop_scope";
|
|
40
41
|
|
|
41
42
|
std::string bucket_name;
|
|
42
43
|
std::string scope_name;
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
|
|
20
20
|
#include "core/topology/collections_manifest_json.hxx"
|
|
21
21
|
#include "core/utils/json.hxx"
|
|
22
|
+
#include "core/utils/url_codec.hxx"
|
|
22
23
|
#include "error_utils.hxx"
|
|
23
24
|
|
|
24
25
|
#include <fmt/core.h>
|
|
@@ -31,7 +32,8 @@ scope_get_all_request::encode_to(encoded_request_type& encoded,
|
|
|
31
32
|
http_context& /* context */) const -> std::error_code
|
|
32
33
|
{
|
|
33
34
|
encoded.method = "GET";
|
|
34
|
-
encoded.path = fmt::format("/pools/default/buckets/{}/scopes",
|
|
35
|
+
encoded.path = fmt::format("/pools/default/buckets/{}/scopes",
|
|
36
|
+
utils::string_codec::v2::path_escape(bucket_name));
|
|
35
37
|
return {};
|
|
36
38
|
}
|
|
37
39
|
|
|
@@ -38,6 +38,7 @@ struct scope_get_all_request {
|
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
40
|
static const inline service_type type = service_type::management;
|
|
41
|
+
static const inline std::string observability_identifier = "manager_collections_get_all_scopes";
|
|
41
42
|
|
|
42
43
|
std::string bucket_name;
|
|
43
44
|
|
|
@@ -37,6 +37,7 @@ struct search_get_stats_request {
|
|
|
37
37
|
using error_context_type = error_context::http;
|
|
38
38
|
|
|
39
39
|
static const inline service_type type = service_type::search;
|
|
40
|
+
static const inline std::string observability_identifier = "manager_search_get_stats";
|
|
40
41
|
|
|
41
42
|
std::optional<std::string> client_context_id{};
|
|
42
43
|
std::optional<std::chrono::milliseconds> timeout{};
|
package/deps/couchbase-cxx-client/core/operations/management/search_index_analyze_document.cxx
CHANGED
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
#include "search_index_analyze_document.hxx"
|
|
19
19
|
|
|
20
20
|
#include "core/utils/json.hxx"
|
|
21
|
+
#include "core/utils/url_codec.hxx"
|
|
21
22
|
#include "error_utils.hxx"
|
|
22
23
|
|
|
23
24
|
#include <fmt/core.h>
|
|
@@ -38,8 +39,8 @@ search_index_analyze_document_request::encode_to(encoded_request_type& encoded,
|
|
|
38
39
|
encoded.headers["content-type"] = "application/json";
|
|
39
40
|
if (bucket_name.has_value() && scope_name.has_value()) {
|
|
40
41
|
encoded.path = fmt::format("/api/bucket/{}/scope/{}/index/{}/analyzeDoc",
|
|
41
|
-
bucket_name.value(),
|
|
42
|
-
scope_name.value(),
|
|
42
|
+
utils::string_codec::v2::path_escape(bucket_name.value()),
|
|
43
|
+
utils::string_codec::v2::path_escape(scope_name.value()),
|
|
43
44
|
index_name);
|
|
44
45
|
} else {
|
|
45
46
|
encoded.path = fmt::format("/api/index/{}/analyzeDoc", index_name);
|
package/deps/couchbase-cxx-client/core/operations/management/search_index_analyze_document.hxx
CHANGED
|
@@ -39,6 +39,7 @@ struct search_index_analyze_document_request {
|
|
|
39
39
|
using error_context_type = error_context::http;
|
|
40
40
|
|
|
41
41
|
static const inline service_type type = service_type::search;
|
|
42
|
+
static const inline std::string observability_identifier = "manager_search_analyze_document";
|
|
42
43
|
|
|
43
44
|
std::string index_name;
|
|
44
45
|
std::string encoded_document;
|
package/deps/couchbase-cxx-client/core/operations/management/search_index_control_ingest.cxx
CHANGED
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
#include "search_index_control_ingest.hxx"
|
|
19
19
|
|
|
20
20
|
#include "core/utils/json.hxx"
|
|
21
|
+
#include "core/utils/url_codec.hxx"
|
|
21
22
|
#include "error_utils.hxx"
|
|
22
23
|
|
|
23
24
|
#include <fmt/core.h>
|
|
@@ -35,8 +36,8 @@ search_index_control_ingest_request::encode_to(encoded_request_type& encoded,
|
|
|
35
36
|
encoded.method = "POST";
|
|
36
37
|
if (bucket_name.has_value() && scope_name.has_value()) {
|
|
37
38
|
encoded.path = fmt::format("/api/bucket/{}/scope/{}/index/{}/ingestControl/{}",
|
|
38
|
-
bucket_name.value(),
|
|
39
|
-
scope_name.value(),
|
|
39
|
+
utils::string_codec::v2::path_escape(bucket_name.value()),
|
|
40
|
+
utils::string_codec::v2::path_escape(scope_name.value()),
|
|
40
41
|
index_name,
|
|
41
42
|
pause ? "pause" : "resume");
|
|
42
43
|
} else {
|
package/deps/couchbase-cxx-client/core/operations/management/search_index_control_ingest.hxx
CHANGED
|
@@ -38,6 +38,7 @@ struct search_index_control_ingest_request {
|
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
40
|
static const inline service_type type = service_type::search;
|
|
41
|
+
static const inline std::string observability_identifier = "manager_search_control_ingest";
|
|
41
42
|
|
|
42
43
|
std::string index_name;
|
|
43
44
|
bool pause;
|
package/deps/couchbase-cxx-client/core/operations/management/search_index_control_plan_freeze.cxx
CHANGED
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
#include "search_index_control_plan_freeze.hxx"
|
|
19
19
|
|
|
20
20
|
#include "core/utils/json.hxx"
|
|
21
|
+
#include "core/utils/url_codec.hxx"
|
|
21
22
|
#include "error_utils.hxx"
|
|
22
23
|
|
|
23
24
|
#include <fmt/core.h>
|
|
@@ -36,8 +37,8 @@ search_index_control_plan_freeze_request::encode_to(encoded_request_type& encode
|
|
|
36
37
|
encoded.method = "POST";
|
|
37
38
|
if (bucket_name.has_value() && scope_name.has_value()) {
|
|
38
39
|
encoded.path = fmt::format("/api/bucket/{}/scope/{}/index/{}/planFreezeControl/{}",
|
|
39
|
-
bucket_name.value(),
|
|
40
|
-
scope_name.value(),
|
|
40
|
+
utils::string_codec::v2::path_escape(bucket_name.value()),
|
|
41
|
+
utils::string_codec::v2::path_escape(scope_name.value()),
|
|
41
42
|
index_name,
|
|
42
43
|
freeze ? "freeze" : "unfreeze");
|
|
43
44
|
} else {
|
package/deps/couchbase-cxx-client/core/operations/management/search_index_control_plan_freeze.hxx
CHANGED
|
@@ -40,6 +40,7 @@ struct search_index_control_plan_freeze_request {
|
|
|
40
40
|
using error_context_type = error_context::http;
|
|
41
41
|
|
|
42
42
|
static const inline service_type type = service_type::search;
|
|
43
|
+
static const inline std::string observability_identifier = "manager_search_control_plan_freeze";
|
|
43
44
|
|
|
44
45
|
std::string index_name;
|
|
45
46
|
bool freeze;
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
#include "search_index_control_query.hxx"
|
|
19
19
|
|
|
20
20
|
#include "core/utils/json.hxx"
|
|
21
|
+
#include "core/utils/url_codec.hxx"
|
|
21
22
|
#include "error_utils.hxx"
|
|
22
23
|
|
|
23
24
|
#include <fmt/core.h>
|
|
@@ -35,8 +36,8 @@ search_index_control_query_request::encode_to(encoded_request_type& encoded,
|
|
|
35
36
|
encoded.method = "POST";
|
|
36
37
|
if (bucket_name.has_value() && scope_name.has_value()) {
|
|
37
38
|
encoded.path = fmt::format("/api/bucket/{}/scope/{}/index/{}/queryControl/{}",
|
|
38
|
-
bucket_name.value(),
|
|
39
|
-
scope_name.value(),
|
|
39
|
+
utils::string_codec::v2::path_escape(bucket_name.value()),
|
|
40
|
+
utils::string_codec::v2::path_escape(scope_name.value()),
|
|
40
41
|
index_name,
|
|
41
42
|
allow ? "allow" : "disallow");
|
|
42
43
|
} else {
|
|
@@ -38,6 +38,7 @@ struct search_index_control_query_request {
|
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
40
|
static const inline service_type type = service_type::search;
|
|
41
|
+
static const inline std::string observability_identifier = "manager_search_control_querying";
|
|
41
42
|
|
|
42
43
|
std::string index_name;
|
|
43
44
|
bool allow;
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
#include "search_index_drop.hxx"
|
|
19
19
|
|
|
20
20
|
#include "core/utils/json.hxx"
|
|
21
|
+
#include "core/utils/url_codec.hxx"
|
|
21
22
|
#include "error_utils.hxx"
|
|
22
23
|
|
|
23
24
|
#include <fmt/core.h>
|
|
@@ -34,8 +35,10 @@ search_index_drop_request::encode_to(encoded_request_type& encoded,
|
|
|
34
35
|
}
|
|
35
36
|
encoded.method = "DELETE";
|
|
36
37
|
if (bucket_name.has_value() && scope_name.has_value()) {
|
|
37
|
-
encoded.path = fmt::format(
|
|
38
|
-
|
|
38
|
+
encoded.path = fmt::format("/api/bucket/{}/scope/{}/index/{}",
|
|
39
|
+
utils::string_codec::v2::path_escape(bucket_name.value()),
|
|
40
|
+
utils::string_codec::v2::path_escape(scope_name.value()),
|
|
41
|
+
index_name);
|
|
39
42
|
} else {
|
|
40
43
|
encoded.path = fmt::format("/api/index/{}", index_name);
|
|
41
44
|
}
|
|
@@ -38,6 +38,7 @@ struct search_index_drop_request {
|
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
40
|
static const inline service_type type = service_type::search;
|
|
41
|
+
static const inline std::string observability_identifier = "manager_search_drop_index";
|
|
41
42
|
|
|
42
43
|
std::string index_name;
|
|
43
44
|
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
|
|
20
20
|
#include "core/management/search_index_json.hxx"
|
|
21
21
|
#include "core/utils/json.hxx"
|
|
22
|
+
#include "core/utils/url_codec.hxx"
|
|
22
23
|
#include "error_utils.hxx"
|
|
23
24
|
|
|
24
25
|
#include <fmt/core.h>
|
|
@@ -35,8 +36,10 @@ search_index_get_request::encode_to(encoded_request_type& encoded,
|
|
|
35
36
|
}
|
|
36
37
|
encoded.method = "GET";
|
|
37
38
|
if (bucket_name.has_value() && scope_name.has_value()) {
|
|
38
|
-
encoded.path = fmt::format(
|
|
39
|
-
|
|
39
|
+
encoded.path = fmt::format("/api/bucket/{}/scope/{}/index/{}",
|
|
40
|
+
utils::string_codec::v2::path_escape(bucket_name.value()),
|
|
41
|
+
utils::string_codec::v2::path_escape(scope_name.value()),
|
|
42
|
+
index_name);
|
|
40
43
|
} else {
|
|
41
44
|
encoded.path = fmt::format("/api/index/{}", index_name);
|
|
42
45
|
}
|
|
@@ -40,6 +40,7 @@ struct search_index_get_request {
|
|
|
40
40
|
using error_context_type = error_context::http;
|
|
41
41
|
|
|
42
42
|
static const inline service_type type = service_type::search;
|
|
43
|
+
static const inline std::string observability_identifier = "manager_search_get_index";
|
|
43
44
|
|
|
44
45
|
std::string index_name;
|
|
45
46
|
std::optional<std::string> bucket_name;
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
|
|
20
20
|
#include "core/management/search_index_json.hxx"
|
|
21
21
|
#include "core/utils/json.hxx"
|
|
22
|
+
#include "core/utils/url_codec.hxx"
|
|
22
23
|
#include "error_utils.hxx"
|
|
23
24
|
|
|
24
25
|
#include <fmt/core.h>
|
|
@@ -32,8 +33,9 @@ search_index_get_all_request::encode_to(encoded_request_type& encoded,
|
|
|
32
33
|
{
|
|
33
34
|
encoded.method = "GET";
|
|
34
35
|
if (bucket_name.has_value() && scope_name.has_value()) {
|
|
35
|
-
encoded.path =
|
|
36
|
-
|
|
36
|
+
encoded.path = fmt::format("/api/bucket/{}/scope/{}/index",
|
|
37
|
+
utils::string_codec::v2::path_escape(bucket_name.value()),
|
|
38
|
+
utils::string_codec::v2::path_escape(scope_name.value()));
|
|
37
39
|
} else {
|
|
38
40
|
encoded.path = "/api/index";
|
|
39
41
|
}
|
|
@@ -40,6 +40,7 @@ struct search_index_get_all_request {
|
|
|
40
40
|
using error_context_type = error_context::http;
|
|
41
41
|
|
|
42
42
|
static const inline service_type type = service_type::search;
|
|
43
|
+
static const inline std::string observability_identifier = "manager_search_get_all_indexes";
|
|
43
44
|
|
|
44
45
|
std::optional<std::string> bucket_name;
|
|
45
46
|
std::optional<std::string> scope_name;
|
package/deps/couchbase-cxx-client/core/operations/management/search_index_get_documents_count.cxx
CHANGED
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
#include "search_index_get_documents_count.hxx"
|
|
19
19
|
|
|
20
20
|
#include "core/utils/json.hxx"
|
|
21
|
+
#include "core/utils/url_codec.hxx"
|
|
21
22
|
#include "error_utils.hxx"
|
|
22
23
|
|
|
23
24
|
#include <fmt/core.h>
|
|
@@ -33,8 +34,8 @@ search_index_get_documents_count_request::encode_to(encoded_request_type& encode
|
|
|
33
34
|
encoded.method = "GET";
|
|
34
35
|
if (bucket_name.has_value() && scope_name.has_value()) {
|
|
35
36
|
encoded.path = fmt::format("/api/bucket/{}/scope/{}/index/{}/count",
|
|
36
|
-
bucket_name.value(),
|
|
37
|
-
scope_name.value(),
|
|
37
|
+
utils::string_codec::v2::path_escape(bucket_name.value()),
|
|
38
|
+
utils::string_codec::v2::path_escape(scope_name.value()),
|
|
38
39
|
index_name);
|
|
39
40
|
} else {
|
|
40
41
|
encoded.path = fmt::format("/api/index/{}/count", index_name);
|
package/deps/couchbase-cxx-client/core/operations/management/search_index_get_documents_count.hxx
CHANGED
|
@@ -39,6 +39,8 @@ struct search_index_get_documents_count_request {
|
|
|
39
39
|
using error_context_type = error_context::http;
|
|
40
40
|
|
|
41
41
|
static const inline service_type type = service_type::search;
|
|
42
|
+
static const inline std::string observability_identifier =
|
|
43
|
+
"manager_search_get_indexed_documents_count";
|
|
42
44
|
|
|
43
45
|
std::string index_name;
|
|
44
46
|
|
|
@@ -39,6 +39,7 @@ struct search_index_get_stats_request {
|
|
|
39
39
|
using error_context_type = error_context::http;
|
|
40
40
|
|
|
41
41
|
static const inline service_type type = service_type::search;
|
|
42
|
+
static const inline std::string observability_identifier = "manager_search_get_stats";
|
|
42
43
|
|
|
43
44
|
std::string index_name;
|
|
44
45
|
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
|
|
20
20
|
#include "core/management/search_index_json.hxx"
|
|
21
21
|
#include "core/utils/json.hxx"
|
|
22
|
+
#include "core/utils/url_codec.hxx"
|
|
22
23
|
#include "error_utils.hxx"
|
|
23
24
|
|
|
24
25
|
#include <fmt/core.h>
|
|
@@ -37,8 +38,10 @@ search_index_upsert_request::encode_to(encoded_request_type& encoded,
|
|
|
37
38
|
encoded.headers["cache-control"] = "no-cache";
|
|
38
39
|
encoded.headers["content-type"] = "application/json";
|
|
39
40
|
if (bucket_name.has_value() && scope_name.has_value()) {
|
|
40
|
-
encoded.path = fmt::format(
|
|
41
|
-
|
|
41
|
+
encoded.path = fmt::format("/api/bucket/{}/scope/{}/index/{}",
|
|
42
|
+
utils::string_codec::v2::path_escape(bucket_name.value()),
|
|
43
|
+
utils::string_codec::v2::path_escape(scope_name.value()),
|
|
44
|
+
index.name);
|
|
42
45
|
} else {
|
|
43
46
|
encoded.path = fmt::format("/api/index/{}", index.name);
|
|
44
47
|
}
|
|
@@ -41,6 +41,7 @@ struct search_index_upsert_request {
|
|
|
41
41
|
using error_context_type = error_context::http;
|
|
42
42
|
|
|
43
43
|
static const inline service_type type = service_type::search;
|
|
44
|
+
static const inline std::string observability_identifier = "manager_search_upsert_index";
|
|
44
45
|
|
|
45
46
|
couchbase::core::management::search::index index;
|
|
46
47
|
|
|
@@ -36,6 +36,7 @@ struct user_drop_request {
|
|
|
36
36
|
using encoded_response_type = io::http_response;
|
|
37
37
|
using error_context_type = error_context::http;
|
|
38
38
|
|
|
39
|
+
static const inline std::string observability_identifier = "manager_users_drop_user";
|
|
39
40
|
static const inline service_type type = service_type::management;
|
|
40
41
|
|
|
41
42
|
std::string username{};
|
|
@@ -37,6 +37,7 @@ struct user_get_request {
|
|
|
37
37
|
using encoded_response_type = io::http_response;
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
|
+
static const inline std::string observability_identifier = "manager_users_get_user";
|
|
40
41
|
static const inline service_type type = service_type::management;
|
|
41
42
|
|
|
42
43
|
std::string username{};
|
|
@@ -37,6 +37,7 @@ struct user_get_all_request {
|
|
|
37
37
|
using encoded_response_type = io::http_response;
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
|
+
static const inline std::string observability_identifier = "manager_users_get_all_users";
|
|
40
41
|
static const inline service_type type = service_type::management;
|
|
41
42
|
|
|
42
43
|
couchbase::core::management::rbac::auth_domain domain{
|
|
@@ -51,11 +51,11 @@ user_upsert_request::encode_to(encoded_request_type& encoded,
|
|
|
51
51
|
for (const auto& role : user.roles) {
|
|
52
52
|
std::string spec = role.name;
|
|
53
53
|
if (role.bucket) {
|
|
54
|
-
spec += fmt::format("[{}", role.bucket.value());
|
|
54
|
+
spec += fmt::format("[{}", utils::string_codec::v2::path_escape(role.bucket.value()));
|
|
55
55
|
if (role.scope) {
|
|
56
|
-
spec += fmt::format(":{}", role.scope.value());
|
|
56
|
+
spec += fmt::format(":{}", utils::string_codec::v2::path_escape(role.scope.value()));
|
|
57
57
|
if (role.collection) {
|
|
58
|
-
spec += fmt::format(":{}", role.collection.value());
|
|
58
|
+
spec += fmt::format(":{}", utils::string_codec::v2::path_escape(role.collection.value()));
|
|
59
59
|
}
|
|
60
60
|
}
|
|
61
61
|
spec += "]";
|
|
@@ -37,6 +37,7 @@ struct user_upsert_request {
|
|
|
37
37
|
using encoded_response_type = io::http_response;
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
|
+
static const inline std::string observability_identifier = "manager_users_upsert_user";
|
|
40
41
|
static const inline service_type type = service_type::management;
|
|
41
42
|
|
|
42
43
|
couchbase::core::management::rbac::auth_domain domain{
|
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
|
|
18
18
|
#include "view_index_drop.hxx"
|
|
19
19
|
|
|
20
|
+
#include "core/utils/url_codec.hxx"
|
|
20
21
|
#include "error_utils.hxx"
|
|
21
22
|
|
|
22
23
|
#include <fmt/core.h>
|
|
@@ -30,7 +31,7 @@ view_index_drop_request::encode_to(encoded_request_type& encoded,
|
|
|
30
31
|
{
|
|
31
32
|
encoded.method = "DELETE";
|
|
32
33
|
encoded.path = fmt::format("/{}/_design/{}{}",
|
|
33
|
-
bucket_name,
|
|
34
|
+
utils::string_codec::v2::path_escape(bucket_name),
|
|
34
35
|
ns == design_document_namespace::development ? "dev_" : "",
|
|
35
36
|
document_name);
|
|
36
37
|
return {};
|
|
@@ -37,6 +37,7 @@ struct view_index_drop_request {
|
|
|
37
37
|
using error_context_type = error_context::http;
|
|
38
38
|
|
|
39
39
|
static const inline service_type type = service_type::view;
|
|
40
|
+
static const inline std::string observability_identifier = "manager_views_drop_design_document";
|
|
40
41
|
|
|
41
42
|
std::string bucket_name;
|
|
42
43
|
std::string document_name;
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
#include "view_index_get.hxx"
|
|
19
19
|
|
|
20
20
|
#include "core/utils/json.hxx"
|
|
21
|
+
#include "core/utils/url_codec.hxx"
|
|
21
22
|
#include "error_utils.hxx"
|
|
22
23
|
|
|
23
24
|
#include <fmt/core.h>
|
|
@@ -31,7 +32,7 @@ view_index_get_request::encode_to(encoded_request_type& encoded,
|
|
|
31
32
|
{
|
|
32
33
|
encoded.method = "GET";
|
|
33
34
|
encoded.path = fmt::format("/{}/_design/{}{}",
|
|
34
|
-
bucket_name,
|
|
35
|
+
utils::string_codec::v2::path_escape(bucket_name),
|
|
35
36
|
ns == design_document_namespace::development ? "dev_" : "",
|
|
36
37
|
document_name);
|
|
37
38
|
return {};
|
|
@@ -38,6 +38,7 @@ struct view_index_get_request {
|
|
|
38
38
|
using error_context_type = error_context::http;
|
|
39
39
|
|
|
40
40
|
static const inline service_type type = service_type::view;
|
|
41
|
+
static const inline std::string observability_identifier = "manager_views_get_design_document";
|
|
41
42
|
|
|
42
43
|
std::string bucket_name;
|
|
43
44
|
std::string document_name;
|