Exporteren (0) Afdrukken
Alles uitvouwen
EN
Deze inhoud is niet beschikbaar in uw taal, maar wel in het Engels.

Service Bus Samples

Updated: July 17, 2014

The Microsoft Azure Service Bus samples demonstrate the use of the features of Service Bus and Service Bus for Windows Server. To download the samples, visit Azure SDK samples page. This topic categorizes and describes the samples available, with links to each.

noteNote
By default, the Microsoft Azure Service Bus samples are no longer installed with the SDK. To obtain the samples, visit the Azure SDK samples page.

The following samples illustrate how to write applications that use Service Bus.

Note that the brokered messaging samples require a connection string to access your Service Bus service namespace.

  1. Log on to the Azure Management Portal.

  2. In the left-hand column, click Service Bus.

  3. Click the name of your service namespace in the list.

  4. Click Connection Information. In the Access connection information dialog, copy the connection string to your clipboard.

  5. Paste the connection string into the App.config file for the sample.

  1. Run the following PowerShell cmdlet:

    get-sbClientConfiguration
    
  2. Paste the connection string into the App.config file for the sample.

These samples describe basic messaging and relay functionality.

 

Sample Name Description Minimum SDK Version Availability

Getting Started: Messaging with Queues

Demonstrates how to use Microsoft Azure Service Bus to send and receive messages from a queue.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Getting Started: Messaging With Topics

Demonstrates how to use Microsoft Azure Service Bus to send and receive messages from a topic with multiple subscriptions.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Getting Started with Event Hubs

Demonstrates the basic capabilities of Event Hubs, such as creating an Event Hub, sending events to an Event hub, consuming events using the Event Processor.

2.4

Microsoft Azure Service Bus

The following samples demonstrate various features of Service Bus.

 

Sample Name Description Minimum SDK Version Availability

HTTP Token Providers

Demonstrates the different ways of authenticating an HTTP/REST client with Service Bus.

2.1

Microsoft Azure Service Bus; Service Bus for Windows Server

Service Bus HTTP Client

Demonstrates how to send messages to and receive messages from Service Bus via HTTP/REST.

2.3

Microsoft Azure Service Bus; Service Bus for Windows Server

Service Bus Autoforwarding

Demonstrates how to automatically forward messages from a queue, subscription, or deadletter queue into another queue or topic. It also demonstrates how to send a message into a queue or topic via a transfer queue.

2.3

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: WCF Channel Session Sample

Demonstrates how to use Microsoft Azure Service Bus using Windows Communication Foundation (WCF) channels. The sample shows the use of WCF channels to send and receive messages via a Service Bus queue. The sample shows both session and non-session communication over the Service Bus.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Transactions

Demonstrates how to use the Microsoft Azure Service Bus messaging features within a transaction scope in order to ensure batches of messaging operations are committed atomically.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Management Operations Using REST

Demonstrates how to perform management operations on Service Bus using REST.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Resource Provider REST APIs

Demonstrates how to use the new Service Bus RDFE REST APIs to manage namespaces and messaging entities.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: WCF Service Session Sample

Demonstrates how to use Microsoft Azure Service Bus using the WCF service model. The sample shows the use of the WCF service model to accomplish session-based communication via a Service Bus queue.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Request Response

Demonstrates how to use the Microsoft Azure Service Bus and the request/response functionality. The sample shows simple clients and servers communicating via a Service Bus queue.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Dead Letter Queue

Demonstrates how to use Microsoft Azure Service Bus and the messaging "dead letter queue" functionality. The sample shows a simple sender and receiver communicating via a Service Bus queue.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Deferred Messages

Demonstrates how to use the message deferral feature of Microsoft Azure Service Bus. The sample shows a simple sender and receiver communicating via a Service Bus queue.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Session Messages

Demonstrates how to use Microsoft Azure Service Bus and the Messaging Session functionality. The sample shows simple senders and receivers communicating via a Service Bus queue.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Request Response Topic

Demonstrates how to implement the request/response pattern using Microsoft Azure Service Bus topics and subscriptions. The sample shows simple clients and servers communicating via a Service Bus topic.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Request Response Queue

Demonstrates how to use Microsoft Azure Service Bus and the request/response functionality. The sample shows simple clients and servers communicating via two Service Bus queues.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Duplicate Detection

Demonstrates how to use Microsoft Azure Service Bus duplicate message detection with queues. It creates two queues, one with duplicate detection enabled and other one without duplicate detection.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Async Messaging

Demonstrates how to use Microsoft Azure Service Bus to send and receive messages asynchronously from a queue. The queue provides decoupled, asynchronous communication between a sender and any number of receivers (here, a single receiver).

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging : Advanced Filters

