Skip to content

Consolidate the Windows NamedPipeLogger into the FifoLogger#382

Merged
mxpv merged 1 commit intocontainerd:mainfrom
jprendes:consolidate-logger
Mar 19, 2025
Merged

Consolidate the Windows NamedPipeLogger into the FifoLogger#382
mxpv merged 1 commit intocontainerd:mainfrom
jprendes:consolidate-logger

Conversation

@jprendes
Copy link
Contributor

There's a fair amount of duplicated code between both loggers.
Given that we can treat the named pipe as a std::fs::File, we can consolidate the functionality of both.

This PR:

  • removes the sys module with the NamedPipeLogger
  • brings the NamedPipeLogger functionality as a new with_named_pipe method in the FifoLogger.
  • moves all the NamedPipeLogger tests to the FifoLogger module
  • breaking: changes the signature of the FifoLogger::new so that it can construct the windows logger.

@github-actions github-actions bot added C-shim Containerd shim OS-windows A change is specific to Windows C-shim-protos Shim protos labels Mar 12, 2025
@jprendes jprendes force-pushed the consolidate-logger branch from 601f874 to 7c26aec Compare March 14, 2025 16:56
@github-actions github-actions bot removed the C-shim-protos Shim protos label Mar 14, 2025
@jprendes
Copy link
Contributor Author

@mxpv PTAL

@jprendes
Copy link
Contributor Author

Is this ready to merge?
Otherwise, how can I help? :-)

@mxpv
Copy link
Member

mxpv commented Mar 19, 2025

@jprendes the PR looks good. It looks like the CI is broken because of some other issue, I'll try to have a look soon.

Signed-off-by: Jorge Prendes <jorge.prendes@gmail.com>
@jprendes jprendes force-pushed the consolidate-logger branch from 7c26aec to 32f4104 Compare March 19, 2025 23:05
@mxpv mxpv added this pull request to the merge queue Mar 19, 2025
Merged via the queue into containerd:main with commit 3598068 Mar 19, 2025
18 checks passed
@jprendes jprendes deleted the consolidate-logger branch March 20, 2025 16:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

C-shim Containerd shim OS-windows A change is specific to Windows

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants