{"action":"created","issue":{"url":"https://api.github.com/repos/cloudfoundry/cloud_controller_ng/issues/828","repository_url":"https://api.github.com/repos/cloudfoundry/cloud_controller_ng","labels_url":"https://api.github.com/repos/cloudfoundry/cloud_controller_ng/issues/828/labels{/name}","comments_url":"https://api.github.com/repos/cloudfoundry/cloud_controller_ng/issues/828/comments","events_url":"https://api.github.com/repos/cloudfoundry/cloud_controller_ng/issues/828/events","html_url":"https://github.com/cloudfoundry/cloud_controller_ng/issues/828","id":233906334,"number":828,"title":"Missing chunk delimiter on GET /v3/apps","user":{"login":"nicregez","id":5437832,"avatar_url":"https://avatars1.githubusercontent.com/u/5437832?v=3","gravatar_id":"","url":"https://api.github.com/users/nicregez","html_url":"https://github.com/nicregez","followers_url":"https://api.github.com/users/nicregez/followers","following_url":"https://api.github.com/users/nicregez/following{/other_user}","gists_url":"https://api.github.com/users/nicregez/gists{/gist_id}","starred_url":"https://api.github.com/users/nicregez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicregez/subscriptions","organizations_url":"https://api.github.com/users/nicregez/orgs","repos_url":"https://api.github.com/users/nicregez/repos","events_url":"https://api.github.com/users/nicregez/events{/privacy}","received_events_url":"https://api.github.com/users/nicregez/received_events","type":"User","site_admin":false},"labels":[{"id":240264792,"url":"https://api.github.com/repos/cloudfoundry/cloud_controller_ng/labels/unscheduled","name":"unscheduled","color":"D9D9D9","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2017-06-06T14:14:42Z","updated_at":"2017-06-08T05:27:07Z","closed_at":"2017-06-08T05:27:07Z","body":"## Issue\r\n\r\nResponses to `GET /v3/apps` sometimes have a response header `Transfer-Encoding: chunked` even if the payload is not chunked.\r\n\r\n## Context\r\n\r\nWhen the response payload is smaller in size than the chunk size, the content is not chunked, but still the response header `Transfer-Encoding: chunked` is set by the server. This causes typical clients to report an error like `Error reading response: invalid byte in chunk length`. If the response payload is bigger than the chunk size, chunking is applied properly and everything works fine.\r\n\r\n## Steps to Reproduce\r\n\r\nIssue is reproducible on both `3.0.0` and `3.15.0`.\r\nUse the CLI 2.26 (cf version 6.26.0+9c9a261fd.2017-04-06).\r\nUse the command `cf curl`\r\n\r\n1. No issue: `GET /v3/apps`.\r\n1. No issue: `GET /v3/apps?names=doesnotexist` (where there is no app named 'doesnotexist')\r\n1. Issue: `GET /v3/apps?names=myapp` (where there actually is an app named 'myapp')\r\n\r\n## Expected result\r\n\r\nResponse can be consumed by any compliant http REST client\r\n\r\n## Current result\r\n\r\nResponse cannot be consumed by any compliant http REST client. See above under 'Steps to Reproduce'\r\n\r\n## Possible Fix\r\n\r\nOn small payloads, either set the response header `Content-Length` or do proper chunk encoding.\r\n\r\n## `name of issue` screenshot\r\n\r\n[if relevant, include a screenshot]\r\n"},"comment":{"url":"https://api.github.com/repos/cloudfoundry/cloud_controller_ng/issues/comments/307002166","html_url":"https://github.com/cloudfoundry/cloud_controller_ng/issues/828#issuecomment-307002166","issue_url":"https://api.github.com/repos/cloudfoundry/cloud_controller_ng/issues/828","id":307002166,"user":{"login":"nicregez","id":5437832,"avatar_url":"https://avatars1.githubusercontent.com/u/5437832?v=3","gravatar_id":"","url":"https://api.github.com/users/nicregez","html_url":"https://github.com/nicregez","followers_url":"https://api.github.com/users/nicregez/followers","following_url":"https://api.github.com/users/nicregez/following{/other_user}","gists_url":"https://api.github.com/users/nicregez/gists{/gist_id}","starred_url":"https://api.github.com/users/nicregez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicregez/subscriptions","organizations_url":"https://api.github.com/users/nicregez/orgs","repos_url":"https://api.github.com/users/nicregez/repos","events_url":"https://api.github.com/users/nicregez/events{/privacy}","received_events_url":"https://api.github.com/users/nicregez/received_events","type":"User","site_admin":false},"created_at":"2017-06-08T05:27:07Z","updated_at":"2017-06-08T05:27:07Z","body":"This issue cannot be reproduced, I created it because I had an improper testing setup. My apologise for causing confusion."}}
{"actor":{"display_login":"nicregez"}}