Skip to content

Commit

Permalink
Merge pull request #1219 from pedro93/fix-3.1.3-rc-create-container-m…
Browse files Browse the repository at this point in the history
…issing-regression

Reverts create container cmd regression.
  • Loading branch information
KostyaSha committed Jul 14, 2019
2 parents 99e79bb + 6f00250 commit 5c3ba9a
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,20 @@ public interface CreateContainerCmd extends SyncDockerCmd<CreateContainerRespons

CreateContainerCmd withMacAddress(String macAddress);

@Deprecated
@CheckForNull
Long getMemory();

@Deprecated
CreateContainerCmd withMemory(Long memory);

@Deprecated
@CheckForNull
Long getMemorySwap();

@Deprecated
CreateContainerCmd withMemorySwap(Long memorySwap);

@CheckForNull
String getName();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,37 @@ public CreateContainerCmd withMacAddress(String macAddress) {
return this;
}

@Deprecated
@Override
@JsonIgnore
public Long getMemory() {
return hostConfig.getMemory();
}

@Deprecated
@Override
public CreateContainerCmd withMemory(Long memory) {
checkNotNull(memory, "memory was not specified");
hostConfig.withMemory(memory);
return this;
}

@Deprecated
@Override
@JsonIgnore
public Long getMemorySwap() {
return hostConfig.getMemorySwap();
}

@Deprecated
@Override
public CreateContainerCmd withMemorySwap(Long memorySwap) {
checkNotNull(memorySwap, "memorySwap was not specified");
hostConfig.withMemorySwap(memorySwap);
return this;
}


@Override
public String getName() {
return name;
Expand Down

0 comments on commit 5c3ba9a

Please sign in to comment.