Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fs: add O_DSYNC flag #15451

Closed
wants to merge 3 commits into from
Closed

fs: add O_DSYNC flag #15451

wants to merge 3 commits into from

Conversation

jrasanen
Copy link
Contributor

Added support for O_DSYNC file open flag. (issue #15425)

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • documentation is changed or added
  • commit message follows commit guidelines
Affected core subsystem(s)

src

@nodejs-github-bot nodejs-github-bot added the c++ Issues and PRs that require attention from people who are familiar with C++. label Sep 18, 2017
Copy link
Member

@lpinca lpinca left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SGTM.

Copy link
Member

@bnoordhuis bnoordhuis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

@tniessen tniessen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for this contribution! 😃

Note: It might be a good idea to rephrase the description of O_SYNC and O_DSYNC to emphasize their differences and to distinguish synchronous operations from synchronous API calls. This does not need to be fixed within this PR though.

@jrasanen
Copy link
Contributor Author

Hi,

thanks for the comment! How would we rephrase it to emphasize the difference? Could it be O_FULLSYNC?

@tniessen
Copy link
Member

Could it be O_FULLSYNC?

No, we should not deviate from the POSIX convention here. I would probably just adapt the descriptions from the Linux manual:

O_SYNC:

Write operations on the file will complete according to the requirements of synchronized I/O file integrity completion (by contrast with the synchronized I/O data integrity completion provided by O_DSYNC.) Refer to the Linux manual for further information.

O_DSYNC:

Write operations on the file will complete according to the requirements of synchronized I/O data integrity completion. Refer to the Linux manual for further information.

@BridgeAR
Copy link
Member

@tniessen would you want to have this rephrased before landing or would that be fine sometime later on?

@tniessen tniessen added the semver-minor PRs that contain new features and should be released in the next minor version. label Sep 22, 2017
tniessen pushed a commit that referenced this pull request Sep 22, 2017
PR-URL: #15451
Fixes: #15425
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
@tniessen
Copy link
Member

Landed in 60460bf 🎉 Thank you for your contribution, we are looking forward to more! 😃

I marked this as semver-minor to comply with our guidelines. Partial CI on master: https://ci.nodejs.org/job/node-test-commit-linuxone/8729/

@tniessen tniessen closed this Sep 22, 2017
tniessen added a commit to tniessen/node that referenced this pull request Sep 22, 2017
@tniessen tniessen changed the title src: add O_DSYNC flag fs: add O_DSYNC flag Sep 22, 2017
@jrasanen jrasanen deleted the 15425-dsync-to-fs branch September 22, 2017 06:22
addaleax pushed a commit to addaleax/ayo that referenced this pull request Sep 23, 2017
PR-URL: nodejs/node#15451
Fixes: nodejs/node#15425
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
@jasnell
Copy link
Member

jasnell commented Sep 25, 2017

This does not land cleanly in v8.x-staging because the new fixtures tooling has not been backport to that yet. A backport PR would be needed.

tniessen added a commit to tniessen/node that referenced this pull request Sep 26, 2017
PR-URL: nodejs#15547
Refs: nodejs#15451
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
addaleax pushed a commit to addaleax/ayo that referenced this pull request Sep 30, 2017
PR-URL: nodejs/node#15547
Refs: nodejs/node#15451
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
tniessen pushed a commit to tniessen/node that referenced this pull request Oct 3, 2017
PR-URL: nodejs#15451
Fixes: nodejs#15425
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
tniessen added a commit to tniessen/node that referenced this pull request Oct 3, 2017
PR-URL: nodejs#15547
Refs: nodejs#15451
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
MylesBorins pushed a commit that referenced this pull request Oct 7, 2017
Backport-PR-URL: #15653
PR-URL: #15451
Fixes: #15425
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
MylesBorins pushed a commit that referenced this pull request Oct 7, 2017
Backport-PR-URL: #15653
PR-URL: #15547
Refs: #15451
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
@MylesBorins MylesBorins mentioned this pull request Oct 7, 2017
MylesBorins pushed a commit that referenced this pull request Oct 11, 2017
Backport-PR-URL: #15653
PR-URL: #15451
Fixes: #15425
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
MylesBorins pushed a commit that referenced this pull request Oct 11, 2017
Backport-PR-URL: #15653
PR-URL: #15547
Refs: #15451
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
MylesBorins added a commit that referenced this pull request Oct 11, 2017
Notable Changes:

* deps:
  * update npm to 5.4.2
    #15600
  * upgrade libuv to 1.15.0
    #15745
  * update V8 to 6.1.534.42
    #15393
* dgram:
  * support for setting dgram socket buffer size
    #13623
* fs:
  * add support O_DSYNC file open constant
    #15451
* util:
  * deprecate obj.inspect for custom inspection
    #15631
* tools, build:
  * there is a fancy new macOS installer
    #15179
* Added new collaborator
  * bmeurer - Benedikt Meurer - https://github.com/bmeurer
  * kfarnung - Kyle Farnung - https://github.com/kfarnung

PR-URL: #15762
MylesBorins added a commit that referenced this pull request Oct 11, 2017
Notable Changes:

* deps:
  * update npm to 5.4.2
    #15600
  * upgrade libuv to 1.15.0
    #15745
  * update V8 to 6.1.534.42
    #15393
* dgram:
  * support for setting dgram socket buffer size
    #13623
* fs:
  * add support O_DSYNC file open constant
    #15451
* util:
  * deprecate obj.inspect for custom inspection
    #15631
* tools, build:
  * there is a fancy new macOS installer
    #15179
* Added new collaborator
  * bmeurer - Benedikt Meurer - https://github.com/bmeurer
  * kfarnung - Kyle Farnung - https://github.com/kfarnung

PR-URL: #15762
addaleax pushed a commit to addaleax/ayo that referenced this pull request Oct 12, 2017
Notable Changes:

* deps:
  * update npm to 5.4.2
    nodejs/node#15600
  * upgrade libuv to 1.15.0
    nodejs/node#15745
  * update V8 to 6.1.534.42
    nodejs/node#15393
* dgram:
  * support for setting dgram socket buffer size
    nodejs/node#13623
* fs:
  * add support O_DSYNC file open constant
    nodejs/node#15451
* util:
  * deprecate obj.inspect for custom inspection
    nodejs/node#15631
* tools, build:
  * there is a fancy new macOS installer
    nodejs/node#15179
* Added new collaborator
  * bmeurer - Benedikt Meurer - https://github.com/bmeurer
  * kfarnung - Kyle Farnung - https://github.com/kfarnung

PR-URL: nodejs/node#15762
@gibfahn
Copy link
Member

gibfahn commented Jan 15, 2018

Release team were +1 on backporting to v6.x.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ Issues and PRs that require attention from people who are familiar with C++. semver-minor PRs that contain new features and should be released in the next minor version.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

10 participants