你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

StatePersistenceAttribute 类

定义

指示执行组件状态应是可变的, (内存中仅) 、持久化还是根本不存储。 提供给此属性的存储类型必须与执行组件服务中使用的状态提供程序的类型匹配。

[System.AttributeUsage(System.AttributeTargets.Class, Inherited=false)]
public sealed class StatePersistenceAttribute : Attribute
[<System.AttributeUsage(System.AttributeTargets.Class, Inherited=false)>]
type StatePersistenceAttribute = class
    inherit Attribute
Public NotInheritable Class StatePersistenceAttribute
Inherits Attribute
继承
StatePersistenceAttribute
属性

注解

StatePersistence 属性不是由派生类继承的,每个执行组件类型都必须提供其 StatePersistence 级别,如果 Actor 类型未指定 StatePersistence 属性,则执行组件状态不会复制或写入磁盘。

构造函数

StatePersistenceAttribute(StatePersistence)

初始化 StatePersistenceAttribute 类的新实例。

属性

StatePersistence

获取表示要用于执行组件的状态存储类型的枚举。

适用于