BatchPutAttributes
The original release of SimpleDB only provided the ability to update or save attributes for a single item per call. As you can imagine, this can cause major performance issues if you had updated several items and their attributes, as you would have to make one SimpleDB call for each item. This may not seem like such a big deal, but once the number of items to be updated starts going above 100, this becomes very significant. SimpleDB released support for insert or update of multiple items in the form of BatchPutAttributes
. This is a nice way to perform multiple PutAttribute
operations in a single call, saving unnecessary round trips and network and HTTP response/request latencies to the SimpleDB server.
BatchPutAttributes in Java
In this section, we will create a Java class that will update attributes for multiple items by making a single call to SimpleDB. We will accomplish that by using the support for BatchPutAttributes
provided by Typica. The following code runs a query...