Class StreamMetadataBase
Stream metadata base class.
Implements
Namespace: Microsoft.Psi
Assembly: Microsoft.Psi.dll
Syntax
public abstract class StreamMetadataBase : object, IStreamMetadata
Constructors
View SourceStreamMetadataBase(String, Int32, String, String, String, DateTime, DateTime, Int64, Double, Double)
Initializes a new instance of the Stream
Declaration
public StreamMetadataBase(string name, int id, string typeName, string partitionName, string partitionPath, DateTime first, DateTime last, long messageCount, double averageMessageSize, double averageLatencyMs)
Parameters
Type | Name | Description |
---|---|---|
System. |
name | Stream name. |
System. |
id | Stream ID. |
System. |
typeName | Stream type name. |
System. |
partitionName | Partition/file name. |
System. |
partitionPath | Partition/file path. |
Date |
first | First message time. |
Date |
last | Last message time. |
System. |
messageCount | Total message count. |
System. |
averageMessageSize | Average message size (bytes). |
System. |
averageLatencyMs | Average message latency (milliseconds). |
Properties
View SourceAverageMessageLatencyMs
Gets the average latency (milliseconds) of messages in the stream.
Declaration
public double AverageMessageLatencyMs { get; }
Property Value
Type | Description |
---|---|
System. |
AverageMessageSize
Gets the average size (bytes) of messages in the stream.
Declaration
public double AverageMessageSize { get; }
Property Value
Type | Description |
---|---|
System. |
ClosedTime
Gets the time when the stream was closed.
Declaration
public DateTime ClosedTime { get; }
Property Value
Type | Description |
---|---|
Date |
FirstMessageCreationTime
Gets the first creation time of a message in the stream.
Declaration
public DateTime FirstMessageCreationTime { get; }
Property Value
Type | Description |
---|---|
Date |
See Also
View SourceFirstMessageOriginatingTime
Gets the first originating time of a message in the stream.
Declaration
public DateTime FirstMessageOriginatingTime { get; }
Property Value
Type | Description |
---|---|
Date |
See Also
View SourceId
Gets the id of the stream the metadata represents.
Declaration
public int Id { get; }
Property Value
Type | Description |
---|---|
System. |
IsClosed
Gets a value indicating whether the stream has been closed.
Declaration
public bool IsClosed { get; }
Property Value
Type | Description |
---|---|
System. |
LastMessageCreationTime
Gets the last creation time of a message in the stream.
Declaration
public DateTime LastMessageCreationTime { get; }
Property Value
Type | Description |
---|---|
Date |
See Also
View SourceLastMessageOriginatingTime
Gets the last originating time of a message in the stream.
Declaration
public DateTime LastMessageOriginatingTime { get; }
Property Value
Type | Description |
---|---|
Date |
See Also
View SourceMessageCount
Gets the number of messages in the stream.
Declaration
public long MessageCount { get; }
Property Value
Type | Description |
---|---|
System. |
Name
Gets the name of the stream the metadata represents.
Declaration
public string Name { get; }
Property Value
Type | Description |
---|---|
System. |
OpenedTime
Gets the time when the stream was opened.
Declaration
public DateTime OpenedTime { get; }
Property Value
Type | Description |
---|---|
Date |
StoreName
Gets the name of the store containing the stream.
Declaration
public string StoreName { get; }
Property Value
Type | Description |
---|---|
System. |
StorePath
Gets the path of the store containing the stream.
Declaration
public string StorePath { get; }
Property Value
Type | Description |
---|---|
System. |
SupplementalMetadataTypeName
Gets the name of the type of supplemental metadata for the stream the metadata represents.
Declaration
public string SupplementalMetadataTypeName { get; }
Property Value
Type | Description |
---|---|
System. |
TypeName
Gets the name of the type of data contained in the stream the metadata represents.
Declaration
public string TypeName { get; }
Property Value
Type | Description |
---|---|
System. |
Methods
View SourceGetSupplementalMetadata<T>()
Gets supplemental stream metadata.
Declaration
public virtual T GetSupplementalMetadata<T>()
Returns
Type | Description |
---|---|
T | Supplemental metadata. |
Type Parameters
Name | Description |
---|---|
T | Type of supplemental metadata. |
Update(Envelope, Int32)
Updates this stream metadata with the specified envelope and size.
Declaration
public virtual void Update(Envelope envelope, int size)
Parameters
Type | Name | Description |
---|---|---|
Envelope | envelope | The envelope. |
System. |
size | The size. |
Update(TimeInterval, TimeInterval)
Updates this stream metadata with the times and originating times of the first and last messages.
Declaration
public virtual void Update(TimeInterval messagesTimeInterval, TimeInterval messagesOriginatingTimeInterval)
Parameters
Type | Name | Description |
---|---|---|
Time |
messagesTimeInterval | A TimeInterval representing the times of the first and last messages in the stream. |
Time |
messagesOriginatingTimeInterval | A TimeInterval representing the originating times of the first and last messages in the stream. |