Skip to content

Commit d838313

Browse files
committed
test formatting
1 parent b21218b commit d838313

File tree

1 file changed

+51
-13
lines changed

1 file changed

+51
-13
lines changed

articles/azure-functions/migration/lambda-functions-migration-migrate.md

Lines changed: 51 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,70 @@
11
---
2-
title: AWS Lambda to Azure Functions Migration Migrate Stage
3-
description: Learn about the steps that you need to take during the migrate stage of your AWS Lambda to Azure Functions migration.
2+
title: Migrate Workloads from AWS Lambda to Azure Functions
3+
description: Learn about the steps to complete your AWS Lambda to Azure Functions migration, test performance, optimize operations, and implement monitoring.
44
author: MadhuraBharadwaj-MSFT
55
ms.author: mabhar
66
ms.service: azure-functions
77
ms.topic: how-to
88
ms.date: 03/18/2025
9-
#customer intent: As a developer, I want to learn about the migrate stage of migration so that I can migrate serverless applications from AWS Lambda to Azure Functions efficiently.
9+
#customer intent: As a developer, I want to adapt function code for compatibility and best practices so that I can migrate serverless applications from AWS Lambda to Azure Functions efficiently.
1010
---
1111

12-
# AWS Lambda to Azure Functions migration migrate stage
12+
# Migrate workloads from AWS Lambda to Azure Functions
1313

14-
In this stage, after mapping AWS Lambda features to Azure Functions and developing a migration plan, it's time to execute the migration. The goal is to adapt function code for compatibility and best practices, migrate workloads to Azure Functions, test for performance, optimize operations, and implement monitoring for reliability and efficiency.
14+
In this stage, you finish migrating your workload from AWS Lambda to Azure Functions. The goal is to adapt function code for compatibility and best practices, migrate the workload, test for performance, optimize operations, and implement monitoring for reliability and efficiency.
1515

16-
## Adapt Function Code, Config and Infrastructure as Code (IaC) files
16+
## Adapt function code, configuration files, and infrastructure as code files
1717

18-
- Update Code for Azure Functions Runtime Requirements:
19-
- Modify your code to adhere to the Azure Functions programming model. For instance, adapt your function signatures to match Azure Functions' required format. Refer to our language specific [Azure Functions developer guides](/azure/azure-functions/functions-reference-node) for details on function definition and execution context.
20-
- Utilize the [Azure Functions extensions bundle](/azure/azure-functions/functions-bindings-register) to handle various bindings and triggers that are similar to AWS services. For .NET applications, you should use the appropriate NuGet packages rather than the extensions bundle.
21-
- The extensions bundle allows you to integrate with other Azure services such as Storage, Service Bus, Cosmos DB, and more without needing to manually configure each binding through SDKs. For more details on integrating services with Azure Functions, refer to [Connect functions to Azure services using bindings](/azure/azure-functions/add-bindings-existing-function) and [Azure Functions bindings expressions and patterns](/azure/azure-functions/functions-bindings-expressions-patterns)
18+
You need to adapt function code, configuration files, and infrastructure as code (IaC) files to adhere to the Azure Functions programming model and best practices. This step helps ensure that your workload is compatible with Functions.
2219

23-
Below are some examples of common SDK code snippets written in AWS Lambdas mapped to corresponding Triggers/Bindings/SDK code snippets with Azure Functions:
20+
To update code for Azure Functions runtime requirements:
2421

25-
**Reading from S3 (AWS) vs. Blob Storage (Azure)**
22+
- Modify your code to adhere to the Functions programming model. For instance, adapt your function signatures to match the format that Functions requires. For more information about function definition and execution context, see [Functions developer guides](/azure/azure-functions/functions-reference-node).
23+
24+
- Use the [Functions extensions bundle](/azure/azure-functions/functions-bindings-register) to handle various bindings and triggers that are similar to AWS services. For .NET applications, you should use the appropriate NuGet packages instead of the extensions bundle.
25+
26+
- The extensions bundle allows you to integrate with other Azure services such as Storage, Service Bus, and Azure Cosmos DB without needing to manually configure each binding through SDKs. For more information, see [Connect functions to Azure services by using bindings](/azure/azure-functions/add-bindings-existing-function) and [Azure Functions binding expression patterns](/azure/azure-functions/functions-bindings-expressions-patterns).
27+
28+
The following snippets are examples of common SDK code. The AWS Lambda code maps to the corresponding triggers, bindings, or SDK code snippets in Azure Functions.
29+
30+
**Reading from Amazon S3 versus Azure Blob Storage**
31+
32+
:::row:::
33+
:::column span="":::
34+
35+
const AWS = require('aws-sdk');
36+
const s3 = new AWS.S3();
37+
38+
exports.handler = async (event) => {
39+
const params = {
40+
Bucket: 'my-bucket',
41+
Key: 'my-object.txt',
42+
};
43+
const data = await
44+
s3.getObject(params).promise();
45+
console.log('File content:',
46+
data.Body.toString());
47+
};
48+
49+
:::column-end:::
50+
:::column span="":::
51+
52+
import { app } from '@azure/functions';
53+
54+
app.storageblob('blobTrigger', {
55+
path: 'my-container/{blobName}',
56+
connection: 'AzureWebJobsStorage',
57+
}, async (context, myBlob) => {
58+
context.log(`Blob content:
59+
${myBlob.toString()}`);
60+
});
61+
62+
:::column-end:::
63+
:::row-end:::
2664

2765
| AWS Lambda code (SDK) | Azure Functions code (Trigger) |
2866
|---|---|
29-
| const AWS = require('aws-sdk'); const s3 = new AWS.S3(); exports.handler = async (event) => { const params = { Bucket: 'my-bucket', Key: 'my-object.txt', }; const data = await s3.getObject(params).promise(); console.log('File content:', data.Body.toString()); }; | import { app } from '@azure/functions'; app.storageblob('blobTrigger', { path: 'my-container/{blobName}', connection: 'AzureWebJobsStorage', }, async (context, myBlob) => { context.log(`Blob content: ${myBlob.toString()}`); }); |
67+
| const AWS = require('aws-sdk'); const s3 = new AWS.S3(); <br><br> exports.handler = async (event) => { const params = { Bucket: 'my-bucket', Key: 'my-object.txt', <br> }; <br> const data = await s3.getObject(params).promise(); console.log('File content:', data.Body.toString()); <br> }; | import { app } from '@azure/functions'; <br><br> app.storageblob('blobTrigger', { <br> path: 'my-container/{blobName}', <br> connection: 'AzureWebJobsStorage', <br> }, async (context, myBlob) => { <br> context.log(`Blob content: ${myBlob.toString()}`); <br> }); |
3068

3169
**Writing to SQS (AWS) vs. Queue Storage (Azure)**
3270

0 commit comments

Comments
 (0)