couchbase 4.4.2 → 4.4.4
Sign up to get free protection for your applications and to get access to all the features.
- 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
package/tools/gen-bindings-js.js
CHANGED
@@ -138,6 +138,8 @@ function getCppType(type) {
|
|
138
138
|
const ofType = getCppType(type.of)
|
139
139
|
const sizeVal = type.size
|
140
140
|
return `${type.name}<${ofType}, ${sizeVal}>`
|
141
|
+
} else if (type.name == 'template') {
|
142
|
+
return getCppType(type.of)
|
141
143
|
}
|
142
144
|
|
143
145
|
if (type.of) {
|
@@ -162,6 +164,21 @@ function getUnprefixedName(name) {
|
|
162
164
|
throw new Error('unexpected struct name')
|
163
165
|
}
|
164
166
|
|
167
|
+
// handle templated names
|
168
|
+
if (name.includes('<')) {
|
169
|
+
const nameTokens = name.split('<')
|
170
|
+
const templateNameTokens = nameTokens[1].replace('>', '').split('::')
|
171
|
+
const templateName = uppercaseFirstLetter(
|
172
|
+
templateNameTokens[templateNameTokens.length - 1]
|
173
|
+
)
|
174
|
+
// move the _request to the end of the name
|
175
|
+
if (nameTokens[0].includes('_request')) {
|
176
|
+
name = nameTokens[0].replace('_request', '') + templateName + '_request'
|
177
|
+
} else {
|
178
|
+
name = nameTokens[0] + templateName
|
179
|
+
}
|
180
|
+
}
|
181
|
+
|
165
182
|
// replace all namespace separators with underscores
|
166
183
|
name = name.replace(/::/g, '_')
|
167
184
|
if (name.includes('_with_legacy_durability')) {
|
@@ -330,6 +347,9 @@ async function go() {
|
|
330
347
|
if (opStruct.name.endsWith('_with_legacy_durability')) {
|
331
348
|
opReqTypes.push(opStruct.name)
|
332
349
|
}
|
350
|
+
if (opStruct.name.endsWith('>')) {
|
351
|
+
opReqTypes.push(opStruct.name.replace('_request', ''))
|
352
|
+
}
|
333
353
|
})
|
334
354
|
|
335
355
|
// filter out the custom types
|
@@ -377,6 +397,11 @@ async function go() {
|
|
377
397
|
const jsFieldType = getTsType(field.type.of, ops)
|
378
398
|
|
379
399
|
outJsAll.write(` ${jsFieldName}?: ${jsFieldType}`)
|
400
|
+
} else if (field.type.name === 'template') {
|
401
|
+
const jsFieldName = field.name
|
402
|
+
const jsFieldType = getStructTsName(field.type.of.name)
|
403
|
+
|
404
|
+
outJsAll.write(` ${jsFieldName}: ${jsFieldType}`)
|
380
405
|
} else {
|
381
406
|
const jsFieldName = field.name
|
382
407
|
const jsFieldType = getTsType(field.type, ops)
|
@@ -416,9 +441,15 @@ async function go() {
|
|
416
441
|
opReqTypes.forEach((x) => {
|
417
442
|
const jsOpName = getTsNiceName(x)
|
418
443
|
const jsReqName = getStructTsName(x + '_request')
|
419
|
-
|
420
|
-
|
421
|
-
|
444
|
+
let jsRespName
|
445
|
+
if (x.endsWith('_with_legacy_durability')) {
|
446
|
+
jsRespName = getStructTsName(x.substr(0, x.length - 31) + '_response')
|
447
|
+
} else if (x.endsWith('>')) {
|
448
|
+
const reqTokens = x.split('<')
|
449
|
+
jsRespName = getStructTsName(reqTokens[0] + '_response')
|
450
|
+
} else {
|
451
|
+
jsRespName = getStructTsName(x + '_response')
|
452
|
+
}
|
422
453
|
|
423
454
|
outJsAll.write(` ${jsOpName}(`)
|
424
455
|
outJsAll.write(` options: ${jsReqName},`)
|
@@ -498,6 +529,10 @@ async function go() {
|
|
498
529
|
outCppFuncDefs.write(` executeOp("${cppBaseOpName}",`)
|
499
530
|
if (x.endsWith('_with_legacy_durability')) {
|
500
531
|
outCppFuncDefs.write(` jsToCbpp<${x}>(optsJsObj),`)
|
532
|
+
} else if (x.endsWith('>')) {
|
533
|
+
const reqTokens = x.split('<')
|
534
|
+
const cppReqName = reqTokens[0] + '_request<' + reqTokens[1]
|
535
|
+
outCppFuncDefs.write(` jsToCbpp<${cppReqName}>(optsJsObj),`)
|
501
536
|
} else {
|
502
537
|
outCppFuncDefs.write(` jsToCbpp<${x}_request>(optsJsObj),`)
|
503
538
|
}
|