DeepEarthPrototype V1.1 Map not displayed

Feb 1, 2009 at 8:30 AM
Edited Feb 1, 2009 at 8:31 AM
I am getting the error when running the application.

The remote server returned an error: NotFound

At

public ImageryMetadataResponse EndGetImageryMetadata(IAsyncResult result)

            {

                var _args = new object[0];<o:p></o:p>

                var _result = ((ImageryMetadataResponse) (EndInvoke("GetImageryMetadata", _args, result)));

                return _result;

            }

Developer
Feb 1, 2009 at 10:00 AM
Edited Feb 1, 2009 at 10:01 AM
please read the posts on this thread, you have the same/similar issue

http://www.codeplex.com/deepearth/Thread/View.aspx?ThreadId=45682

Feb 1, 2009 at 2:34 PM
Edited Feb 1, 2009 at 3:23 PM
I did the steps as mentioned in the above thread
But I still get a error http://img87.imageshack.us/img87/6448/errorde1et6.png
Developer
Feb 1, 2009 at 4:18 PM
Edited Feb 1, 2009 at 4:18 PM
I just downloaded a copy of the DeepEarth Source Version 1.1

I add my VE dev account details Username/ID & Password into the web.config and run the prototype project and I get no errors, the maps load OK

you have got a VE web services dev account and you have added you Username/ID & Password into the web.config file..?
Note: your Username/ID is a number (mine is 6 digits long)

   31     <add key="VETokenUserName" value="{ Username/ID Here }"/>
   32     <add key="VETokenPassword" value="{ Password here }"/>
   33     <add key="VETokenServiceUrl" value="http://staging.common.virtualearth.net/find-30/common.asmx"/>
Feb 1, 2009 at 9:07 PM
I see the same error for the call to BeginGetImageryMetaData - the calls to GetToken that preceed this call work just fine and so BeginGetImageryMetaData is called but returns with an exception.  I am only seeing this error though on a machine that is on my CorpNet - I run the same example on two machines at home and it works just fine, so I'm wondering if the network folks are messing with me on the way out or back in, if anyone has any ideas on what I should look for please share.  This is using DeeepEarth v1.0 and the VEDeepEarthExample.

Thanks.
Coordinator
Feb 1, 2009 at 10:23 PM
I recommend you use the latest V1.1 if you can. You need to make sure that your pointing the Token service (ASP.NET site) and the VEWS WCF services (from the silverlight app) at the same thing, either production or staging.

These are set in the config in your silverlight project and the web.config in your ASP.NET site.

We have tried to make this work as best as possible so no longer use the trival wati for token before we serve your application technique from the SDK, instead we have the async token service to get the token when you need it.

To debug the control I highly recommend fiddler to see exactly what service (if any) is being hit and the actual HTTP error.

We have also put in logic to save a valid tileset info and your last working token to the Isolated storage. If you change between staging and production, right click on the application, silverlight settings and delete the storage for the application to refresh this. What we have done is to speed up startup and allow the control to work momentarily if your disconnected.
Feb 2, 2009 at 1:38 AM
Thanks for trying to help out here, it is appreciated.  I upgraded this machine to v1.1 and I get the same error as srinathk - here are the details

In the VEDeepEarth example

BeginGetImageryMetadata is calling

http://staging.dev.virtualearth.net/webservices/v1/imageryservice/imageryservice.svc

ImageryMetadataRequest is filled out with the token received from token service.  The call to BeginGetImageryMetadata results in the error

System.Net.WebException occurred
  Message="The remote server returned an error: NotFound"
  StackTrace:
       at System.Net.BrowserHttpWebRequest.InternalEndGetResponse(IAsyncResult asyncResult)
  InnerException:

Web.Config  (I verified username & password are correct by calling the common.asmx web service directly)

 <add key="VETokenUserName" value="xxxxxx"/>     // These are just numbers
 <add key="VETokenPassword" value="xxxxxxxxx"/>  // I am using correct username here
 <add key="VETokenServiceUrl" value="http://staging.common.virtualearth.net/find-30/common.asmx>

ServiceReference.Client.Config

