Skip to content

Commit

Permalink
[Service Bus] Hide rule manager (Azure#8660)
Browse files Browse the repository at this point in the history
  • Loading branch information
HarshaNalluru authored May 2, 2020
1 parent a9c5c75 commit 8579032
Show file tree
Hide file tree
Showing 15 changed files with 819 additions and 1,104 deletions.
3 changes: 3 additions & 0 deletions sdk/servicebus/service-bus/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
Please note that if using sessions, this behavior doesn't change with this release.
- Provided down-leveled type declaration files to support older TypeScript versions 3.1 to 3.6.
[PR 8619](https://github.com/Azure/azure-sdk-for-js/pull/8619)
- Remove rule operations from `ServiceBusClient` in favor of having similar operations via the management apis
which would apply to queues, topics, subscriptions and rules in the upcoming previews.
[PR 8660](https://github.com/Azure/azure-sdk-for-js/pull/8660)

## 7.0.0-preview.1 (2020-04-07)

Expand Down
1 change: 0 additions & 1 deletion sdk/servicebus/service-bus/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ Use the client library `@azure/service-bus` in your application to

- Send messages to an Azure Service Bus Queue or Topic
- Receive messages from an Azure Service Bus Queue or Subscription
- Manage Subscription rules

Resources for the v7.0.0-preview.1 of `@azure/service-bus`:

Expand Down
30 changes: 0 additions & 30 deletions sdk/servicebus/service-bus/review/service-bus.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,19 +23,6 @@ export interface BrowseMessagesOptions extends OperationOptions {
maxMessageCount?: number;
}

// @public
export interface CorrelationFilter {
contentType?: string;
correlationId?: string;
label?: string;
messageId?: string;
replyTo?: string;
replyToSessionId?: string;
sessionId?: string;
to?: string;
userProperties?: any;
}

// @public
export interface CreateBatchOptions extends OperationOptions {
maxSizeInBytes?: number;
Expand Down Expand Up @@ -133,13 +120,6 @@ export interface Receiver<ReceivedMessageT> {

export { RetryOptions }

// @public
export interface RuleDescription {
action?: string;
filter?: string | CorrelationFilter;
name: string;
}

// @public
export interface Sender {
cancelScheduledMessage(sequenceNumber: Long, options?: OperationOptions): Promise<void>;
Expand Down Expand Up @@ -172,7 +152,6 @@ export class ServiceBusClient {
createSessionReceiver(queueName: string, receiveMode: "receiveAndDelete", options?: CreateSessionReceiverOptions): Promise<SessionReceiver<ReceivedMessage>>;
createSessionReceiver(topicName: string, subscriptionName: string, receiveMode: "peekLock", options?: CreateSessionReceiverOptions): Promise<SessionReceiver<ReceivedMessageWithLock>>;
createSessionReceiver(topicName: string, subscriptionName: string, receiveMode: "receiveAndDelete", options?: CreateSessionReceiverOptions): Promise<SessionReceiver<ReceivedMessage>>;
getSubscriptionRuleManager(topic: string, subscription: string): SubscriptionRuleManager;
}

// @public
Expand Down Expand Up @@ -234,15 +213,6 @@ export interface SessionReceiverOptions {
export interface SubscribeOptions extends OperationOptions, MessageHandlerOptions {
}

// @public
export interface SubscriptionRuleManager {
addRule(ruleName: string, filter: boolean | string | CorrelationFilter, sqlRuleActionExpression?: string, options?: OperationOptions): Promise<void>;
close(): Promise<void>;
readonly defaultRuleName: string;
getRules(options?: OperationOptions): Promise<RuleDescription[]>;
removeRule(ruleName: string, options?: OperationOptions): Promise<void>;
}

export { TokenCredential }

export { TokenType }
Expand Down
2 changes: 0 additions & 2 deletions sdk/servicebus/service-bus/samples/javascript/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ These sample programs show how to use the JavaScript client libraries for Azure
| [advanced/deferral.js][advanced-deferral] | uses the defer() function to defer a message for later processing |
| [advanced/processMessageFromDLQ.js][advanced-processmessagefromdlq] | retrieves a message from a dead-letter queue, edits it, and sends it back to the main queue |
| [advanced/sessionState.js][advanced-sessionstate] | uses a "shopping cart" example to demonstrate how SessionState information can be read and maintained in an application |
| [advanced/topicFilters.js][advanced-topicfilters] | use topic subscriptions and filters for splitting up a message stream into multiple streams based on message properties |

## Prerequisites

Expand Down Expand Up @@ -67,7 +66,6 @@ Take a look at our [API Documentation][apiref] for more information about the AP
[advanced-deferral]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/javascript/advanced/deferral.js
[advanced-processmessagefromdlq]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/javascript/advanced/processMessageFromDLQ.js
[advanced-sessionstate]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/javascript/advanced/sessionState.js
[advanced-topicfilters]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/javascript/advanced/topicFilters.js
[sendmessages]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/javascript/sendMessages.js
[serviceprincipallogin]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/javascript/servicePrincipalLogin.js
[apiref]: https://docs.microsoft.com/javascript/api/@azure/service-bus
Expand Down
116 changes: 0 additions & 116 deletions sdk/servicebus/service-bus/samples/javascript/advanced/topicFilters.js

This file was deleted.

2 changes: 0 additions & 2 deletions sdk/servicebus/service-bus/samples/typescript/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ These sample programs show how to use the TypeScript client libraries for Azure
| [advanced/processMessageFromDLQ.ts][advanced-processmessagefromdlq] | retrieves a message from a dead-letter queue, edits it, and sends it back to the main queue |
| [advanced/sessionRoundRobin.ts][advanced-session-round-robin] | uses `SessionReceiver`'s ability to get the next available session to round-robin through all sessions in a Queue/Subscription |
| [advanced/sessionState.ts][advanced-sessionstate] | uses a "shopping cart" example to demonstrate how SessionState information can be read and maintained in an application |
| [advanced/topicFilters.ts][advanced-topicfilters] | use topic subscriptions and filters for splitting up a message stream into multiple streams based on message properties |

## Prerequisites

Expand Down Expand Up @@ -82,7 +81,6 @@ Take a look at our [API Documentation][apiref] for more information about the AP
[advanced-processmessagefromdlq]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/typescript/src/advanced/processMessageFromDLQ.ts
[advanced-sessionstate]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/typescript/src/advanced/sessionState.ts
[advanced-session-round-robin]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/typescript/src/advanced/sessionRoundRobin.ts
[advanced-topicfilters]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/typescript/src/advanced/topicFilters.ts
[sendmessages]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/typescript/src/sendMessages.ts
[serviceprincipallogin]: https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/servicebus/service-bus/samples/typescript/src/servicePrincipalLogin.ts
[apiref]: https://docs.microsoft.com/javascript/api/@azure/service-bus
Expand Down

This file was deleted.

5 changes: 5 additions & 0 deletions sdk/servicebus/service-bus/src/core/managementClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ import { OperationOptions } from "../modelsToBeSharedWithEventHubs";
import { AbortError } from "@azure/abort-controller";

/**
* @internal
* @ignore
* Represents a Rule on a Subscription that is used to filter the incoming message from the
* Subscription.
*/
Expand All @@ -73,6 +75,9 @@ export interface RuleDescription {
}

/**
* @internal
* @ignore
*
* Represents the correlation filter expression.
* A CorrelationFilter holds a set of conditions that are matched against user and system properties
* of incoming messages from a Subscription.
Expand Down
3 changes: 0 additions & 3 deletions sdk/servicebus/service-bus/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ export {

export { SessionReceiverOptions, SessionMessageHandlerOptions } from "./session/messageSession";

export { CorrelationFilter, RuleDescription } from "./core/managementClient";

export {
ReceivedMessage,
ServiceBusMessage,
Expand All @@ -43,7 +41,6 @@ export {
export { OperationOptions } from "./modelsToBeSharedWithEventHubs";

export { Receiver } from "./receivers/receiver";
export { SubscriptionRuleManager } from "./receivers/subscriptionRuleManager";
export { SessionReceiver } from "./receivers/sessionReceiver";
export { Sender } from "./sender";
export { ServiceBusClient } from "./serviceBusClient";
Loading

0 comments on commit 8579032

Please sign in to comment.