Indeed, my main personal experience with Lambda so far has been in writing an 
Alexa skill in my spare time.  It’s been quite fun, and very instructive in the 
benefits and pitfalls of lambda.

My main takehomes so far:

1.  I love the fact that there’s basically no code at all other than that 
required to deliver the actual skill. Just handler functions for the incoming 
requests (Intents, as Amazon call them)

2.  Debugging is awkward.  There is no interactive debugging, as far as I can 
tell.   Log inspection is about all you have, and some errors are obtuse (for 
example, some valid Node.js constructs produce syntax errors on Lambda, and 
it’s very hard to track down when it happens - unit tests all pass locally but 
then you get a syntax error in the LogWatch logs, with a useless stack trace 
that doesn’t tell you where the syntax error is).  Debugging and unit testing 
on your laptop is hard to do; many Alexa APIs rely on real hardware functions 
and the simulators don’t handle them.

3.  Persistence of data is fairly straightforward using S3 buckets or DynamoDB, 
and I haven’t noticed latency issues with those (of course the interactions are 
on a human timescale, so latency isn’t really much of an issue)

4.  Interaction with external services can be problematic; Alexa lambda 
functions must return within 8 seconds, which can be fun if your skill needs to 
fetch data from some other source (in my case a rather sluggish data service in 
Azure run by my local council), and there’s no clean way to handle the event if 
you hit the 8 second limit, the function just gets terminated and Alexa returns 
a rather meaningless error to the user.

Tim

On 25 Nov 2020, at 09:45, John Hearns 
<hear...@gmail.com<mailto:hear...@gmail.com>> wrote:

BTW, I am sure everyone knows this but if you have a home assistant such as 
Alexa everytime you ask Alexa it is a lambda which is spun up





-- 
 The Wellcome Sanger Institute is operated by Genome Research 
 Limited, a charity registered in England with number 1021457 and a 
 company registered in England with number 2742969, whose registered 
 office is 215 Euston Road, London, NW1 2BE.
_______________________________________________
Beowulf mailing list, Beowulf@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit 
https://beowulf.org/cgi-bin/mailman/listinfo/beowulf

Reply via email to