There’s actually one thing you need to take into account when using 
DynamoDB for persistence.

I've been bitten by this a few times when using other Amazon services.


The Java SDK provided by Amazon includes two interfaces: synchronous and 
asynchronous.

I imagine you’d prefer to use the asynchronous API as part of an Akka 
application, but unlike what you often encounter with other such dual APIs, 
the asynchronous API in this case is implemented as a wrapper around the 
synchronous API (using a thread pool) which uses blocking IO. What I’m at 
least used to with other NoSQL clients is having things the other way 
around – an asynchronous client that uses non-blocking IO and a synchronous 
wrapper around it, but that’s not currently the case with the Amazon Java 
SDK. 

 

Given that each operation is actually an HTTP call to the amazon service 
(not sure if there's any batching going on internally, but probably not), 
they can get pretty pricy.

You will need to make sure that you don’t send requests to Amazon faster 
than the client can handle it.

It’s not just a question of overflowing the thread pool, you can also get 
terrible latency for some of the requests this way as they get queued in 
your JVM, which depending on your system, might not be acceptable.

Another option is to make the HTTP calls using your own non-blocking 
client, but that comes with a larger price tag for development time.


And then again, perhaps it's not really an issue in your case and you won't 
even come close to suffering from this.


On Saturday, June 20, 2015 at 8:36:09 PM UTC+3, Bill Goldsworthy wrote:
>
> OK, good to know, thanks!
>
> On Friday, June 19, 2015 at 11:24:50 AM UTC-5, Konrad Malawski wrote:
>>
>> Hi Bill,
>> I don't see a reason why such implementation wouldn't make sense - in 
>> fact many of the other NoSQL stores nowadays are very "dynamo inspired" :-)
>> So I'd say it's just a matter of actually sitting down and implementing 
>> it.
>>
>> PS: We're in the middle of the final adjustment phase in Akka Persistence 
>> (plugin APIs *slightly* affected), after which Persistence will soon become 
>> a stable module (yay!).
>>
>> -- Konrad
>>
>> On Fri, Jun 19, 2015 at 4:20 PM, Bill Goldsworthy <bgol...@gmail.com> 
>> wrote:
>>
>>> Greetings,
>>>
>>> Is there a DynamoDB snapshot plugin for akka-persistence available 
>>> anywhere? There is not one listed on the community page and my searches 
>>> have been fruitless. If not, is this because of technical limitations with 
>>> DynamoDB or simply because one hasn't been created yet?
>>>
>>> Thank you,
>>> Bill Goldsworthy
>>>
>>> -- 
>>> >>>>>>>>>> Read the docs: http://akka.io/docs/
>>> >>>>>>>>>> Check the FAQ: 
>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>> >>>>>>>>>> Search the archives: 
>>> https://groups.google.com/group/akka-user
>>> --- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "Akka User List" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to akka-user+...@googlegroups.com.
>>> To post to this group, send email to akka...@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/akka-user.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
>>
>> -- 
>> Cheers,
>> Konrad 'ktoso' Malawski
>> Akka <http://akka.io/> @ Typesafe <http://typesafe.com/>
>>  
>

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to akka-user+unsubscr...@googlegroups.com.
To post to this group, send email to akka-user@googlegroups.com.
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to