Uredi

Deli z drugimi prek


MessageQueue.MaximumJournalSize Property

Definition

Gets or sets the maximum size of the journal queue.

public:
 property long MaximumJournalSize { long get(); void set(long value); };
[System.ComponentModel.TypeConverter(typeof(System.Messaging.Design.SizeConverter))]
[System.Messaging.MessagingDescription("MQ_MaximumJournalSize")]
public long MaximumJournalSize { get; set; }
[<System.ComponentModel.TypeConverter(typeof(System.Messaging.Design.SizeConverter))>]
[<System.Messaging.MessagingDescription("MQ_MaximumJournalSize")>]
member this.MaximumJournalSize : int64 with get, set
Public Property MaximumJournalSize As Long

Property Value

The maximum size, in kilobytes, of the journal queue. The Message Queuing default specifies that no limit exists.

Attributes

Exceptions

The maximum journal queue size was set to an invalid value.

An error occurred when accessing a Message Queuing method.

Examples

The following code example gets and sets the value of a message queue's MaximumJournalSize property.

// Set the queue's MaximumJournalSize property value.
queue.MaximumJournalSize = 10;

// Display the new value of the queue's MaximumJournalSize property.
Console.WriteLine("MessageQueue.MaximumJournalSize: {0}",
    queue.MaximumJournalSize);

Remarks

MaximumJournalSize provides access to the Message Queuing journal storage limit. It is relevant only when UseJournalQueue is true. Setting this property modifies the Message Queuing queue. Therefore, any other MessageQueue instances are affected by the change

If you store messages in a journal or dead-letter queue, you should periodically clear the queue to remove messages that are no longer needed. Messages in such a queue count toward the message quota for the computer where the queue resides. (The administrator sets the computer quota.)

The following table shows whether this property is available in various Workgroup modes.

Workgroup mode Available
Local computer Yes
Local computer and direct format name Yes
Remote computer No
Remote computer and direct format name No

Applies to

See also