<client>
      <endpoint address="http://localhost:52640/VEDeepEarthExampleWeb/Services/VETokenService.svc"
                binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_ITokenService"
                contract="TokenService.ITokenService" name="BasicHttpBinding_ITokenService" />
      <endpoint address="http://staging.dev.virtualearth.net/webservices/v1/geocodeservice/GeocodeService.svc"
          binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_IGeocodeService"
          contract="VEGeocodeService.IGeocodeService" name="BasicHttpBinding_IGeocodeService" />
      <endpoint address="http://staging.dev.virtualearth.net/webservices/v1/imageryservice/imageryservice.svc"
          binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_IImageryService"
          contract="VEImageryService.IImageryService" name="BasicHttpBinding_IImageryService" />
      <endpoint address="http://staging.dev.virtualearth.net/webservices/v1/routeservice/routeservice.svc"
          binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_IRouteService"
          contract="VERouteService.IRouteService" name="BasicHttpBinding_IRouteService" />
</client>

# Result Protocol Host URL Body Caching Content-Type Process User-defined 
0 200 HTTP www.fiddler2.com /fiddler2/updatecheck.asp?isBeta=False 520 private   text/plain fiddler:5140  
1 200 HTTP localhost:52640 /VEDeepEarthExampleWeb/ 2,877 private   text/html; charset=utf-8 iexplore:2332  
2 200 HTTP localhost:52640 /VEDeepEarthExampleWeb/ClientBin/VEDeepEarthExample.xap 118,447 private   application/octet-stream iexplore:2332  
3 200 HTTP localhost:52640 /VEDeepEarthExampleWeb/Services/VETokenService.svc 289 private   text/xml; charset=utf-8 iexplore:2332  
4 401 HTTP staging.common.virtualearth.net /find-30/common.asmx 0   webdev.webserver:3056  
5 200 HTTP staging.common.virtualearth.net /find-30/common.asmx 470 private, max-age=0   text/xml; charset=utf-8 webdev.webserver:3056  
6 304 HTTP staging.dev.virtualearth.net /clientaccesspolicy.xml 0   iexplore:2332  
7 200 HTTP staging.dev.virtualearth.net /webservices/v1/imageryservice/imageryservice.svc 744  text/xml; charset=utf-8 iexplore:2332  

 

Developer
Feb 2, 2009 at 3:39 AM
Just out of interest what are the servers that you guys are trying to run on...?  
as windows 2000 has IIS 5 and there are some issues with running WCF services there i think....

byteAlign, you are updating the VETokenService.svc endpoint address when you move it up to your "CorpNet"..?

Feb 2, 2009 at 1:29 PM
Thanks for your efforts to help here.

I am working with DeepEarth Source Version 1.1.
All the configuration settings are done as per the reqirements.

Executing the project in VS2008 with DeepEarthProtypeWeb as the startup project.

This error is displayed http://img87.imageshack.us/img87/6448/errorde1et6.png

Still the map is loaded.

I need to know when the MapLoaded or MapZoomEnded events are fired. Due to the error these events are not fired.
Feb 2, 2009 at 3:08 PM

To summarize:

Home machine:   Vista Ultimate IIS 7

VEDeepEarth (v1.1) example works fine, DeepEarthPrototypeWeb (v1.0) works just fine, DeepEarthPrototypeWeb (v1.1) does not work – IE crashes after CrossAppDomainMarshaledException, I debugged this some more, there is nothing on the main thread callstack – on a background thread it is in a wait state and on the stack is the call to System.Windows.dll!System.Net.BrowserHttpWebRequest.BeginGetResponse for the call to http://localhost:52638/DeepEarthPrototypeWeb/Services/VETokenService.svc

 

Work Machine: Windows XP2, SP 2, IIS 5.1

On my work machine VEDeepEarth &  DeepEarthPrototypeWeb  (v1.0) (v1.1) do not work, getting the token works fine, BeginGetImageryMetaData fails.  Regarding your question about updating the endpoints when I’m on the corpnet, yes the endpoints are correct, I’m not deploying this to any of our servers, still using my local dev box, but the difference between home vs. corpnet is that the work machine is behind company firewalls etc. so I’m going to talk to our network folks today to see if they are doing anything with outbound/inbound requests for this endpoint.  We do a lot of Silverlight + WCF development but usually the endpoints are to our own servers and we don’t see these kinds of issues.

Thanks

Feb 2, 2009 at 4:02 PM
For those that are getting the SOAP error "cannot handle request without a valid SOAP action parameter", I am 99.9% certain that in some way the outbound request is losing its SOAPAction HTTP header, maybe due to proxy'ing, firewalling or what have you. Without this header present, WCF services (and many other SOAP implementations) will just not work.

