views:

15

answers:

1

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?

A: 

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).

Johann Blais