Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
docker-py
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
docker-py
Commits
d9e08aed
Kaydet (Commit)
d9e08aed
authored
Kas 09, 2018
tarafından
Joffrey F
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Disallow incompatible combination stats(decode=True, stream=False)
Signed-off-by:
Joffrey F
<
joffrey@docker.com
>
üst
ebfba8d4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
container.py
docker/api/container.py
+6
-1
containers.py
docker/models/containers.py
+2
-1
No files found.
docker/api/container.py
Dosyayı görüntüle @
d9e08aed
...
@@ -1071,7 +1071,8 @@ class ContainerApiMixin(object):
...
@@ -1071,7 +1071,8 @@ class ContainerApiMixin(object):
Args:
Args:
container (str): The container to stream statistics from
container (str): The container to stream statistics from
decode (bool): If set to true, stream will be decoded into dicts
decode (bool): If set to true, stream will be decoded into dicts
on the fly. False by default.
on the fly. Only applicable if ``stream`` is True.
False by default.
stream (bool): If set to false, only the current stats will be
stream (bool): If set to false, only the current stats will be
returned instead of a stream. True by default.
returned instead of a stream. True by default.
...
@@ -1085,6 +1086,10 @@ class ContainerApiMixin(object):
...
@@ -1085,6 +1086,10 @@ class ContainerApiMixin(object):
return
self
.
_stream_helper
(
self
.
_get
(
url
,
stream
=
True
),
return
self
.
_stream_helper
(
self
.
_get
(
url
,
stream
=
True
),
decode
=
decode
)
decode
=
decode
)
else
:
else
:
if
decode
:
raise
errors
.
InvalidArgument
(
"decode is only available in conjuction with stream=True"
)
return
self
.
_result
(
self
.
_get
(
url
,
params
=
{
'stream'
:
False
}),
return
self
.
_result
(
self
.
_get
(
url
,
params
=
{
'stream'
:
False
}),
json
=
True
)
json
=
True
)
...
...
docker/models/containers.py
Dosyayı görüntüle @
d9e08aed
...
@@ -385,7 +385,8 @@ class Container(Model):
...
@@ -385,7 +385,8 @@ class Container(Model):
Args:
Args:
decode (bool): If set to true, stream will be decoded into dicts
decode (bool): If set to true, stream will be decoded into dicts
on the fly. False by default.
on the fly. Only applicable if ``stream`` is True.
False by default.
stream (bool): If set to false, only the current stats will be
stream (bool): If set to false, only the current stats will be
returned instead of a stream. True by default.
returned instead of a stream. True by default.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment