This project is read-only.

Thread Safety

Nov 2, 2011 at 2:44 AM

I've been reading some of the v2.1 code, and it seems to me that the service is basically not threadsafe at all. Is that reasonably accurate, or am I missing something here? 

In particular, I'm looking at the TemplateService.Run<T>(T model, string name)  method. It looks to me like nearly anything could potentially get mixed up there. Since the Service and Model are set as properties on the ITemplate object, they could really be anything when the Execute() method actually runs, so the caller could get back nearly anything. 

Am I reading this correctly? 

Nov 7, 2011 at 10:32 AM


To be honest, it's not worth looking at the thread safety of v2.1. It has been completely redesigned for v3 ( I'm hoping to push this out the door by the end of the week.