共用方式為


ServiceBusMessage.ApplicationProperties Property

Definition

Gets the application properties bag, which can be used for custom message metadata.

public System.Collections.Generic.IDictionary<string,object> ApplicationProperties { get; }
member this.ApplicationProperties : System.Collections.Generic.IDictionary<string, obj>
Public ReadOnly Property ApplicationProperties As IDictionary(Of String, Object)

Property Value

Exceptions

Occurs when the ServiceBusMessage is serialized for transport when an unsupported type is used as a property.

Occurs when the ServiceBusMessage is serialized for transport when a value of type byte[] or ArraySegment{byte} is used as a property. The Reason will be set to MessageSizeExceeded in this case.

This is due to a known bug in the Service Bus service, where an application property encoded as binary cannot be handled by the service and is incorrectly rejected for being too large. A fix is planned, but the time line is currently unknown. The recommended workaround is to encode the binary data as a Base64 string.

Remarks

The following types are supported:

  • string
  • bool
  • byte
  • sbyte
  • short
  • ushort
  • int
  • uint
  • long
  • ulong
  • float
  • decimal
  • double
  • char
  • Guid
  • DateTime
  • DateTimeOffset
  • Stream
  • Uri
  • TimeSpan

Applies to