IP Library Granted Patent US 11,314,443
Granted Patent B2
US 11,314,443 · App. 16/983,244 · Granted Apr 26, 2022

Method, device, and computer program product for managing image of container

Inventors: Si Chen (Shanghai, CN); Pengfei Wu (Shanghai, CN); Zhenzhen Lin (Shanghai, CN); Ruixue Zhang (Shanghai, CN)
Assignee: EMC IP Holding Company LLC
G06F3/0653G06F3/067G06F3/0614G06F3/0652G06F3/0659G06F3/0662G06F8/63G06F9/45533
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,314,443
App. No.
16/983,244
Granted
Apr 26, 2022
Kind
B2
Abstract

In a method for managing an image of a container in a host device, a first image of a first container is received, wherein the first image includes a first set of image layers for implementing a first set of services of the first container respectively. The first image is loaded to deploy the first container at the host device. Based on an attribute of an image layer in the first set of image layers, an expiration time is set for the image layer. In response to determining that the expiration time is reached, the image layer is deleted from the host device. Stored image layers can be reused to reduce the transmission bandwidth for remotely downloading the image layers. A corresponding device and a corresponding computer program product are provided.

Claims (66)

1. A method for managing an image of a container in a host device, comprising:

receiving a first image of a first container, the first image comprising a first set of image layers for implementing a first set of services of the first container respectively;

loading the first image to deploy the first container at the host device;

based on an attribute of an image layer in the first set of image layers, setting an expiration time for the image layer; and

in response to determining that the expiration time is reached, deleting the image layer from the host device;

wherein the attribute of the image layer comprises at least one of a parallel providing number of the image layer and a number of copies of the image layer in a host cluster; and

wherein the expiration time is determined at least in part as a function of the attribute of the image layer.

2. The method according to claim 1 , wherein setting an expiration time for the image layer comprises: setting the expiration time based on a level of the image layer, wherein the expiration time is inversely proportional to the level.

3. The method according to claim 1 , wherein setting an expiration time for the image layer comprises: setting the expiration time based on the parallel providing number of the image layer, wherein the expiration time is directly proportional to the parallel providing number, and the parallel providing number represents how many other host devices in the host cluster access the image layer in parallel at most.

4. The method according to claim 1 , wherein setting an expiration time for the image layer comprises: setting the expiration time based on the number of copies of the image layer in the host cluster, wherein the expiration time is inversely proportional to the number of the copies.

5. The method according to claim 1 , wherein setting an expiration time for the image layer comprises: setting the expiration time based on a difference between a current time and a time when the image layer was recently accessed, wherein the expiration time is inversely proportional to the difference, and the time when the image layer was recently accessed comprises at least one of the following:

a time when the host device recently accessed the image layer; and

a time when one or more other host devices in the host cluster recently accessed the image layer.

6. The method according to claim 1 , further comprising: in response to receiving an instruction to deploy a second container at the host device,

determining a second set of image layers for implementing a second set of services of the second container; and

in response to determining that a specified image layer in the second set of image layers is not in the host device, acquiring the specified image layer from one or more other host devices in the host cluster.

7. The method according to claim 6 , wherein acquiring the specified image layer from the one or more other host devices comprises:

acquiring a topological structure representing a connection between the host device and a plurality of other host devices in the host cluster; and

based on the topological structure, acquiring the specified image layer from the other host devices.

8. The method according to claim 6 , further comprising: in response to determining that the specified image layer is not in the host cluster, acquiring the specified image layer from an image server connected to the host cluster.

9. The method according to claim 1 , further comprising:

in response to receiving a request from one or more other host devices in the host cluster for acquiring the image layer, providing the image layer to the one or more other host devices; and

updating the expiration time of the image layer.

10. A method for managing an image of a container in a host device, comprising:

receiving a first image of a first container, the first image comprising a first set of image layers for implementing a first set of services of the first container respectively;

loading the first image to deploy the first container at the host device;

based on an attribute of an image layer in the first set of image layers, setting an expiration time for the image layer; and

in response to determining that the expiration time is reached, deleting the image layer from the host device;

wherein setting an expiration time for the image layer comprises: setting the expiration time based on a size of the image layer, wherein the expiration time is directly proportional to the size.

11. An electronic device, comprising:

at least one processor; and

a memory coupled to the at least one processor and having instructions stored therein, wherein the instructions, when executed by the at least one processor, cause the electronic device to perform actions for managing an image of a container in a host device, and the actions include:

receiving a first image of a first container, the first image comprising a first set of image layers for implementing a first set of services of the first container respectively;

loading the first image to deploy the first container at the host device;

based on an attribute of an image layer in the first set of image layers, setting an expiration time for the image layer; and

in response to determining that the expiration time is reached, deleting the image layer from the host device;

wherein the attribute of the image layer comprises at least one of a parallel providing number of the image layer and a number of copies of the image layer in a host cluster; and

wherein the expiration time is determined at least in part as a function of the attribute of the image layer.

12. The device according to claim 11 , wherein setting an expiration time for the image layer comprises: setting the expiration time based on a level of the image layer, wherein the expiration time is inversely proportional to the level.

13. The device according to claim 11 , wherein setting an expiration time for the image layer comprises: setting the expiration time based on the parallel providing number of the image layer, wherein the expiration time is directly proportional to the parallel providing number, and the parallel providing number represents how many other host devices in the host cluster access the image layer in parallel at most.

