kaniko/pkg/commands
Aaron Lehmann 32ce1bf67e
Avoid redundant calls to filepath.Clean (#2652)
filepath.Clean shows up in profiles as a hot spot, and there seem to be
many redundant calls, particularly in ignorelist handling. We can avoid
these redundant calls by pre-cleaning entries in the ignore list, and
providing fast paths when we know we're already dealing with a cleaned
candidate path.

Before:

     580ms  3.03% 72.35%      590ms  3.08%  path/filepath.(*lazybuf).append (inline)
     390ms  2.03% 74.39%      990ms  5.16%  path/filepath.Clean

After:

     0.13s  0.69% 84.01%      0.17s  0.91%  path/filepath.(*lazybuf).append (inline)
     0.13s  0.69% 84.70%      0.31s  1.65%  path/filepath.Clean
2023-07-31 17:18:16 -07:00
..
add.go Upgrade docker (#2440) 2023-03-23 20:34:25 -04:00
arg.go Fix resolving arguments over multi-stage build (#1928) 2022-02-10 09:22:21 -08:00
base_command.go Fix multistage caching with COPY --from (#2559) 2023-06-16 10:56:05 -07:00
cache.go fmt 2020-04-30 17:07:18 -07:00
cache_test.go remove read succesS 2020-04-30 15:18:39 -07:00
cmd.go Fix bug with docker compatibility 2020-01-13 21:18:54 -08:00
cmd_test.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00
commands.go Fix multistage caching with COPY --from (#2559) 2023-06-16 10:56:05 -07:00
copy.go Fix multistage caching with COPY --from (#2559) 2023-06-16 10:56:05 -07:00
copy_test.go Avoid redundant calls to filepath.Clean (#2652) 2023-07-31 17:18:16 -07:00
entrypoint.go Fixing lint issues. Adding tests for COPY command. Fixing issue with copying files out of snapshots 2019-09-16 10:48:31 -07:00
entrypoint_test.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00
env.go Fixing lint issues. Adding tests for COPY command. Fixing issue with copying files out of snapshots 2019-09-16 10:48:31 -07:00
env_test.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00
expose.go fix: Refactor `LayersMap` to correct old strange code behavior (#2066) 2022-05-17 20:30:58 -04:00
expose_test.go Fixing lint issues. Adding tests for COPY command. Fixing issue with copying files out of snapshots 2019-09-16 10:48:31 -07:00
fake_commands.go add unit tests for caching run and copy 2019-12-10 09:29:10 -08:00
healthcheck.go Fixing lint issues. Adding tests for COPY command. Fixing issue with copying files out of snapshots 2019-09-16 10:48:31 -07:00
label.go Fixing lint issues. Adding tests for COPY command. Fixing issue with copying files out of snapshots 2019-09-16 10:48:31 -07:00
label_test.go Fixing lint issues. Adding tests for COPY command. Fixing issue with copying files out of snapshots 2019-09-16 10:48:31 -07:00
onbuild.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00
onbuild_test.go Fixing lint issues. Adding tests for COPY command. Fixing issue with copying files out of snapshots 2019-09-16 10:48:31 -07:00
run.go Fix multistage caching with COPY --from (#2559) 2023-06-16 10:56:05 -07:00
run_marker.go Fix multistage caching with COPY --from (#2559) 2023-06-16 10:56:05 -07:00
run_test.go Avoid redundant calls to filepath.Clean (#2652) 2023-07-31 17:18:16 -07:00
shell.go Update linter and fix errors 2019-12-21 12:27:14 -08:00
shell_test.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00
stopsignal.go fix: Refactor `LayersMap` to correct old strange code behavior (#2066) 2022-05-17 20:30:58 -04:00
stopsignal_test.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00
user.go fix: getUIDandGID is able to resolve non-existing users and groups (#2106) 2022-07-12 10:21:37 -04:00
user_test.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00
volume.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00
volume_test.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00
workdir.go fix(WORKDIR): use the config.User for the new dir permissions (#2269) 2022-09-28 21:18:40 -04:00
workdir_test.go Fix Integration tests (#2425) 2023-03-21 12:30:54 -04:00