Demonstrates how to use Microsoft Azure Service Bus publish/subscribe advanced filters. It creates a topic and 3 subscriptions with different filter definitions, sends messages to the topic, and receives all messages from subscriptions.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Brokered Messaging: Messages Prefetch

Demonstrates how to use the Microsoft Azure Service Bus messages prefetch feature. It demonstrates how to use the messages prefetch feature upon receive.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Samples that demonstrate the Service Bus relay.

 

Sample Name Description Minimum SDK Version Availability

Relayed Messaging; Azure

Demonstrates how to run a Microsoft Azure Service Bus client and service on Microsoft Azure. This sample configures Service Bus programmatically. Only environment and security information is stored in the configuration files.

1.8

Microsoft Azure Service Bus

Relayed Messaging Authentication: Shared Secret

Demonstrates how to use an issuer name and issuer secret to authenticate with Service Bus.

1.8

Microsoft Azure Service Bus

Relayed Messaging Authentication: WebNoAuth

Demonstrates how to expose an HTTP service that does not require client user authentication.

1.8

Microsoft Azure Service Bus

Relayed Messaging Bindings: WebHttp

Demonstrates how to use the WebHttpRelayBinding binding to return binary data using the Web programming model.

1.8

Microsoft Azure Service Bus

Relayed Messaging Bindings: NetTcp Relayed

Demonstrates how to use the NetTcpRelayBinding binding.

1.8

Microsoft Azure Service Bus

Samples that demonstrate the Service Bus relay.

 

Sample Name Description Minimum SDK Version Availability

Relayed Messaging Authentication: Simple WebToken

Demonstrates how to use a simple web token credential to authenticate with Service Bus. The sample is similar to the Echo sample, with a few changes. Specifically, this sample adds a behavior in the ServiceHost (service) and ChannelFactory (client) applications.

1.8

Microsoft Azure Service Bus

Relayed Messaging: Load Balance

Demonstrates how to use Microsoft Azure Service Bus to route messages to multiple receivers. It shows multiple instances of a simple service communicating with a client via the NetTcpRelayBinding binding

1.8

Microsoft Azure Service Bus

Relayed Messaging Bindings: Net Event

Demonstrates using the NetEventRelayBinding binding on Microsoft Azure Service Bus.

1.8

Microsoft Azure Service Bus

Relayed Messaging Bindings: WS2007Http Session

Demonstrates using the WS2007HttpRelayBinding binding with reliable sessions enabled. It also shows how to specify Service Bus credentials in the configuration file instead of programmatically.

1.8

Microsoft Azure Service Bus

Relayed Messaging Bindings : WS2007Http MsgSecCertificate

Demonstrates how to use the WS2007HttpRelayBinding binding with message security to secure end-to-end messages while still requiring clients to authenticate with Service Bus.

1.8

Microsoft Azure Service Bus

Relayed Messaging: Metadata Exchange

Demonstrates how to expose a metadata endpoint that uses the relay binding. MetadataExchange is supported in the following relay bindings: NetTcpRelayBinding, NetOnewayRelayBinding, BasicHttpRelayBinding, and WS2007HttpRelayBinding.

1.8

Microsoft Azure Service Bus

Relayed Messaging Bindings: NetTcp Direct

Demonstrates how to configure the NetTcpRelayBinding binding to support the Hybrid connection mode which first establishes a relayed connection, and if possible, switches automatically to a direct connection between a client and a service.

1.8

Microsoft Azure Service Bus

Relayed Messaging Bindings: NetTcp MsgSec UserName

Demonstrates how to use the NetTcpRelayBinding binding with message security.

1.8

Microsoft Azure Service Bus

Relayed Messaging Bindings: Net Oneway

Demonstrates how to expose and consume a service endpoint using the NetOnewayRelayBinding binding.

1.8

Microsoft Azure Service Bus

Relayed Messaging Bindings: WS2007Http Simple

Demonstrates using the WS2007HttpRelayBinding binding. It demonstrates a simple service that uses no security options and does not require clients to authenticate.

1.8

Microsoft Azure Service Bus

The following samples demonstrate various other features of the service.

 

Sample Name Description Minimum SDK Version Availability

Service Bus Explorer

The Service Bus Explorer allows users to connect to a Service Bus service namespace and manage messaging entities in an easy manner. The tool provides advanced features such as import/export functionality, and the ability to test messaging entities and relay services.

1.8

Microsoft Azure Service Bus; Service Bus for Windows Server

Authorization: SBAzTool

This sample demonstrates how to create and manage service identities in Microsoft Azure Active Directory Access Control (also known as Access Control Service or ACS) for use with Service Bus.

N/A

Microsoft Azure Service Bus

Weergeven:
© 2014 Microsoft