Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: tonistiigi/fsutil
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 9e7a6df48576
Choose a base ref
...
head repository: tonistiigi/fsutil
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 36ef4d8c0dbb
Choose a head ref
  • 15 commits
  • 13 files changed
  • 5 contributors

Commits on Feb 15, 2023

  1. Fix leaking file handle

    Remove the break statement that prevented the file from being closed.
    
    Signed-off-by: Gabriel Adrian Samfira <gsamfira@cloudbasesolutions.com>
    gabriel-samfira committed Feb 15, 2023
    Configuration menu
    Copy the full SHA
    b689884 View commit details
    Browse the repository at this point in the history

Commits on Apr 11, 2023

  1. Use RunWithPrivileges

    The EnableProcessPrivileges function will enable a certain set of
    privileges for the entire process. I am unsure if enabling/disabling
    privileges is tracked with some sort of reference counting, but if it's
    not, when we release those privileges, we disable them for the entire
    process. This means that if some other go routine requires them, we may
    end up with undesirable results.
    
    The RunWithPrivileges locks the thread in which the function runs, and
    enables those privileges only in that thread.
    
    Signed-off-by: Gabriel Adrian Samfira <gsamfira@cloudbasesolutions.com>
    gabriel-samfira committed Apr 11, 2023
    Configuration menu
    Copy the full SHA
    30ab577 View commit details
    Browse the repository at this point in the history

Commits on Jun 27, 2023

  1. Merge pull request #158 from gabriel-samfira/use-run-with-privileges

    Use RunWithPrivileges
    tonistiigi authored Jun 27, 2023
    Configuration menu
    Copy the full SHA
    b80225e View commit details
    Browse the repository at this point in the history
  2. Merge pull request #153 from gabriel-samfira/fix-leaking-file-handles

    Fix leaking file handle
    tonistiigi authored Jun 27, 2023
    Configuration menu
    Copy the full SHA
    22252dd View commit details
    Browse the repository at this point in the history

Commits on Jun 29, 2023

  1. walk: avoid stat()'ing files unnecessarily

    Before:
    
    ```
    go test -bench=. .
    goos: linux
    goarch: amd64
    pkg: github.com/tonistiigi/fsutil
    cpu: Intel(R) Core(TM) i7-10610U CPU @ 1.80GHz
    BenchmarkWalker/[1]-target-8         	   27994	     41254 ns/op
    BenchmarkWalker/[1]-**/target-8      	   29540	     40402 ns/op
    BenchmarkWalker/[2]-*/target-8       	    1017	   1104834 ns/op
    BenchmarkWalker/[2]-**/target-8      	     920	   1124731 ns/op
    BenchmarkWalker/[3]-*/*/target-8     	      34	  40524094 ns/op
    BenchmarkWalker/[3]-**/target-8      	      32	  40432908 ns/op
    BenchmarkWalker/[4]-*/*/*/target-8   	      31	  44836714 ns/op
    BenchmarkWalker/[4]-**/target-8      	      26	  44611379 ns/op
    BenchmarkWalker/[5]-*/*/*/*/target-8 	      85	  14179975 ns/op
    BenchmarkWalker/[5]-**/target-8      	      78	  13620031 ns/op
    BenchmarkWalker/[6]-*/*/*/*/*/target-8         	      44	  23380013 ns/op
    BenchmarkWalker/[6]-**/target-8                	      51	  22435264 ns/op
    BenchmarkWalker/[6]-**-!*/*/**-8               	    2101	    580936 ns/op
    ```
    
    After:
    
    ```
    go test -bench=. .
    goos: linux
    goarch: amd64
    pkg: github.com/tonistiigi/fsutil
    cpu: Intel(R) Core(TM) i7-10610U CPU @ 1.80GHz
    BenchmarkWalker/[1]-target-8         	   40788	     26219 ns/op
    BenchmarkWalker/[1]-**/target-8      	   41642	     26998 ns/op
    BenchmarkWalker/[2]-*/target-8       	    1725	    660271 ns/op
    BenchmarkWalker/[2]-**/target-8      	    1806	    645525 ns/op
    BenchmarkWalker/[3]-*/*/target-8     	      64	  17609101 ns/op
    BenchmarkWalker/[3]-**/target-8      	      66	  17563334 ns/op
    BenchmarkWalker/[4]-*/*/*/target-8   	      40	  26241578 ns/op
    BenchmarkWalker/[4]-**/target-8      	      43	  24575370 ns/op
    BenchmarkWalker/[5]-*/*/*/*/target-8 	     121	   9564283 ns/op
    BenchmarkWalker/[5]-**/target-8      	     126	   9412483 ns/op
    BenchmarkWalker/[6]-*/*/*/*/*/target-8         	      63	  18703020 ns/op
    BenchmarkWalker/[6]-**/target-8                	      73	  17287584 ns/op
    BenchmarkWalker/[6]-**-!*/*/**-8               	    3792	    273148 ns/op
    ```
    
    Signed-off-by: Nick Santos <nick.santos@docker.com>
    nicks committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    b9e22fc View commit details
    Browse the repository at this point in the history
  2. handle mkdir race for diskwriter

    If using the diskwriter hanlders in parallel we might see a common
    directory being created in parallel, only one will win.  This allows us
    to gracefully retry/re-evaluate when we get a syscall.EEXIST error on
    the mkdir instead of returning an error.
    coryb committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    8176e09 View commit details
    Browse the repository at this point in the history
  3. Merge pull request #161 from coryb/mkdir-race

    handle mkdir race for diskwriter
    tonistiigi authored Jun 29, 2023
    Configuration menu
    Copy the full SHA
    4951688 View commit details
    Browse the repository at this point in the history
  4. Merge pull request #160 from nicks/nicks/walkdir

    walk: avoid stat()'ing files unnecessarily
    tonistiigi authored Jun 29, 2023
    Configuration menu
    Copy the full SHA
    2bcc6db View commit details
    Browse the repository at this point in the history
  5. ci: update to FreeBSD 13.2 stable

    Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
    crazy-max committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    de9b3f4 View commit details
    Browse the repository at this point in the history
  6. ci: update runner to latest macos for freebsd job

    Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
    crazy-max committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    905f4a1 View commit details
    Browse the repository at this point in the history
  7. ci: add timeout to freebsd workflow

    Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
    crazy-max committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    062c2c7 View commit details
    Browse the repository at this point in the history
  8. ci: concurrency check

    Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
    crazy-max committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    61b7e6f View commit details
    Browse the repository at this point in the history
  9. Merge pull request #163 from crazy-max/fix-ci

    ci: fix freebsd workflow
    tonistiigi authored Jun 29, 2023
    Configuration menu
    Copy the full SHA
    171984c View commit details
    Browse the repository at this point in the history
  10. update to Go 1.20

    Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
    tonistiigi committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    d384523 View commit details
    Browse the repository at this point in the history
  11. Merge pull request #162 from tonistiigi/tonistiigi/go-1.20

    update to Go 1.20
    tonistiigi authored Jun 29, 2023
    Configuration menu
    Copy the full SHA
    36ef4d8 View commit details
    Browse the repository at this point in the history
Loading