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

retain cli output experience #39

Open
andrewhsu opened this issue Mar 29, 2019 · 1 comment
Open

retain cli output experience #39

andrewhsu opened this issue Mar 29, 2019 · 1 comment
Assignees

Comments

@andrewhsu
Copy link

andrewhsu commented Mar 29, 2019

This is a tracking issue to ensure the old cli output experience is similar to the new cli output experience.

This issue should be taken care of by getting integration-cli tests running and passing.

@dmcgowan dmcgowan added this to To do in containerd-integration via automation Mar 29, 2019
@thaJeztah
Copy link
Collaborator

thaJeztah commented Apr 11, 2019

Discussing with @dmcgowan on Slack;

There's a couple of issues to address when migrating images from Docker to Containerd;

containerd uses timestamps for objects, which are set to the date/time that an object was added to the local metadata-store. This is a good match for LastTagTime, as this means that containerd offers this out of the box.

The problem for LastTagTime is that when we migrate the images from Docker to containerd, those images will be tagged at that moment, so all images will get the date/time of the migration.

Containerd does allow storing custom metadata/labels for objects, so we can add the information and have dockerd use that to fill in the information. Some things we were discussing;

  • dockerd should not require those custom properties to be present, as it should be able to handle images that were not migrated, not pulled through the docker daemon (i.e. if images were added directly by containerd); same for containers that were started outside of dockerd.
  • we can add a label for LastTagTime, which (if present) is used by dockerd to show the date/time of tagging, and fall back to the actual tag-timestamp if no label is found
  • we should only add those labels for images that were migrated
  • remove this functionality after X releases (as it's only useful for the migration case)

The Created date shown by docker (docker images CREATED column) is a bit more challenging. This column shows information about when the image was originally created by the author. Containerd itself does not keep track of that information; it stores the images, but does not look at the date/time the image was created; it only stores the date/time at which the image was added to the metadata store, not when it was originally created.

Some things were discussed;

  • The "created" date can be read from the manifest, so the information is not "lost"
  • Similar to the LastTagTime we can store this custom metadata in the containerd metadata store
  • Possibly add an extra column (ADDED?) that shows the date/time that the image was added locally; this is useful for images that were not pulled by dockerd (thus have no custom metadata stored to keep the
  • Show the CREATED data if the custom metadata is present, otherwise fall back to the ADDED date
    • Should we update images that were pulled outside of dockerd? Is this a costly operation?

^^ more info to be added

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

No branches or pull requests

2 participants