question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Exception while trying to use Logs.fetch() with docker 18.09

See original GitHub issue

Using release 0.0.6 in a container, with docker 18.09, fails whenever trying to use the logs().fetch() method for another container with the following exception:

com.amihaiemil.docker.UnexpectedResponseException: Expected status 200 but got 400 when calling unix://localhost:80/v1.35/containers/a589995677a2511cd8db4a72e79e04d1b33467f27cf951896f3129f22dca88c4/logs. Response body was {"message":"Bad parameters: you must choose at least one stream"}
        at com.amihaiemil.docker.MatchStatus.handleResponse(MatchStatus.java:66)
        at com.amihaiemil.docker.MatchStatus.handleResponse(MatchStatus.java:39)
        at com.amihaiemil.docker.ReadString.handleResponse(ReadString.java:57)
        at com.amihaiemil.docker.ReadString.handleResponse(ReadString.java:39)
        at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:223)
        at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:165)
        at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:140)
        at com.amihaiemil.docker.HttpClientEnvelope.execute(HttpClientEnvelope.java:103)
        at com.amihaiemil.docker.RtLogs.fetch(RtLogs.java:84)
[...]

From what I understood from “Bad parameters: you must choose at least one stream”, it looks like it’s necessary to specify if its stdout or stderr since both, by default, are false.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:13 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
nmaguiarcommented, Jan 3, 2019

@amihaiemil, Thank you a lot 😃 Just tested 0.0.7 and it solved my problem.

0reactions
0cratcommented, Jan 3, 2019

Order was finished: +35 point(s) just awarded to @amihaiemil/z

Read more comments on GitHub >

github_iconTop Results From Across the Web

Overview | Docker Documentation
This page contains information on: How to diagnose and troubleshoot Docker Desktop issues; Check the logs; Find workarounds for common problems ...
Read more >
Docker in Docker 19.03 service fails (#4501) · Issues - GitLab
In 19.03+, this behavior is enabled by default. This means that when the service starts it will try and create the certificates, which...
Read more >
Docker-compose up : Error while fetching server API version ...
What worked for me: resetting the docker, navigate to my projectfolder and do docker-compose up again. – blackSwan566. Jan 9, 2021 at 11:58....
Read more >
How To Install and Use Docker on Ubuntu 22.04 - DigitalOcean
Log in with docker login and repeat the push attempt. Then verify that it exists on your Docker Hub repository page. You can...
Read more >
Tutoriel Docker - Read the Docs
22.1.1.1 Jeudi 8 novembre 2018 : sortie de Docker 18.09 . ... If you want to force Compose to stop and recreate all...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found