<?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: AGOL/Portal mapservice is returning incorrect renderer for some featurelayers, with JS API. in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/agol-portal-mapservice-is-returning-incorrect/m-p/1540302#M85712</link>
    <description>&lt;P&gt;I think I have seen this issue before and it's not strictly speaking an error, but it can be some unexpected behavior. It is possible for a MapServer and the FeatureLayers inside it to have two different symbologies. Go to the REST page of the MapServer and click All Layers and Tables.&amp;nbsp;This is the symbology you should see loading the MapServer as a MapImageLayer.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JeffreyThompson2_0-1726748886416.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/115426iA38D8B769AC2F088/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JeffreyThompson2_0-1726748886416.png" alt="JeffreyThompson2_0-1726748886416.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Now, go to the REST page of the FeatureLayer you are trying to load (.../MapServer/5). This is the symbology you will see if you load it as an individual FeatureLayer. Do they match?&lt;/P&gt;&lt;P&gt;You should see this same behavior in the MapViewer if you load the layers by the different urls. .../MapServer vs. .../MapServer/5&lt;/P&gt;</description>
    <pubDate>Thu, 19 Sep 2024 12:32:11 GMT</pubDate>
    <dc:creator>JeffreyThompson2</dc:creator>
    <dc:date>2024-09-19T12:32:11Z</dc:date>
    <item>
      <title>AGOL/Portal mapservice is returning incorrect renderer for some featurelayers, with JS API.</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/agol-portal-mapservice-is-returning-incorrect/m-p/1540212#M85710</link>
      <description>&lt;P&gt;From within a ExperienceBuilder 1.14 custom widget, using JS API&amp;nbsp; 4.x, i am loading featurelayers from an internal mapservice.&amp;nbsp; Using "new FeatureLayer(...)", etc.&lt;/P&gt;&lt;P&gt;The issue is that the some of the featurelayers are showing an incorrect renderer.&amp;nbsp; When i manually query the featurelayer via REST, in the json results i see that the renderer that the mapservice is sending me is the same incorrect renderer that JS API is displaying.&lt;/P&gt;&lt;P&gt;However, when i display that mapservice with ArcGIS Online Map Viewer, MapViewer is displaying the correct renderer!&amp;nbsp; So how is it that MapViewer somehow magically gets the correct renderer, but the mapservice refuses to provide it to anyone else?&lt;/P&gt;&lt;P&gt;I'm thinking that ESRI MapServer and/or JS API has a bug here, and MapViewer is somehow working around that ESRI bug using secret undocumented functionality.&lt;/P&gt;&lt;P&gt;Has anyone else run across this sort of issue?&lt;/P&gt;&lt;P&gt;Typically the problem shows up with line/polygon symbology where there's a lighter fill combined with a darker border.&amp;nbsp; The incorrect renderer has only a SimplerRenderer with esriSLSSolid of the dark border color instead.&amp;nbsp; Massively ugly and unreadable on the map.&lt;/P&gt;&lt;P&gt;Unfortunately, due to the internal data and internal app, i can't provide a reproduceable example here.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Sep 2024 00:02:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/agol-portal-mapservice-is-returning-incorrect/m-p/1540212#M85710</guid>
      <dc:creator>EmoryHorvath</dc:creator>
      <dc:date>2024-09-19T00:02:48Z</dc:date>
    </item>
    <item>
      <title>Re: AGOL/Portal mapservice is returning incorrect renderer for some featurelayers, with JS API.</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/agol-portal-mapservice-is-returning-incorrect/m-p/1540302#M85712</link>
      <description>&lt;P&gt;I think I have seen this issue before and it's not strictly speaking an error, but it can be some unexpected behavior. It is possible for a MapServer and the FeatureLayers inside it to have two different symbologies. Go to the REST page of the MapServer and click All Layers and Tables.&amp;nbsp;This is the symbology you should see loading the MapServer as a MapImageLayer.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="JeffreyThompson2_0-1726748886416.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/115426iA38D8B769AC2F088/image-size/medium?v=v2&amp;amp;px=400" role="button" title="JeffreyThompson2_0-1726748886416.png" alt="JeffreyThompson2_0-1726748886416.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Now, go to the REST page of the FeatureLayer you are trying to load (.../MapServer/5). This is the symbology you will see if you load it as an individual FeatureLayer. Do they match?&lt;/P&gt;&lt;P&gt;You should see this same behavior in the MapViewer if you load the layers by the different urls. .../MapServer vs. .../MapServer/5&lt;/P&gt;</description>
      <pubDate>Thu, 19 Sep 2024 12:32:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/agol-portal-mapservice-is-returning-incorrect/m-p/1540302#M85712</guid>
      <dc:creator>JeffreyThompson2</dc:creator>
      <dc:date>2024-09-19T12:32:11Z</dc:date>
    </item>
    <item>
      <title>Re: AGOL/Portal mapservice is returning incorrect renderer for some featurelayers, with JS API.</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/agol-portal-mapservice-is-returning-incorrect/m-p/1540581#M85715</link>
      <description>&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;Yes, i've seen that sort of thing before with MapServer, but this time the MapService level (All Layers) still shows the same incorrect renderer.&amp;nbsp; Bleah.&amp;nbsp; But yet, MapViewer somehow magically grabs the correct renderer notwithstanding.&lt;/P&gt;&lt;P&gt;But it just occurred to me that i can launch MapViewer and monitor the network requests/responses, and maybe see what magic MapViewer is doing, you know that secret "UseCorrectRenderer=Yes" flag it's passing in...&lt;/P&gt;&lt;P&gt;If i can find anything useful amidst all the network noise!&lt;/P&gt;&lt;P&gt;Later: Hmm, If you can believe it, MapViewer seems to actually have MapServer render the layer on the server and pass it down as an image:&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;"...&lt;SPAN&gt;MapServer/export?bbox=-13626505.46942316%2C6047143.17598199%2C-13610186.163884297%2C6058838.041309605&amp;amp;bboxSR=102100&amp;amp;imageSR=102100&amp;amp;size=1708%2C1224&amp;amp;dpi=96&amp;amp;format=png32&amp;amp;transparent=true&amp;amp;layers=show%3A-1&amp;amp;f=image"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Well that's not very helpful of MapViewer.&amp;nbsp; It's cheating!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 19 Sep 2024 19:21:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/agol-portal-mapservice-is-returning-incorrect/m-p/1540581#M85715</guid>
      <dc:creator>EmoryHorvath</dc:creator>
      <dc:date>2024-09-19T19:21:55Z</dc:date>
    </item>
  </channel>
</rss>

