ThinkGeo.com    |     Blog    |     Wiki    |     Support

WMS Server Image Caching

hi Ethan,

Regarding your Item #1 – As I stated in my previous post the tiles get deleted even though ReadOnly is specified.

Regarding your Item #3 – The code I previously posted is the only code for caching that my application has. I am totally convinced there is an issue in MapSuite with not properly setting Creation Date as I have explained previously.

At first opportunity I will download the latest WMS Server build and test.

Please let me know what your developer finds after doing deeper research.

Regards,
Dennis

Hi Dennis,

Any update I will let you know.

Regards,

Ethan

Hi Dennis,

Our developer did further research, we double check the logic and build sample try to reproduce it about the ExpirationTime don’t works after the first time. It looks everything goes well, so we think that’s maybe related with your other code implementation.

WmsSample.zip (511.4 KB)

If you have more information about it please let us know.

Regards,

Ethan

hi Ethan,

The code that I previously posted is the only code I have for caching. Is this code correct? It’s the same code that’s in the example project you provided.

Are your tests under Windows 7 or Windows 10? I develop under Windows 10.

I am 100% certain this is not an issue within my application.

I will upgrade to the latest WMS Server deployment build and see if this bug has been fixed since version V9.0.0.856.

Regards,
Dennis
OriStar Mapping, Inc.

Hi Dennis,

We tested that in win10, and we test it with latest dll and the specified dll 9.0.0.856.

Do you think we missed anything? Have you tried to run our sample to see whether it also can reproduce this problem in your machine?

Regards,

Ethan

hi Ethan,

I’ve updated to WmsServerEdition V9.0.0.1096 and still have this issue.

I repeat - MapSuite is not updating the Creation Date on the cached images when those cached tiles are refreshed. This is the issue.

I have not yet tried to run your sample, but I will.

The only difference that I can see between your sample and my code is that your sample uses WmsOverlay where my application uses WmsRasterLayer.

Regards,
Dennis

Hi Dennis,

It looks the cache is in your transfer sever (WmsServiceEdition), and for this edition it should only contains the WmsRasterLayer but without the WmsOverlay.

Maybe we confuse something?

Regards,

Ethan

Ethan,

I was merely pointing out that your client example uses WmsOverlay whereas my client uses WmsRasterLayer as a possible problem area.

In my posts I have mentioned Creation Date not being updated upon tile refresh. Would you please respond concerning Creation Date?

I setup a test where tiles were cached for two different extents. The expiration time of five minutes then elapsed. I then used Windows Explorer to manually delete the cached tiles on one of the extents. I then positioned the map client to said extent and the tiles were refreshed with the current date as the Creation Date.

When MapSuite does a tile refresh, on an existing set of tiles, the Accessed & Modified dates are updated correctly, but the Creation Date stays as the original date. Please speak to the fact that MapSuite, upon tile cache delete & refresh, does not update the Creation Date.

I just did some research and found this article.

Based on this article it would seem to me that MapSuite needs to be specifically setting the Creation Date after a tile refresh. Or, as previously suggested, use Modified Date to determine expiration/refresh interval.

Here’s what Microsoft has to say about replacing files…
https://msdn.microsoft.com/en-us/library/system.io.file.setcreationtime(v=vs.110).aspx

Your thoughts?

Regards,
Dennis
OriStar Mapping, Inc.

Hi Dennis,

Thanks for your thinking.

I read the topic and find some related topic for example: https://blogs.msdn.microsoft.com/oldnewthing/20050715-14/?p=34923

And I think we hadn’t reproduced it is because the OS version reason.

Our developer discuss about the solution and decide to modified the logic to check the modify time of tile image, please get that when NuGet update the package: https://www.nuget.org/packages/ThinkGeo.MapSuite/11.0.0-beta069

Please let us know whether it solved this problem in your end.

Regards,

Ethan

Ethan,

I’m using WmsServerEdition V9.0.0.1096. How does nuget work with V9? I had expected to download a new V9 using V9 Product Center.

Dennis

Hi Dennis,

Please latest package which will be updated today or tomorrow.

And let us know whether it works for you.

Regards

Ethan

hi Ethan,

My application is now compiled with WmsServerEdition V9.0.0.1103 and cache expiration/refresh is now working.

Thanks for your support!

Dennis
OriStar Mapping, Inc.

Hi Dennis,

Thanks for your update.

Any question please let us know.

Regards,

Ethan

hi Ethan,

I’ve just upgraded to ThinkGeo.MapSuite.WmsServer V11.0.0-beta002 and this issue has resurfaced.

You’ll see in this discussion thread that MapSuite repaired this issue in WmsServerEdition V9.0.0.1103.

You’ll recall the original issue was that after the timeout period (5 minutes) the issue was present. With WmsServer the issue occurs all the time (inside and outside the 5 minute timeout window).

Please let me know what you find.

Regards,
Dennis

Hi Dennis,

Last time we modify that is not in the WmsServerEdition package, it’s modified in the ThinkGeo.MapSuite package.

So please make sure your package version is higher than ThinkGeo.MapSuite 11.0.0-beta069.

For make sure that, I double check the lastest code of development and release version, both of them contains the fixed logic.

Regards,

Ethan

hi Ethan,

My applications are using the following:
V11.0.0-beta107 ThinkGeo.MapSuite
V11.0.0-beta002 ThinkGeo.MapSuite.WmsServer

My post from yesterday->

You’ll recall the original issue was that after the timeout period (5 minutes) the issue was present. With WmsServer the issue occurs all the time (inside and outside the 5 minute timeout window).

Please check the MapSuite code again because the symptoms this time seem to be different.

Thanks,
Dennis

Hi Dennis,

Yes it’s a bug in MapSuite 10, in our PCL structure, it don’t return the UTC time but the cache logic used UTC time, so the cache tile expiration function don’t works correct.

Our developer had fixed that, please get https://www.nuget.org/packages/ThinkGeo.MapSuite/11.0.0-beta108 when it’s available and let us know whether it works for you.

Regards,

Ethan

hi Ethan,

V11.0.0-beta108 is not yet available on NuGet. Once there I’ll download and install.

Thanks very much,
Dennis

hi Ethan,

I’ve upgraded to ThinkGeo.MapSuite.dll V11.0.0-beta108 and now the caching expiration is working properly.

Thanks for the addressing the issue.

Dennis

Hi Dennis,

I am glad to hear that works.

Regards,

Ethan