ServiceBusNamespaceClient.BeginCreateQueue Method (String, QueueDescription, AsyncCallback, Object)
Asynchronous version of CreateQueue(String, QueueDescription).
Namespace: Microsoft.ServiceBus
Assembly: Microsoft.ServiceBus.Messaging (in Microsoft.ServiceBus.Messaging.dll)
Syntax
'Declaration
Public Function BeginCreateQueue ( _
path As String, _
description As QueueDescription, _
callback As AsyncCallback, _
state As Object _
) As IAsyncResult
'Usage
Dim instance As ServiceBusNamespaceClient
Dim path As String
Dim description As QueueDescription
Dim callback As AsyncCallback
Dim state As Object
Dim returnValue As IAsyncResult
returnValue = instance.BeginCreateQueue(path, _
description, callback, state)
public IAsyncResult BeginCreateQueue(
string path,
QueueDescription description,
AsyncCallback callback,
Object state
)
public:
IAsyncResult^ BeginCreateQueue(
String^ path,
QueueDescription^ description,
AsyncCallback^ callback,
Object^ state
)
member BeginCreateQueue :
path:string *
description:QueueDescription *
callback:AsyncCallback *
state:Object -> IAsyncResult
public function BeginCreateQueue(
path : String,
description : QueueDescription,
callback : AsyncCallback,
state : Object
) : IAsyncResult
Parameters
- path
Type: System.String
Path of the queue relative to the service namespace base address.
- description
Type: Microsoft.ServiceBus.Messaging.QueueDescription
The queue description object.
- callback
Type: System.AsyncCallback
A AsyncCallback delegate that references the method to invoke when the operation is complete.
- state
Type: System.Object
A user-defined object that contains information about the receive operation. This object is passed to the EndCreateQueue(IAsyncResult) delegate when the operation is complete.
Return Value
Type: System.IAsyncResult
An IAsyncResult object that references the asynchronously created queue.
Exceptions
Exception | Condition |
---|---|
ArgumentException | path is null or empty. |
ArgumentOutOfRangeException | Length of path is greater than QueueNameMaximumLength(). |
TimeoutException | The operation times out. The timeout period is initialized through the ServiceBusNamespaceClientSettings class. You may need to increase the value of the OperationTimeout property to avoid this exception if the timeout value is relatively low. |
MessagingEntityAlreadyExistsException | A queue with the same name and path exists under the same service namespace. |
UnauthorizedAccessException | The ServiceBusNamespaceClient object does not have sufficient permission to perform this operation. You should check to ensure that your ServiceBusNamespaceClient has the correct Credential credentials to perform this operation. |
QuotaExceededException | The maximum allowable quota has been reached. You must delete existing entities or increase your quota size. |
MessagingException | An internal error or unexpected exception occurs. |
ServerBusyException | The server is overloaded with logical operations. You can consider any of the following actions:
|