-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathTasks.cs
24 lines (23 loc) · 841 Bytes
/
Tasks.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Azure.Messaging.EventHubs;
using Microsoft.Azure.WebJobs;
using Microsoft.Extensions.Logging;
using Azure.Messaging.Replication;
using Azure.Messaging.ServiceBus;
namespace ServiceBusCopy
{
public static class Tasks
{
[FunctionName("jobs-transfer")]
[ExponentialBackoffRetry(-1, "00:00:05", "00:05:00")]
public static Task JobsTransfer(
[ServiceBusTrigger("jobs-transfer", Connection = "jobs-transfer-source-connection")] ServiceBusReceivedMessage[] input,
[ServiceBus("jobs", Connection = "jobs-target-connection")] IAsyncCollector<ServiceBusMessage> output,
ILogger log)
{
return ServiceBusReplicationTasks.ForwardToServiceBus(input, output, log);
}
}
}