IInstanceContextProvider.IsIdle(InstanceContext) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Called when all InstanceContext activities have completed to enable implementers to prevent the InstanceContext from being recycled.
public:
bool IsIdle(System::ServiceModel::InstanceContext ^ instanceContext);
public bool IsIdle (System.ServiceModel.InstanceContext instanceContext);
abstract member IsIdle : System.ServiceModel.InstanceContext -> bool
Public Function IsIdle (instanceContext As InstanceContext) As Boolean
Parameters
- instanceContext
- InstanceContext
The InstanceContext object that is considered idle.
Returns
true
if Windows Communication Foundation (WCF) is to close and recycle the InstanceContext object and adjust the value of MaxConcurrentInstances; otherwise, false
.
Remarks
IsIdle is called when WCF is about to close and recycle an idle InstanceContext object so that you can inform the runtime whether to continue doing so.
For an example that demonstrates the sharing of instance contexts, see InstanceContextSharing.
Applies to
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