mirror of https://github.com/mongodb/mongo
Revert "SERVER-114734 Add extension_options configurations to archive-dist-test tarball (#45207)" (#45282)
Co-authored-by: auto-revert-processor <devprod-si-team@mongodb.com> GitOrigin-RevId: 67ce34c32809f5a498ab187a12b91b739eba90b8
This commit is contained in:
parent
550cf43403
commit
9ec406e405
|
|
@ -313,12 +313,6 @@ mongo_install(
|
|||
"//src/mongo/db/shard_role/lock_manager:lock_gdb_test.py": "//src/mongo/db:mongod",
|
||||
"//src/mongo/db/query/stage_builder/sbe/abt:optimizer_gdb_test.py": "//src/mongo/db/query/stage_builder/sbe/abt:optimizer_gdb_test_program",
|
||||
},
|
||||
root_files = select({
|
||||
"@platforms//os:linux": {
|
||||
"//src/mongo/db/extension/test_examples:extension_options_configs": "etc/mongo/extensions",
|
||||
},
|
||||
"//conditions:default": {},
|
||||
}),
|
||||
try_zstd = True,
|
||||
deps = [
|
||||
"//src/mongo/db/modules/enterprise:dist-test",
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
load("//bazel/install_rules:install_rules.bzl", "extensions_with_config")
|
||||
load("//bazel:mongo_src_rules.bzl", "mongo_cc_extension_shared_library")
|
||||
load("@poetry//:dependencies.bzl", "dependency")
|
||||
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
|
|
@ -92,43 +91,6 @@ pkg_name = "//" + package_name() + "/"
|
|||
]
|
||||
]
|
||||
|
||||
py_binary(
|
||||
name = "gen_conf",
|
||||
srcs = [":gen_conf.py"],
|
||||
data = ["configurations.yml"],
|
||||
deps = [
|
||||
dependency(
|
||||
"pyyaml",
|
||||
group = "core",
|
||||
),
|
||||
],
|
||||
)
|
||||
|
||||
[
|
||||
genrule(
|
||||
name = extension_name + "_conf",
|
||||
srcs = ["configurations.yml"],
|
||||
outs = [extension_name + ".conf"],
|
||||
cmd = "$(location :gen_conf) $(OUTS) $(SRCS) " + extension_name,
|
||||
tools = [":gen_conf"],
|
||||
)
|
||||
for extension_name in [
|
||||
"test_options",
|
||||
"parse_options",
|
||||
"toaster",
|
||||
]
|
||||
]
|
||||
|
||||
filegroup(
|
||||
name = "extension_options_configs",
|
||||
srcs = [
|
||||
"parse_options_conf",
|
||||
"test_options_conf",
|
||||
"toaster_conf",
|
||||
":aggregation_stage_fallback_parsers.json",
|
||||
],
|
||||
)
|
||||
|
||||
# Extensions under test_examples/extension_options/
|
||||
[
|
||||
mongo_cc_extension_shared_library(
|
||||
|
|
|
|||
0
src/mongo/db/extension/test_examples/aggregation_stage_fallback_parsers.json
Executable file → Normal file
0
src/mongo/db/extension/test_examples/aggregation_stage_fallback_parsers.json
Executable file → Normal file
|
|
@ -1,20 +0,0 @@
|
|||
import sys
|
||||
|
||||
import yaml
|
||||
|
||||
|
||||
def get_extension_confs(file_path, extension_name):
|
||||
with open(file_path, "r") as file:
|
||||
data = yaml.safe_load(file)
|
||||
return data["extensions"][extension_name]
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
output = sys.argv[1]
|
||||
conf_file = sys.argv[2]
|
||||
extension_name = sys.argv[3]
|
||||
conf_data = get_extension_confs(conf_file, extension_name)
|
||||
new_conf = dict(conf_data)
|
||||
new_conf["sharedLibraryPath"] = f"lib/lib{extension_name}_mongo_extension.so"
|
||||
with open(output, "w") as stream:
|
||||
yaml.dump(new_conf, stream)
|
||||
Loading…
Reference in New Issue