DotNet Proxy Configuration - Feature service not showing up

5716
6
08-11-2015 01:15 PM
AdrianaPaese
Occasional Contributor

Hello

I have downloaded DotNet Proxy from Github, installed it on server with "Application pool"  4.5

Tested it with the ping command and it is set up ok

I am trying to make secure ArcGIS Server services available to end users without having them use login and passwords

I have added the following lines to the JS code:

  urlUtils.addProxyRule({

  urlPrefix: "http://myserver/arcgis/rest/services/MyService/FeatureServer/0",

  proxyUrl: "http://myserver/proxy/proxy.ashx"

  });

                       

  urlUtils.addProxyRule({

  urlPrefix: "http://myserver/arcgis/rest/services/MyService/FeatureServer/1",

  proxyUrl: "http://myserver/proxy/proxy.ashx"

  });

one fore each secured service in the JS app

and the following lines in the proxy.conf file:

  <serverUrl url="http://myserver/arcgis/rest/services/MyService/FeatureServer/0" username="username" password="password"

                   matchAll="true"/>

  <serverUrl url="http://myserver/arcgis/rest/services/MyService/FeatureServer/1" username="username" password="password"

                   matchAll="true"/>

                  

                  

                   These two steps have prevented the authentication window from showing up when the application is open. However, the feature service is not showing up either.

                  

                   Could anyone help me with an idea of what is happening?

                  

                   Thank you so much

                   Adriana

0 Kudos
6 Replies
JavierDelgadillo
Esri Contributor

How are you trying to use the .NET proxy in relation to GeoEvent.

0 Kudos
sapnas
by
Occasional Contributor III

Have you tried using https  instead of http in ServerUrl section of proxy.config file

0 Kudos
AdrianaPaese
Occasional Contributor

Thank you so much Javier and Sapna

The problem was that the hostname was not set in the etc/hosts file

The problem now is that after installing the proxy I am able to see the secured feature service in my app without authentication but I am unable to edit it

Any hint?

Best wishes

0 Kudos
RJSunderman
Esri Regular Contributor

Hello Adriana -

Are you using a GeoEvent output -- either the Add a Feature output or the Update a Feature output -- to make edits to your feature service? If so, you can review the Debugging the Add a Feature / Update a Feature Output Connectors​ blog to see how to configure GeoEvent to log debug messages which should tell you something about the JSON being sent in the requests to Server and the responses returned from Server.

If you are not using GeoEvent and the application you are developing is making its own requests on a feature service's .../FeatureServer/0/addFeatures or .../FeatureServer/0/updateFeatures REST endpoint, you might want to ask your question on the Web AppBuilder for ArcGIS​​ forum. Someone there can provide you advice on developing your web application.

Hope this information helps -

RJ

0 Kudos
AdrianaPaese
Occasional Contributor

Hi RJ

I am not using GeoEvent or Web APPBuilder I have used the ArcGIS API for JavaScript to develop the application.

APP works works fine if services are not secure.

If they are secure, it still works well after authentication.

However, when I use the proxy, although I can still see the points layer  (which means the service is accessible),  I am not able to edit it (e.g. add another point to my points layer).

I have used the template picker widged. I am able to select the layer in the template picker, but when I click on the map to add a point it doesnt work after the proxy is set. I thought it was because editor tracking was enabled (which doesnt really make sense if we are using the proxy) but the service is not editable even after disabling the editor tracking.

May this be a proxy and JavaScript API combination problem?

Thank you so much

Adriana

0 Kudos
RJSunderman
Esri Regular Contributor

Hello Adriana -

I was assuming that you were using the Esri/geoevent-datastore-proxy. Is this true, or are you using the Esri/resource-proxy?

The former was developed specifically for GeoEvent users who are unable to adopt the latest release of GeoEvent. Specifically it provides token management for ArcGIS Server connections registered with GeoEvent as Data Stores. Users who must remain at the 10.2.2 or 10.3.0 release who need functionality built-in to the GeoEvent 10.3.1 release can find what they need by using the GeoEvent Data Store proxy.

If you're using the .NET version of the "resource-proxy" to enhance a web application, I don't think we'll be able to help; this forum is specific to the use of the ArcGIS GeoEvent Extension for Server.

If you're using the GeoEvent Data Store proxy, but are not using GeoEvent, that would be an unsupported configuration. Either way, the GeoEvent product team does not have the experience you are looking for.

I think you are correct that this may be a security, proxy, JavaScript API related problem. You might have better luck if you take your question to another forum. Perhaps:

Good Luck -

RJ

0 Kudos