I am using dynamic layer to load different data on map when we search. There are two ways to search:
1. by using country name
2. by using country as well as state name.
When we search using state and country name, then I am not having any issue. But when I search using just country name then I am getting "Error 500: Internal server error". I am using proxy for calling the arcgis services.
To set the new definition for layer:-
map.getLayer("Dealer Location").setLayerDefinitions(layerDefinitions);
Error:
- n {message: "Unable to load /aor/proxy.jsp?https://arcgisqualap…AOR/Dealer_Info_Lbl/MapServer/export? status: 500", response: Object, status: 500,responseText: "{"timestamp":1490685729634,"status":500,"error":"I…":"No message available","path":"/aor/proxy.jsp"}", xhr: XMLHttpRequest…}
- _ssl: undefined
- log: undefined
- message: "Unable to load /aor/proxy.jsp?https://XXXXXXXXXXXX.com/arcgis/rest/services/Dealer_AOR/Dealer_Info_Lbl/MapServer/export? status: 500"
- response: Object
- responseText: "{"timestamp":1490685729634,"status":500,"error":"Internal Server Error","message":"No message available","path":"/aor/proxy.jsp"}"
- stack: (...)
- get stack: ()
- arguments: null
- caller: null
- length: 0
- name: ""
- prototype: aZ
- __proto__: ()
- <function scope>
- set stack: ()
- status: 500
- xhr: XMLHttpRequest
- __proto__: a
So,when we are searching using "Country", then a huge amount of data comes in variable 'layerDefinitions' and I am getting the above issue where 'POST' call is failing. But if we change the data and reduce the the amount of data in 'layerDefinitions', then It is working fine and data is getting loaded on the map (same case as search using 'State+Country').
Earlier, we were not using proxy and there were no issues.
Can anybody please tell me what changes can I do or is there any other way to set the map layer definition for such a huge amount of data for layer definition?
Thanks in advance.