14. The device according to claim 11 , wherein setting an expiration time for the image layer comprises: setting the expiration time based on the number of copies of the image layer in the host cluster, wherein the expiration time is inversely proportional to the number of the copies.

15. The device according to claim 11 , wherein setting an expiration time for the image layer comprises: setting the expiration time based on a difference between a current time and a time when the image layer was recently accessed, wherein the expiration time is inversely proportional to the difference, and the time when the image layer was recently accessed comprises at least one of the following:

a time when the host device recently accessed the image layer; and

a time when one or more other host devices in the host cluster recently accessed the image layer.

16. The device according to claim 11 , wherein the actions further comprise: in response to receiving an instruction to deploy a second container at the host device,

determining a second set of image layers for implementing a second set of services of the second container; and

in response to determining that a specified image layer in the second set of image layers is not in the host device, acquiring the specified image layer from one or more other host devices in the host cluster.

17. The device according to claim 16 , wherein acquiring the specified image layer from the one or more other host devices comprises:

acquiring a topological structure representing a connection between the host device and a plurality of other host devices in the host cluster; and

based on the topological structure, acquiring the specified image layer from the other host devices.

18. The device according to claim 16 , wherein the actions further comprise: in response to determining that the specified image layer is not in the host cluster, acquiring the specified image layer from an image server connected to the host cluster.

19. An electronic device, comprising:

at least one processor; and

a memory coupled to the at least one processor and having instructions stored therein, wherein the instructions, when executed by the at least one processor, cause the electronic device to perform actions for managing an image of a container in a host device, and the actions include:

receiving a first image of a first container, the first image comprising a first set of image layers for implementing a first set of services of the first container respectively;

loading the first image to deploy the first container at the host device;

based on an attribute of an image layer in the first set of image layers, setting an expiration time for the image layer; and

in response to determining that the expiration time is reached, deleting the image layer from the host device;

wherein setting an expiration time for the image layer comprises: setting the expiration time based on a size of the image layer, wherein the expiration time is directly proportional to the size.

20. A computer program product tangibly stored on a non-transitory computer-readable medium and comprising machine-executable instructions, wherein the machine-executable instructions are used to implement a method for managing an image of a container in a host device, the method comprising:

receiving a first image of a first container, the first image comprising a first set of image layers for implementing a first set of services of the first container respectively;

loading the first image to deploy the first container at the host device;

based on an attribute of an image layer in the first set of image layers, setting an expiration time for the image layer; and

in response to determining that the expiration time is reached, deleting the image layer from the host device;

wherein the attribute of the image layer comprises at least one of a parallel providing number of the image layer and a number of copies of the image layer in a host cluster; and

wherein the expiration time is determined at least in part as a function of the attribute of the image layer.

Assignments (9)
RELEASE OF SECURITY INTEREST IN PATENTS PREVIOUSLY RECORDED AT REEL/FRAME (054475/0523) Recorded Jun 10, 2022
From: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A., AS NOTES COLLATERAL AGENT
To: EMC IP HOLDING COMPANY LLC; DELL PRODUCTS L.P.
Reel/Frame 060332/0664 →
RELEASE OF SECURITY INTEREST IN PATENTS PREVIOUSLY RECORDED AT REEL/FRAME (054475/0434) Recorded Jun 10, 2022
From: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A., AS NOTES COLLATERAL AGENT
To: EMC IP HOLDING COMPANY LLC; DELL PRODUCTS L.P.
Reel/Frame 060332/0740 →
RELEASE OF SECURITY INTEREST IN PATENTS PREVIOUSLY RECORDED AT REEL/FRAME (054475/0609) Recorded Jun 10, 2022
From: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A., AS NOTES COLLATERAL AGENT
To: EMC IP HOLDING COMPANY LLC; DELL PRODUCTS L.P.
Reel/Frame 062021/0570 →
RELEASE OF SECURITY INTEREST AT REEL 054591 FRAME 0471 Recorded Nov 2, 2021
From: CREDIT SUISSE AG, CAYMAN ISLANDS BRANCH
To: DELL PRODUCTS L.P.; EMC IP HOLDING COMPANY LLC
Reel/Frame 058001/0463 →
SECURITY INTEREST Recorded Nov 18, 2020
From: EMC IP HOLDING COMPANY LLC; DELL PRODUCTS L.P.
To: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A., AS COLLATERAL AGENT
Reel/Frame 054475/0609 →
SECURITY INTEREST Recorded Nov 18, 2020
From: EMC IP HOLDING COMPANY LLC; DELL PRODUCTS L.P.
To: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A., AS NOTES COLLATERAL AGENT
Reel/Frame 054475/0434 →
SECURITY INTEREST Recorded Nov 18, 2020
From: EMC IP HOLDING COMPANY LLC; DELL PRODUCTS L.P.
To: THE BANK OF NEW YORK MELLON TRUST COMPANY, N.A., AS NOTES COLLATERAL AGENT
Reel/Frame 054475/0523 →
SECURITY AGREEMENT Recorded Nov 13, 2020
From: EMC IP HOLDING COMPANY LLC; DELL PRODUCTS L.P.
To: CREDIT SUISSE AG, CAYMAN ISLANDS BRANCH
Reel/Frame 054591/0471 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Aug 3, 2020
From: CHEN, SI; WU, PENGFEI; LIN, ZHENZHEN; ZHANG, RUIXUE
To: EMC IP HOLDING COMPANY LLC
Reel/Frame 053382/0561 →