Skip to content

v1.8 backports 2020-07-03 - atomically replace endpoint header files #12400

Merged
aanm merged 1 commit intov1.8from
pr/tklauser/backport-1.8-ep-header-atomic-write
Jul 3, 2020
Merged

v1.8 backports 2020-07-03 - atomically replace endpoint header files #12400
aanm merged 1 commit intov1.8from
pr/tklauser/backport-1.8-ep-header-atomic-write

Conversation

@tklauser
Copy link
Copy Markdown
Member

@tklauser tklauser commented Jul 3, 2020

Once this PR is merged, you can update the PR labels via:

$ for pr in 12380; do contrib/backporting/set-labels.py $pr done 1.8; done

[ upstream commit 542f0c2 ]

Write contents of the header file to a temporary file first. It will
then be atomically renamed to the real file. This makes sure we never
end up with corrupted on inconsistent header files on the filesystem.
Also make sure the symlink to the old header file in the downgrade case
is created atomically. The github.com/google/renameio package is used
for the atomic replace and symlink creation.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
@tklauser tklauser added kind/backports This PR provides functionality previously merged into master. backport-pending/1.8 labels Jul 3, 2020
@tklauser tklauser requested a review from a team as a code owner July 3, 2020 09:19
@tklauser
Copy link
Copy Markdown
Member Author

tklauser commented Jul 3, 2020

test-backport-1.8

@aanm aanm merged commit 8e004f7 into v1.8 Jul 3, 2020
@aanm aanm deleted the pr/tklauser/backport-1.8-ep-header-atomic-write branch July 3, 2020 16:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/backports This PR provides functionality previously merged into master.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants