Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

In Python Boto's API for DynamoDB, what are the differences between Layer1 and Layer2?

Which should be used and for what? Is there any advantage to one over the other?

like image 976
ensnare Avatar asked Jan 01 '26 03:01

ensnare


1 Answers

It is only a matter of abstraction levels. In most cases, you will want to use the highest level API.

  • Layer1 API is a direct mapping of Amazon's API
  • layer2 API add some nice abstractions like a generator for scan and query results as well as answer cleaning.

When you call layer2, it calls layer1 which ends up generating HTTP calls.

like image 84
yadutaf Avatar answered Jan 02 '26 15:01

yadutaf



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!