We run an HTTP request forwarder service that basically proxies HTTP GET and POST requests, and it failed when it did not replicate the SOAPAction header.

HTH,

Joost M.
Feb 2, 2009 at 6:46 PM
One of my problems is now solved.  I ran a network trace while running VEDeepEarth (v1.1) and while looking through it I noticed that GetImageryMetadata method returns its content using gzip compression.  IE 6 has some issues with gzip compression (see this link http://support.microsoft.com/default.aspx?scid=kb;en-us;Q312496) - so I upgraded my browser and presto everything works.  Now I just need to figure out what the CrossAppDomainMarshaledException is all about on my Vista machine and all will be well.

Thanks everyone for their thoughtful suggestions.  Almost there ...
Coordinator
Feb 2, 2009 at 10:10 PM
And thankyou byteAlign for posting back here, I can admit I've never tested with IE6 but will now and thanks to you will submit something back to MSFT if I can recreate. It doesn't sound like anything we can fix from our end.
The "CrossAppDomainMarshaledException" however is more alarming, hey any change your application is not running on http://localhost:52638  ? The service is part of the same web app that launched the silverlight application, the path has to be set to the same domain or else it will throw a CrossAppDomain error.
So the demo site for example I have to change this setting on deploy to http://deepearth.soulsolutions.com.au/Services/VETokenService.svc
Feb 9, 2009 at 7:38 PM
Hi

I'm experimenting with deploying a sample to my local IIS. Is there any way to set up VETokenService.svc so that all the service endpoints don't need to be edited manually?
I can only seem to get things to work by doing a currentproject edit, replacing all of the endpoint references as suggested by soulsolutions:
    http: //localhost:52638/DeepEarthPrototypeWeb/Services/VETokenService.svc
    http: //localhost:8084/Services/VETokenService.svc

Is there is a way to allow crossappdomain references so I don't have to make edits each time I want to test a deploy?

thanks
rkgeorge

P.S. Also I like the new DeepEarth Logo size. The previous version took up a lot of map space.
Developer
Feb 10, 2009 at 5:13 PM
Simple patch/hack to allow Dynamic Token Service Binding 
e.g. so you do not need to update the Url & Port number when you deploy the DeepEarth Control in a site with different port number for testing etc.

The Zip contains two files, they need to be included into the "DeepEarth.Provider.VirtualEarth" project

Replace the "Token.cs" with the new one from zip
Add new file "DynamicTokenServiceBinding.cs" to the project from zip

Patch files were made/tested on change set "18360"


I tried to add it as a Patch, but could not get it to upload so I added it as a Task in the Issue Tracker, at the link below you can download the Zip with the two files mentioned above
code is very simple and easy to see how it works with comments in the Token.cs file to see what I added

http://www.codeplex.com/deepearth/WorkItem/View.aspx?WorkItemId=3797
Feb 12, 2009 at 7:59 PM

Hi dotnetnoobie,

                Thanks that works for me on DeepEarth-18287.

rkgeorge

From: dotnetnoobie [mailto:notifications@codeplex.com]
Sent: Tuesday, February 10, 2009 10:14 AM
To: rkgeorge@cadmaps.com
Subject: Re: DeepEarthPrototype V1.1 Map not displayed [deepearth:45831]

From: dotnetnoobie

Simple patch/hack to allow Dynamic Token Service Binding
e.g. so you do not need to update the Url & Port number when you deploy the DeepEarth Control in a site with different port number for testing etc.

The Zip contains two files, they need to be included into the "DeepEarth.Provider.VirtualEarth" project

Replace the "Token.cs" with the new one from zip
Add new file "DynamicTokenServiceBinding.cs" to the project from zip

Patch files were made/tested on change set "18360"

I tried to add it as a Patch, but could not get it to upload so I added it as a Task in the Issue Tracker, at the link below you can download the Zip with the two files mentioned above

code is very simple and easy to see how it works with comments in the Token.cs file to see what I added

http://www.codeplex.com/deepearth/WorkItem/View.aspx?WorkItemId=3797

Read the full discussion online.

To add a post to this discussion, reply to this email (deepearth@discussions.codeplex.com)

To start a new discussion for this project, email deepearth@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com