<?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: Print Task - Execute URL Cancelled in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1111631#M75091</link>
    <description>&lt;P&gt;You can try providing a requestOptions object as the second arg of the execute command that sets the timeout to 0.&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-request.html#RequestOptions" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/api-reference/esri-request.html#RequestOptions&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 27 Oct 2021 14:23:50 GMT</pubDate>
    <dc:creator>ReneRubalcava</dc:creator>
    <dc:date>2021-10-27T14:23:50Z</dc:date>
    <item>
      <title>Print Task - Execute URL Cancelled</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1111629#M75090</link>
      <description>&lt;P&gt;Good Day&lt;BR /&gt;&lt;BR /&gt;I'm trying to print a large view of ~4600 segment, after pressing the print button, which executes the following function:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;printMap&lt;/SPAN&gt;() {&lt;BR /&gt;  &lt;SPAN&gt;try &lt;/SPAN&gt;{&lt;BR /&gt;    &lt;SPAN&gt;const &lt;/SPAN&gt;printTask = &lt;SPAN&gt;new &lt;/SPAN&gt;PrintTask()&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;    printTask.&lt;SPAN&gt;url &lt;/SPAN&gt;= &lt;SPAN&gt;'https://utility.arcgisonline.com/arcgis/rest/services/Utilities/PrintingTools/GPServer/Export%20Web%20Map%20Task'&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;    const &lt;/SPAN&gt;template = &lt;SPAN&gt;new &lt;/SPAN&gt;PrintTemplate({&lt;BR /&gt;      &lt;SPAN&gt;format&lt;/SPAN&gt;: &lt;SPAN&gt;'jpg'&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;      &lt;SPAN&gt;layout&lt;/SPAN&gt;: &lt;SPAN&gt;'a4-landscape'&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;    })&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;    const &lt;/SPAN&gt;params = &lt;SPAN&gt;new &lt;/SPAN&gt;PrintParameters({&lt;BR /&gt;      &lt;SPAN&gt;view&lt;/SPAN&gt;: &lt;SPAN&gt;this&lt;/SPAN&gt;.&lt;SPAN&gt;_view&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;BR /&gt;&lt;/SPAN&gt;      &lt;SPAN&gt;template&lt;/SPAN&gt;: template&lt;BR /&gt;    })&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;    this&lt;/SPAN&gt;.&lt;SPAN&gt;printProgress &lt;/SPAN&gt;= &lt;SPAN&gt;true;&lt;BR /&gt;&lt;/SPAN&gt;    printTask.&lt;SPAN&gt;execute&lt;/SPAN&gt;(params).&lt;SPAN&gt;then&lt;/SPAN&gt;((result) =&amp;gt; {&lt;BR /&gt;      &lt;SPAN&gt;this&lt;/SPAN&gt;.&lt;SPAN&gt;printProgress &lt;/SPAN&gt;= &lt;SPAN&gt;false;&lt;BR /&gt;&lt;/SPAN&gt;      &lt;SPAN&gt;window&lt;/SPAN&gt;.&lt;SPAN&gt;open&lt;/SPAN&gt;(result.&lt;SPAN&gt;url&lt;/SPAN&gt;)&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;    }&lt;SPAN&gt;, &lt;/SPAN&gt;(err) =&amp;gt; {&lt;BR /&gt;      &lt;SPAN&gt;this&lt;/SPAN&gt;.&lt;SPAN&gt;printProgress &lt;/SPAN&gt;= &lt;SPAN&gt;false;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;      this&lt;/SPAN&gt;.&lt;SPAN&gt;alert&lt;/SPAN&gt;.&lt;SPAN&gt;errorDialog&lt;/SPAN&gt;(&lt;SPAN&gt;'Print Error'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'Please try again or contact support!'&lt;/SPAN&gt;)&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;    })&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;  } &lt;SPAN&gt;catch &lt;/SPAN&gt;(error) {&lt;BR /&gt;    &lt;SPAN&gt;console&lt;/SPAN&gt;.&lt;SPAN&gt;log&lt;/SPAN&gt;(error)&lt;SPAN&gt;;&lt;BR /&gt;&lt;/SPAN&gt;  }&lt;BR /&gt;}&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;I get 'cancelled' in the network tab of the Dev Console:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AndrewMurdoch1_1-1635343724559.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/26286i96A6DCA5B7DF1B13/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AndrewMurdoch1_1-1635343724559.png" alt="AndrewMurdoch1_1-1635343724559.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I'm assuming this is a timeout issue, due to the amount of data being sent, is there a way to add a timeout override to the execute call?&amp;nbsp; Is there an upper limit to the amount of data you can push from a client side ArcGIS JS Map to the Print Service?&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Wed, 10 Nov 2021 18:17:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1111629#M75090</guid>
      <dc:creator>AndrewMurdoch1</dc:creator>
      <dc:date>2021-11-10T18:17:33Z</dc:date>
    </item>
    <item>
      <title>Re: Print Task - Execute URL Cancelled</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1111631#M75091</link>
      <description>&lt;P&gt;You can try providing a requestOptions object as the second arg of the execute command that sets the timeout to 0.&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-request.html#RequestOptions" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/api-reference/esri-request.html#RequestOptions&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 27 Oct 2021 14:23:50 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1111631#M75091</guid>
      <dc:creator>ReneRubalcava</dc:creator>
      <dc:date>2021-10-27T14:23:50Z</dc:date>
    </item>
    <item>
      <title>Re: Print Task - Execute URL Cancelled</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1111632#M75092</link>
      <description>&lt;P&gt;Thanks!&amp;nbsp; I'll try that &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 27 Oct 2021 14:24:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1111632#M75092</guid>
      <dc:creator>AndrewMurdoch1</dc:creator>
      <dc:date>2021-10-27T14:24:55Z</dc:date>
    </item>
    <item>
      <title>Re: Print Task - Execute URL Cancelled</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1111658#M75094</link>
      <description>&lt;P&gt;After changing the timeout to 0, I'm no longer getting the cancelled request, but I'm getting lots of 500 / 504 errors.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AndrewMurdoch1_1-1635346863242.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/26291i2814D54FD31E2B12/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AndrewMurdoch1_1-1635346863242.png" alt="AndrewMurdoch1_1-1635346863242.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;The 200 at the top had a 500 response inside it:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AndrewMurdoch1_2-1635346925369.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/26292iE891D1B3DD2FA20D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AndrewMurdoch1_2-1635346925369.png" alt="AndrewMurdoch1_2-1635346925369.png" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;I ran the same test several more times, and was able to get a response, and the only different I can see is that the successful one took 1.9 minutes, and all the failures took 1.0 minutes or 2.0+ minutes.&lt;/P&gt;&lt;P&gt;This is the capture of the other responses, the top 200 was actually successful, the second was had a 500 response code it:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AndrewMurdoch1_3-1635347058456.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/26293iB0A1D58434CB1415/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AndrewMurdoch1_3-1635347058456.png" alt="AndrewMurdoch1_3-1635347058456.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 27 Oct 2021 15:04:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1111658#M75094</guid>
      <dc:creator>AndrewMurdoch1</dc:creator>
      <dc:date>2021-10-27T15:04:27Z</dc:date>
    </item>
    <item>
      <title>Re: Print Task - Execute URL Cancelled</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1112843#M75137</link>
      <description>&lt;P&gt;Has anyone seen this kind of behaviour?&lt;/P&gt;</description>
      <pubDate>Mon, 01 Nov 2021 14:10:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/print-task-execute-url-cancelled/m-p/1112843#M75137</guid>
      <dc:creator>AndrewMurdoch1</dc:creator>
      <dc:date>2021-11-01T14:10:56Z</dc:date>
    </item>
  </channel>
</rss>

