[This is preliminary documentation and is subject to change.]
Indicates that server instance should not be lock()-ed by Glue handler because it is implemented in a thread-safe way.
This attribute has no effect for Glue servers that are not [LifeCycle(Stateful)], because they are never locked.
Singleton servers must be thread-safe by definition so this attribute is not needed for Singleton servers.
If the server is implemented in a thread-safe way, then addition of this attribute may give 15-30% performance boost
from Glue runtime when many parallel requests are trying to work with the same instance, however this benefit
may be nullified by inefficient user locking code within server implementation. Leaving this attribute out is safer
System Object
System Attribute NFX.Glue ThreadSafeAttributeNamespace: NFX.GlueAssembly: NFX (in NFX.dll) Version: 3.0.0.1 (3.0.0.1)
[AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple = false, Inherited = false)]
public class ThreadSafeAttribute : Attribute
[AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple = false, Inherited = false)]
public class ThreadSafeAttribute : Attribute
<AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple := false, Inherited := false)>
Public Class ThreadSafeAttribute
Inherits Attribute
<AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple := false, Inherited := false)>
Public Class ThreadSafeAttribute
Inherits Attribute
[AttributeUsageAttribute(AttributeTargets::Class, AllowMultiple = false, Inherited = false)]
public ref class ThreadSafeAttribute : public Attribute
[AttributeUsageAttribute(AttributeTargets::Class, AllowMultiple = false, Inherited = false)]
public ref class ThreadSafeAttribute : public Attribute
[<AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple = false, Inherited = false)>]
type ThreadSafeAttribute =
class
inherit Attribute
end
[<AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple = false, Inherited = false)>]
type ThreadSafeAttribute =
class
inherit Attribute
end