<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: The proxy server received an invalid response from an upstream server (.NET CORE) in Discuss Dropbox Developer &amp; API</title>
    <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/The-proxy-server-received-an-invalid-response-from-an-upstream/m-p/468773#M1571</link>
    <description>&lt;P&gt;I see you also opened a support ticket for this, so we'll follow up with you there.&lt;/P&gt;</description>
    <pubDate>Tue, 10 Nov 2020 19:43:48 GMT</pubDate>
    <dc:creator>Greg-DB</dc:creator>
    <dc:date>2020-11-10T19:43:48Z</dc:date>
    <item>
      <title>The proxy server received an invalid response from an upstream server (.NET CORE)</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/The-proxy-server-received-an-invalid-response-from-an-upstream/m-p/468689#M1570</link>
      <description>&lt;P&gt;Dears, I am uploading files (large files) and when it is ends, this error appear (azure and linux):&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Proxy Error&lt;/P&gt;
&lt;P&gt;The proxy server received an invalid response from an upstream server.&lt;BR /&gt;The proxy server could not handle the request&lt;/P&gt;
&lt;P&gt;Reason:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;Error reading from remote server&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am using&amp;nbsp;ChunkUpload, follow:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;using (var stream = armazenaDropBox.Imagem.OpenReadStream())
                    {
                        int numChunks = (int)Math.Ceiling((double)stream.Length / chunkSize);

                        byte[] buffer = new byte[chunkSize];
                        string sessionId = null;

                        //armazenaDropBox.progressBar = 0;

                        for (var idx = 0; idx &amp;lt; numChunks; idx++)
                        {
                            //Console.WriteLine("Start uploading chunk {0}", idx);
                            var byteRead = stream.Read(buffer, 0, chunkSize);

                            using (MemoryStream memStream = new MemoryStream(buffer, 0, byteRead))
                            {
                                if (idx == 0)
                                {
                                    var result = await dba.Files.UploadSessionStartAsync(body: memStream);
                                    sessionId = result.SessionId;
                                }

                                else
                                {
                                    UploadSessionCursor cursor = new UploadSessionCursor(sessionId, (ulong)(chunkSize * idx));

                                    if (idx == numChunks - 1)
                                    {
                                        await dba.Files.UploadSessionFinishAsync(cursor, new CommitInfo(armazenaDropBox.Folder + "/" + armazenaDropBox.FileName), memStream);
                                    }

                                    else
                                    {
                                        await dba.Files.UploadSessionAppendV2Async(cursor, body: memStream);
                                    }
                                }
                            }

                            //armazenaDropBox.progressBar = 100;

                        }&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The upload is working perfectlly, but appear it.&lt;/P&gt;</description>
      <pubDate>Thu, 12 Nov 2020 06:15:36 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/The-proxy-server-received-an-invalid-response-from-an-upstream/m-p/468689#M1570</guid>
      <dc:creator>silasas</dc:creator>
      <dc:date>2020-11-12T06:15:36Z</dc:date>
    </item>
    <item>
      <title>Re: The proxy server received an invalid response from an upstream server (.NET CORE)</title>
      <link>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/The-proxy-server-received-an-invalid-response-from-an-upstream/m-p/468773#M1571</link>
      <description>&lt;P&gt;I see you also opened a support ticket for this, so we'll follow up with you there.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Nov 2020 19:43:48 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Discuss-Dropbox-Developer-API/The-proxy-server-received-an-invalid-response-from-an-upstream/m-p/468773#M1571</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2020-11-10T19:43:48Z</dc:date>
    </item>
  </channel>
</rss>

