diff options
author | Luke Chen <luke.chen@mongodb.com> | 2021-03-22 15:42:38 +1100 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2021-03-22 05:02:38 +0000 |
commit | 69ab3b4e0bf2831578e5dd004f892e6cc137032c (patch) | |
tree | 92dd7db0b3e69fc3b6afeaf6e6bed4f1017a9c35 | |
parent | ce58b728e87056ede78d88d163a3708138be49e1 (diff) | |
download | mongo-69ab3b4e0bf2831578e5dd004f892e6cc137032c.tar.gz |
Import wiredtiger: a3bd9d2ccf9c12fbc12a39309d927214691ff9b3 from branch mongodb-5.0
ref: 94d67e377a..a3bd9d2ccf
for: 4.9.0
WT-7160 Migrate wiredtiger-doc-build job to Evergreen
-rw-r--r-- | src/third_party/wiredtiger/import.data | 2 | ||||
-rwxr-xr-x | src/third_party/wiredtiger/test/evergreen.yml | 99 |
2 files changed, 100 insertions, 1 deletions
diff --git a/src/third_party/wiredtiger/import.data b/src/third_party/wiredtiger/import.data index 9f40a18b5cb..7d0b6d03b14 100644 --- a/src/third_party/wiredtiger/import.data +++ b/src/third_party/wiredtiger/import.data @@ -2,5 +2,5 @@ "vendor": "wiredtiger", "github": "wiredtiger/wiredtiger.git", "branch": "mongodb-5.0", - "commit": "94d67e377a3f5dd09b3ac4bc03cc98c4e173f5e7" + "commit": "a3bd9d2ccf9c12fbc12a39309d927214691ff9b3" } diff --git a/src/third_party/wiredtiger/test/evergreen.yml b/src/third_party/wiredtiger/test/evergreen.yml index a1636f718b3..a95bfcd697e 100755 --- a/src/third_party/wiredtiger/test/evergreen.yml +++ b/src/third_party/wiredtiger/test/evergreen.yml @@ -130,6 +130,89 @@ functions: --enable-strict --enable-diagnostic --with-builtins=lz4,snappy,zlib fi - *make_wiredtiger + "compile wiredtiger docs": + - command: shell.exec + params: + working_dir: "wiredtiger/build_posix" + shell: bash + script: | + set -o errexit + set -o verbose + + if [[ "${branch_name}" != "develop" ]]; then + echo "We only run the documentation update task on the WiredTiger (develop) Evergreen project." + exit 0 + fi + + # Go through each supported WiredTiger Github branch to build the docs. + # Please note the "branch" variable used here is a normal shell variable to store the name of + # a WiredTiger Github branch, while the "branch_name" used above is an Evergreen built-in variable + # to store the name of the branch being tested by the Evergreen project. + for branch in develop mongodb-4.4 mongodb-4.2 mongodb-4.0 mongodb-3.6 ; do + echo "[Debug] Checking out branch $branch ..." + git checkout $branch && git pull --ff-only && git reset --hard origin/$branch && git clean -fdqx + sh reconf + + # Java API is removed in newer branches via WT-6675. + if [ "$branch" = "mongodb-4.2" -o "$branch" = "mongodb-4.0" -o "$branch" = "mongodb-3.6" ]; then + ../configure CFLAGS="-DMIGHT_NOT_RUN -Wno-error" --enable-java --enable-python --enable-strict + (cd lang/python && make ../../../lang/python/wiredtiger_wrap.c) + (cd lang/java && make ../../../lang/java/wiredtiger_wrap.c) + else + ../configure CFLAGS="-DMIGHT_NOT_RUN -Wno-error" --enable-python --enable-strict + (cd lang/python && make ../../../lang/python/wiredtiger_wrap.c) + fi + + # Make sure the code fragment is in the documentation build. + make all-am + make -C test/utility + make -C examples/c + + (cd ../dist && sh s_docs) + (cd .. && rm -rf docs-$branch && mv docs docs-$branch) + done + "update wiredtiger docs": + - command: shell.exec + params: + working_dir: "wiredtiger" + shell: bash + script: | + set -o errexit + set -o verbose + + if [[ "${branch_name}" != "develop" ]]; then + echo "We only run the documentation update task on the WiredTiger (develop) Evergreen project." + exit 0 + fi + + git clone git@github.com:wiredtiger/wiredtiger.github.com.git + cd wiredtiger.github.com + + # Go through each supported WiredTiger Github branch to stage the doc changes. + # Please note the "branch" variable used here is a normal shell variable to store the name of + # a WiredTiger Github branch, while the "branch_name" used above is an Evergreen built-in variable + # to store the name of the branch being tested by the Evergreen project. + for branch in mongodb-3.6 mongodb-4.0 mongodb-4.2 mongodb-4.4 develop ; do + echo "[Debug] Copying over doc directory for branch $branch ..." + rsync -avq ../docs-$branch/ $branch/ + + # Commit and push the changes (if any). + git add $branch > /dev/null + done + + git commit -m "Update auto-generated develop docs" \ + --author="svc-bot-doc-build <svc-wiredtiger-doc-build@10gen.com>" > /dev/null + # Use separate shell.exec with "silent" directive to avoid exposing credentail in task log. + - command: shell.exec + params: + working_dir: "wiredtiger/wiredtiger.github.com" + shell: bash + silent: true + script: | + set -o errexit + set -o verbose + + git push https://${doc-update-github-token}@github.com/wiredtiger/wiredtiger.github.com "make check directory": command: shell.exec params: @@ -1926,6 +2009,12 @@ tasks: set -o verbose env CC=/opt/mongodbtoolchain/v3/bin/gcc CXX=/opt/mongodbtoolchain/v3/bin/g++ PATH=/opt/mongodbtoolchain/v3/bin:/opt/java/jdk11/bin:$PATH sh s_release `date +%Y%m%d` + - name: doc-update + commands: + - func: "get project" + - func: "compile wiredtiger docs" + - func: "update wiredtiger docs" + - name: syscall-linux depends_on: - name: compile @@ -2525,6 +2614,16 @@ buildvariants: tasks: - name: package +- name: doc-update + display_name: "~ Documentation update" + batchtime: 10080 # 1 day + run_on: + - ubuntu1804-test + tasks: + - name: doc-update + expansions: + configure_env_vars: PATH=/opt/mongodbtoolchain/v3/bin:$PATH + - name: linux-no-ftruncate display_name: Linux no ftruncate batchtime: 10080 # 1 day |