开发者

wcf and pathfinding

开发者 https://www.devze.com 2023-01-21 12:02 出处:网络
Generally I would never expect to see those 2 words together in the same sentenc, however im working on a project that requires me to do simple pathfinding on multiple roads and I\'m just trying to wo

Generally I would never expect to see those 2 words together in the same sentenc, however im working on a project that requires me to do simple pathfinding on multiple roads and I'm just trying to work out the best way to do it.

I was originally thinking of having a few wcf services that could accept an origin and destinations do the work there and send back results. However the data is all in a db, so ideally I need all the routes 开发者_如何学运维in memory or it would be dog slow, can I do that?


If you use a service configured with the single instance mode [ServiceContract(InstanceContextMode = Single)], you can store data in regular attributes and they will stay in memory as long as the host permits (if stored in IIS, as long as the AppPool is not recycled).

0

精彩评论

暂无评论...
验证码 换一张
取 消