18:43 Today was a different Monday as I had several meetings downtown Denver as I start a new cool Flex and maybe Rails project with ThoughtEquity. So I will have to catch up on AweUsageAnalyzr this week.
Last week I’ve added support to parsing usage logs with zone and architectures and this will require that I add these to the low level aggregation so that you can see for example how the price is aggregated for a specific zone. As the zone seem to currently only apply to the EC2 infrastructure I could also show the aggregation at the UI level. Let me think about that. Also I’m not sure if the architecture (windows, linux, …) should be used for aggregation.
Ok, I’ll be starting fixing a few small issues then I’ll be adding the incremental price calculation. A few fixes went in. Then I’m still bugged by Shibuya as I’m not sure it currently supports coupon code and I would love to provide the software for free to several type of users (those who blog about it, those who helped during the initial beta (too come soon…)). So I looked at e-junkie.com, kagi.com and of course was thinking about creating my own solution. The license system I prefer is where a user can enter a license number that was generated based on it’s name. So something more based on the honor system rather than relying on some server validation. This is common on many OSX applications and seems to work pretty well. So the only thing needed is when a user buys the application an email will be sent to with that license code. Then if I want to give a free version to someone I can just generate the code myself. Done.
20:39 Onto the incremental price calculation. The best way to code this is to write a few unit tests. For example for Simple Db you have the machine utilization priced as follows
First 25 Amazon SimpleDB Machine Hours consumed per month are free
$0.154 per Amazon SimpleDB Machine Hour consumed thereafter
And the data transfer out:
First 1 GB of data transferred out per month is free; thereafter:
- $0.170 per GB – first 10 TB / month data transfer out
- $0.130 per GB – next 40 TB / month data transfer out
- $0.110 per GB – next 100 TB / month data transfer out
- $0.100 per GB – data transfer out / month over 150 TB
So this is based on monthly usage where the more you use during the month the cheaper the price get. Internally I have the following data structures that define these prices:
‘BoxUsage’ : [ ONE, [{hour:25, price:0}, 0.140]],
‘DataTransfer-Out-Bytes’ : [ GIGA, [{unit:TB10, price:0.17}, {unit:TB40, price:0.13}, {unit:TB100, price:0.11} , 0.10]],
And internally I was just using the first price:
var usagePrice:Number = priceStructure is Array ? priceStructure[0].price : priceStructure as Number; //FIXME: instead of [0] use cumulateUsage
I also have the cumulated usage (cumulateUsage) available so I just need to verify in what bracket that usage falls
All right, it’s getting a little late and I’m moving home…Arrg…had a long todo list that I couldn’t postpone. So I’ll be back another day.