laptop and a wrench

Bogue

Web Map Service (WMS) GetMap requests are sent as POST with an invalid encoded body when the GetMap requests' URL exceeds the configured maxUrlLength of @arcgis/core/config.

Dernière publication: May 8, 2022 ArcGIS API for JavaScript
Numéro d’ID de bogue BUG-000147618
EnvoiMarch 15, 2022
Dernière modificationJune 5, 2024
S’applique àArcGIS API for JavaScript
Version trouvée4.22
Système d’exploitationWindows OS
Version du système d’exploitation10.0 64 Bit
StatutWill Not Be Addressed

Informations supplémentaires

The Web Map Service (WMS) spec never standardized XML encoding for the post body, so GetMap requests as XML is not supported when sent as POST since the XML may be different for each server. Regarding always sending GetMap requests as GET, we decided against that as well, since we do not want to break existing layers where the server responds correctly. As an alternative, this request interceptor always makes a GET request: esriConfig.request.interceptors.push({ urls: "https://host/path", async before(params) { if (params.requestOptions.responseType === "image") { const url = new URL(params.url); url.search = new URLSearchParams([ ...Array.from(url.searchParams.entries()), ...Object.entries(params.requestOptions.query || {}) ]).toString(); const img = new Image() img.crossOrigin = "anonymous"; img.src = url.href; await img.decode() return img; } } });

Étapes pour reproduire

ID de bogue: BUG-000147618

Logiciel:

  • ArcGIS API for JavaScript

Recevoir une notification lorsque le statut d’un bogue change

Télécharger l’application Esri Support

En savoir plus sur ce sujet

Obtenir de l’aide auprès des experts ArcGIS

Contacter le support technique

Télécharger l’application Esri Support

Accéder aux options de téléchargement