3 ms·
Show HN: A/B Testing Backend Using AWS Lambda and Redis HyperLogLog
- gingerlime 11y agoVery keen to get some feedback since it's the first time I'm using Lambda and Redis HyperLogLog, and might have missed something. It's still quite raw, but I hope it has good potential. I wrote a bit more about the architecture, motivation etc on my blog[0] [0] http://blog.gingerlime.com/2016/a-scaleable-ab-testing-backend-in-100-lines-of-code-and-for-free/ http://blog.gingerlime.com/2016/a-scaleable-ab-testing-backe...
- _bpo 11y agoLooks like your blog is down at the moment
- gingerlime 11y agoSorry about that. It's working for me now. I'll add some monitoring to check its status.
- vhaenel 11y agoYeah, it still seems down.
- gingerlime 11y agoreally? It's working for me, and I have set uptimerobot to test it and it's reporting everything ok... something weird is going on, but not sure what. Does it produce a 404 / 500 / something else?
- vhaenel 11y agoCorrection, it says: Site not configured
- gingerlime 11y agothat sounds like a webfaction error (where I host the blog), but it usually happens when the domain name doesn't match what they know they're hosting... Are you using https anywhere or some other type of plugin that might change the URL or proxy your access somehow? (anything that might mess with the Host header somehow). EDIT: I think I have an idea (could be the webfaction cname + IPv6 - I'll look into it...). Should work now! Sorry about that. Thanks for letting me know!
- vhaenel 11y agoI personally like AWS Lambdas very much and am always looking for interesting use-cases, like this one. I don't quite get what your code is supposed to do yet, but I have some initial comments about the implementation, hope it's ok. There are two things that glare at me immediately, a) the vendoring of the redis code (including pyc files) and b) the need to define static credentials in the code itself. There are two little tools I would like to point your attention to, that may ease this pain. Here is a pybuilder plugin to make deploying lambdas much easier, it can generate a lambda-zip for you (including all dependencies) and upload it to S3 so that you can use it in a CFN template: https://github.com/ImmobilienScout24/pybuilder_aws_plugin https://github.com/ImmobilienScout24/pybuilder_aws_plugin The second is a tool to configure lambdas, by placing "things" (e.g. redis creds) in the description field of the lambda. This way, you can speparate code and configuration cleanly: https://github.com/ImmobilienScout24/aws-lambda-configurer https://github.com/ImmobilienScout24/aws-lambda-configurer
- gingerlime 11y agoThanks a lot! I was looking for ways to separate configuration from code, but couldn't find anything. Similarly "packaging" this so it's easy to share and for other people to use, I couldn't really find any common solution. I'll take a look at your suggestion! Much appreciated.
- vhaenel 11y agoYou are most welcome, our code is still really fresh so if you do hit any snags we'd love to hear from you! Any and all feedback is welcome!