Joseph Abrahamson
a724ad7c85
Made versioning follow git tags
2012-07-05 21:39:41 -04:00
Joseph Abrahamson
ba3fe8c00a
* README.md: Todos added
2012-06-28 13:38:45 -04:00
Joseph Abrahamson
18cbe1ab0c
* README.md: Added some usage examples
2012-06-28 13:33:51 -04:00
Joseph Abrahamson
885e66b39f
* README.md: Added README
2012-06-28 12:35:12 -04:00
Joseph Abrahamson
43a98bc67a
Exported the new serialze/deserialize fns
2012-06-27 13:01:32 -04:00
Joseph Abrahamson
0b639933b5
* src/snowflake.erl: Added serialization/deserialization methods.
...
snowflake:serialize/1 and snowflake:deserialize/1 are wrappers around
base64:encode. So from here out we pick base64 as cannonical
serialization format.
2012-06-27 12:08:52 -04:00
Joseph Abrahamson
accd056d53
* src/snowflake.erl: Export the uuid/0 type for other dialyzer targets.
2012-06-15 13:20:38 -04:00
Joseph Abrahamson
e7141fe1a8
* src/sf_snowstorm.erl: Fixed the uniqueness algorithm to ... actually work.
2012-06-13 12:19:31 -04:00
Joseph Abrahamson
6fba82ef48
Distributed resource discovery with pg2
2012-06-13 12:19:17 -04:00
Joseph Abrahamson
ffb4f1a7c9
Major changes to the package and design!
2012-06-13 01:43:18 -04:00
Joseph Abrahamson
30ac829e32
Changed attribution.
2012-06-13 00:18:27 -04:00
Joseph Abrahamson
b09242f731
* src/snowflake.app.src: Removed the sasl dep.
...
Having sasl around is necessary in RELEASES but apps themselves
probably shouldn't have it be a required app.
2012-06-12 19:24:31 -04:00
Joseph Abrahamson
e29a6acec0
* rebar.config: restored deps dir
2012-06-10 17:51:16 -04:00
Joseph Abrahamson
8339d313ef
* src/snowflake.erl: New "-spec" "@doc" style.
2012-06-10 10:26:50 -04:00
Joseph Abrahamson
87b3b79935
* rebar.config: Changed to centralized apps/ structure.
2012-06-10 10:26:36 -04:00
Joseph Abrahamson
3d1f18e04d
* src/snowflake.erl: Forgot to track the time of last snowflake.
2012-06-09 23:29:32 -04:00
Joseph Abrahamson
43625b57be
* src/snowflake.erl: Ensure uniqueness with sequencing.
...
Previous versions used a random number for the sequence ID ensuring
uniqueness stochastically, but that fails to scale. Sequential IDs
will break if more than 2^12 = 4096 snowflakes are registered in any 1
millisecond (hardware unlikely) while random IDs are virtually assured
to collide after sufficiently many events where 2 snowflakes are
generated in a single millisecond (hardware likely).
2012-06-09 23:27:27 -04:00
Joseph Abrahamson
25fb038bcc
* src/snowflake.erl: Truncation before random:uniform
2012-06-09 23:09:19 -04:00
Joseph Abrahamson
c008c0fce6
* src/snowflake.erl: Stopgap fix: randomization of the sequence number.
2012-06-09 23:07:48 -04:00
Joseph Abrahamson
d27e91ccfa
* rebar.config: Added coverage analysis.
2012-06-09 11:15:17 -04:00
Joseph Abrahamson
54a6536754
* test/snowflake_tests.erl: Added collision_test_
2012-06-08 20:21:12 -04:00
Joseph Abrahamson
766874bdff
Fixed Dialyzer type complaints.
...
Also added a basic uniqueness test.
2012-06-08 12:04:02 -04:00
Joseph Abrahamson
f78cb0fa6a
* src/snowflake.app.src: Configure the .app.src file.
2012-06-08 11:55:42 -04:00
Joseph Abrahamson
64d61c2638
* src/snowflake_sup.erl: Added the supervisor call.
2012-06-08 11:54:18 -04:00
Joseph Abrahamson
c52df0a568
* src/snowflake.erl: Initial snowflake code.
2012-06-08 11:53:33 -04:00
Joseph Abrahamson
340f036d2a
* test/snowflake_tests.erl: fake starter test.
2012-06-08 10:05:48 -04:00
Joseph Abrahamson
170299b7b7
Initial commit.
2012-06-08 10:00:39 -04:00