3 ms·
AFAIK the tweet id has four moving parts, a datacenter id, a worker id, a sequence number, and a timestamp (original poster mentions three). 3-cycle is definit
by pomber 6y ago
AFAIK the tweet id has four moving parts, a datacenter id, a worker id, a sequence number, and a timestamp (original poster mentions three).
3-cycle is definitely doable, it may take a week posting 100 tweets per hour or something like that. The biggest problem is twitter blocking the account (even when you stay under the API rate limit).
Code is here if you are interested, I ran it using GitHub Actions: https://github.com/pomber/conway https://github.com/pomber/conway
- OisinMoran 6y agoOoh that's very interesting! I've just presumably subsumed one of those into one of the others. Seems like there's a cycle-3 game of life creature called a pulsar that would be perfect for this: https://en.wikipedia.org/wiki/Conway%27s_Game_of_Life#/media/File:Game_of_life_pulsar.gif https://en.wikipedia.org/wiki/Conway%27s_Game_of_Life#/media...
- twodave 6y agoThey don't mention a datacenter id in the docs, but I wouldn't be surprised if it's changed since the docs were written: https://developer.twitter.com/en/docs/twitter-ids https://developer.twitter.com/en/docs/twitter-ids I implemented a .NET port of Snowflake where I work--being able to work with data without ever having to worry about an identity column is extremely freeing.
- karlding 6y agoThe Data Center ID has been in Snowflake IDs for a while. It's present in the original version of Snowflake that Twitter open sourced back in 2010 [0]. Looks like it was added in this commit [1] from August 2010. [0] https://github.com/twitter-archive/snowflake/blob/snowflake-2010/src/main/scala/com/twitter/service/snowflake/IdWorker.scala#L92 https://github.com/twitter-archive/snowflake/blob/snowflake-... [1] https://github.com/twitter-archive/snowflake/commit/ba2e67ea1cc3321bc57ab4fa013800df96d30f44#diff-a8e6c5c455239de42d57b7230c4657ab46740c301b89c4aece2496f05b609dcf https://github.com/twitter-archive/snowflake/commit/ba2e67ea...