You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+28-16Lines changed: 28 additions & 16 deletions
Original file line number
Diff line number
Diff line change
@@ -27,7 +27,7 @@ and cost *far* less to run than "*traditional*" server-based apps.
27
27
28
28
Amazon Web Services (AWS) Lambda lets you run JavaScript (Node.js), Java & Python
29
29
scripts/apps in Amazon's (virtually) infinitely-scalable cloud environment
30
-
without having provision VM instances or other "*orquestration*";
30
+
without having provision VM instances or other "*orchestration*";
31
31
Everything is dynamically auto-scaled so if you have 1 user or 1 billion
32
32
you pay for *usage*.
33
33
@@ -92,34 +92,46 @@ Here's a super simple walkthrough of a 'HELLO WORLD!' example to help get you st
92
92
93
93
2. Sign in to the AWS management console, select your region in the top right hand corner and then open the AWS Lambda console.
94
94
95
-
3.Choose 'Get Started Now' and then select the 'hello-world' blueprint from the list of option tiles.
95
+
3.On the 'Learn to Build' section click on 'see all' and then select 'Run a Serverless "Hello World!"'.
96
96
97
-
4.On the 'Configure Function' page, edit the existing inline code to create your function. AWS Lambda expects us to export an object which has a property called handler. Here's our example:
97
+
4.Select that you want to make a blueprint and search for the 'hello-world' example.
5. Once you have found this follow the instructions given to set up your function.
100
+
This will include setting a role (a role is an AWS identity with permission
101
+
policies that determine what the identity can or cannot do in AWS. For more
102
+
information on roles click **[here](http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles.html)**).
103
+
Like the tutorial suggests we chose the 'lambda_basic_execution' role because our function is extremely simple.
100
104
101
-
The value of that property is a function that takes two arguments, event and context. The event will be created by us and the context consists of the runtime information which will be supplied by AWS lambda. They both take the form of JSON objects.
105
+
6. AWS Lambda expects us to export an object which has a property called handler.
106
+
You can specify the handler and the runtime you wish to give it in the 'Function
107
+
code' section:
102
108
103
-
5. Beneath the function you then have to specify the handler and the role you wish to give it. (A role is an AWS identity with permission policies that determine what the identity can or cannot do in AWS. For more information on roles click **[here](http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles.html)**). We chose the 'lambda_basic_execution' role because our function is extremely simple:
109
+

104
110
105
-

111
+
6. Now your function has been created you have the chance to edit its code. Under
112
+
the 'Function code' title, edit the existing inline code. Here's our example:
106
113
107
-
In the 'Advanced Settings' section you can specify the amount of memory that each AWS Lambda instance should be allocated.
108
-
**_Note: by increasing the memory, this also increases the cost of your function runtime!_**
6. Click 'next' to review your code and then if you are happy click 'create function'. You'll then be taken to your AWS Lambda functions where you should see the one you just created.
116
+
The value of that property is a function that takes two arguments, event and context. The event will be created by us and the context consists of the runtime information which will be supplied by AWS lambda. They both take the form of JSON objects.
117
+
118
+
7. In the 'Basic Settings' section you can specify the amount of memory that each AWS Lambda instance should be allocated.
119
+
**_Note: by increasing the memory, this also increases the cost of your function runtime!_**
7. We can then test our function by clicking on the blue 'Test' button in the top left. Here we will be able to specify the payload of the event that gets passed to our function. There will be an existing event template but we changed the key value pairs as shown below:
123
+
8. We can test our function by clicking on the 'Test' button in the top right.
124
+
Here we will be able to specify the payload of the event that gets passed to our
125
+
function. There will be an existing event template but we changed the key value
0 commit comments