15 ms·
Gangnam Style breaks YouTube viewer count
- DigitalSea 12y agoWow, this is cool. One video was able to exceed a 32 bit integer thus requiring a change to a 64 bit integer, all caused by one man and one video.
- abc_lisper 12y agoAnd don't forget there are multiple copies of the same video there.
- DigitalSea 12y agoMy understanding is that the original is the only video that has broken the 32 bit integer barrier though, right?
- jaredsohn 12y agoI think the point is that the number of people who watched the video on YouTube is even larger than the number associated with this copy.
- return0 12y agoNot sure if he did everything all by himself. Regardless, it was bound to happen sooner or later as youtube is getting older.
- acqq 12y agoIt's just a 2 billion limit crossed, 32 bits can count up to 4 billion. Afterwards, they certainly don't have to change to 64-bits, just add a few bits more.
- srtjstjsj 12y agothere's no reason to pick any number between 33 and 63
- acqq 12y agoIf you do it at home, for your 10 videos, there isn't. At youtube scale, they certainly can benefit in having different number of bits in storage and transit and in the CPU. Only on the CPU, and only if you actually want to use the value in calculations the 64 bits is best step after 32. See also discussion here: https://news.ycombinator.com/item?id=8691291 https://news.ycombinator.com/item?id=8691291
- xanderjanz 12y agoShould have gone with unsigned ints, YouTube! EDIT: Which is the solution they apparently implemented, converting signed to unsigned at some higher layer.
- blahedo 12y agoSurely only temporarily, though. I mean, this is an exponential process---adding one bit only doubles the space, and it will not take another nine years before some video passes 4 billion.
- sillysaurus3 12y agoBy that line of reasoning, 15.75 years from now there will be a viewcount greater than 8 billion. ... and now I realize you may be correct, and that it's probably inevitable that a viewcount will not only exceed the total number of people alive, but will double or even quadruple it. Our total population is actually about 100 billion, but only ~7% of us are still alive. The shadows of the dead will be forever enshrined as YouTube view counts. Our shadows.
- mudge 12y agoWow, shit
- trothamel 12y agoYouTube is slightly under 10 years old. It's interesting how we're willing to project it forward into the far future. Not that i think that's wrong or anything - it's just that it's gone from nothing to essential in a fraction of a human lifetime. "We always overestimate the change that will occur in the next two years and underestimate the change that will occur in the next ten." - Bill Gates
- rattray 12y agoThat's a great quote, thanks for sharing
- 12y ago
- Aldo_MX 12y agoNext milestone: 19th January 2038 03:14:07 GMT
- ravenkat 12y agoAh, So many systems going to fail on that day for using epoch with 32 bit.
- ge0rg 12y agoTime to print our "Y2K38 consultant" business cards! :)
- Someone1234 12y agoAren't most Linux servers already 64 bit? And we aren't even close to 2020. I'm sure some software will need to be re-written between now and 2038, but I don't think it will be quite as bad as Y2K just because that was only a 15 year gap (Sometimes less), whereas this is over 24 years. I just think a lot of software will be naturally replaced between now and then. And while there will be a slight mad scramble to fix stuff at the last minute, I don't think it is Y2K-2.
- RadioactiveMan 12y agoIt'll definitely be interesting to see how many 32-bit embedded systems remain in use in 2038 - and what effect the overflow will have on their functionality. https://en.wikipedia.org/wiki/Year_2038_problem#Vulnerable_systems https://en.wikipedia.org/wiki/Year_2038_problem#Vulnerable_s...
- kevin_thibedeau 12y agoJust as many as all of the 8-bit systems in use today. There is no need, in the vast majority of cases, for wide data busses in embedded applications. 16-bit is going to die out, though, like the 4-bit and bitslice processors.
- btilly 12y ago
- jmount 12y agoNifty example. Billionaires, trillion dollar budges, billion-view celebrities, fast CPUs, and large memories: all reasons I am done with 32 bit architectures (old article of mine, but only on large memories http://www.win-vector.com/blog/2012/09/i-am-done-with-32-bit-machines/ http://www.win-vector.com/blog/2012/09/i-am-done-with-32-bit... ).
- diego 12y ago32-bit architectures have nothing to do with the size of different data types that have existed forever. We had 64-bit longs in 8-bit cpus. Also, there are perfectly valid applications that require numbers of 8, 16, 32 or 64 bits (or variable encodings with arbitrary precision). Petabytes, embedded microcontrollers, etc.
- agumonkey 12y agoTrue, the HP48 pocket calculator was a "4bit" cpu with 64bit fp-able registers.
- jmount 12y agoSorry I was unclear. 32 bits architecture can mean a lot of different things (buss sizes, address word sizes, and so on). Mostly I am done with small pointers (having to use segments to address all of your memory, or not being able to memory-map a disk sucks) and small counters (only being able to put signed 32 bit integers into a collection sucks).
- IgorPartola 12y agouint_32 strikes again! And one day we'll stop using it in favor of int_64, and all unique identifiers will be string, and all will be well. I remember when Twitter had rolled over their tweet ID's because they were using an int type that was too short. Should have gone with variable length strings to avoid that problem.
- rinon 12y agoVar-length strings are often too slow to manipulate and store. Better choice to use a fixed but large (64-bit) integer.
- michaelgrosner2 12y agoOr just use a GUID.
- deleted 12y ago[deleted]
- Someone1234 12y agoThat's 16 bytes instead of 8 bytes for a uint64 that still grants you 18,446,744,073,709,551,615 variations. Seems overkill, particularly if you actually generate GUIDs "correctly" in which case you've allocated 16 bytes but will only ever use a sub-set of them[0]. [0] https://en.wikipedia.org/wiki/Globally_unique_identifier#Algorithm https://en.wikipedia.org/wiki/Globally_unique_identifier#Alg...
- aikah 12y agoIsnt mongodb using "hashes" for ids by the way? I wonder how efficient it is and why they chose to do that.
- kevinschumacher 12y agoThey're not hashes. There's a few things embedded in the ObjectId (from the docs - http://docs.mongodb.org/manual/reference/object-id/ http://docs.mongodb.org/manual/reference/object-id/): ObjectId is a 12-byte BSON type, constructed using: a 4-byte value representing the seconds since the Unix epoch, a 3-byte machine identifier, a 2-byte process id, and a 3-byte counter, starting with a random value. You can actually convert the _id to/from a timestamp, which lets you do cool things like never keep a timestamp field (you can convert a datetime to an ObjectId and use that for comparison).
- alejandc 12y agounbelievable
- antimora 12y agoIt looks like it also broke the formatting on the number of the viewers: "2151501252". This string does not have thousands separators. Direct link to the video: https://www.youtube.com/watch?v=9bZkp7q19f0 https://www.youtube.com/watch?v=9bZkp7q19f0
- lstamour 12y agoIt's a joke. Hover your mouse over it to see why ;-)
- rkachowski 12y agoI saw this a few days ago, at first I thought it was an easter egg on youtube's part - saying "so many views we overflow!" But it's real?! It seems incredibly absurd that it could actually overflow, how are signed values useful for a count of views? How are you going to have negative views?
- spb 12y agoSay you're comparing the number of views between two different videos as (video_A.views - video_B.views). How do you represent that the second video has more views than the first?
- nly 12y agovideo_B.views > video_A.views
- tempestn 12y agoAnd what if you want to say how many more? You'd have to first check which one is greater, and then subtract in the right direction. The code is simpler if you just use signed integers.
- vegedor 12y agoYou could still typecast. The code may be simpler, but less explicit. In a storage heavy application it's still sensible to save bytes. Even if it is not a remarkable saving in this case, especially with compression algorithms reducing the impact. Assert will stop the program immediately, so you want to sensibly catch the error, at which point you need to know as much about the error condition as you need to know to use unsigned or casts correctly. So it's rather a question of taste, isn't it?
- bobbykjack 12y agoTo say "b has n more views than a", you need two operations whether you use signed or unsigned ints. Signed let's you say "these two videos have n different views" but, to be honest, it seems unlikely that you be doing either in so many places in your codebase, or so frequently during execution, to make the extra operation that significant.
- dogma1138 12y agoEvery time i check the most viewed videos on YouTube i get depressed and lose all faith in humanity. Landing on a comet gets you 250K views, anouncing the discovery of the higgs gets you less than 100K, latest twerking video or PewDiePie 2M at least...
- tedunangst 12y agoHave you considered that the repeat viewing value of the Higgs boson announcement diminishes rapidly?
- throwaway1979 12y agoNot sure why the pessimistic poster is being downvoted. Factoring for repeat viewers, it is sad how little society values scientific achievements. That said, I was up in the wee hours of the morning watching the LHSC start up and probably put more than 20 views on that song. Have ye hope :D
- spb 12y agoPretty sure it's getting downvoted because Hacker News doesn't want pseudointellectual superiority circlejerks overtaking actual technical discussion.
- cLeEOGPw 12y agoOne is little news report about recent scientific finding (that you don't even need to watch since there are tons of other better sources of that) with viral entertainment video, which is specifically made to get as many viewers as possible. These are not of the same type to be compared.
- nkozyra 12y agoScientific achievements don't necessarily make for entertaining video content. I'm sure most people would rather read about most scientific achievements (which these days are largely invisible or theoretical) than read a literary translation of Gangnam Style, too.
- Animats 12y agoThis is a minor problem. In the 1980s, the number of tradable things with ticker symbols in US markets passed 32767, and some new issues had to be delayed until it was fixed.
- ChuckMcM 12y agoThe interesting meta-point though is that an audience of 20 million viewers is a big hit [1] so a billion views is 20M people watching it 50 times or, 200M people watching it 5 times. And 2 billion views is double that. Put in perspective that is probably in excess the number of times the most favored "I Love Lucy" show has been seen. Or put another way, you've got a music video with the same eyeball impact as the highest rated television show ever. That says to me that either advertising on Youtube is a bargain or advertising on TV is way over priced :-) [1] http://tvbythenumbers.zap2it.com/2014/02/10/the-walking-dead-mid-season-premiere-delivers-15-8-million-viewers/235855/ http://tvbythenumbers.zap2it.com/2014/02/10/the-walking-dead... [2] http://en.wikipedia.org/wiki/I_Love_Lucy http://en.wikipedia.org/wiki/I_Love_Lucy
- derefr 12y agoOr advertising on TV seriously under-represents the total number of impressions over time through alternate consumption streams. Right now, supposedly "unpopular" shows are cancelled, and then immediately get a successful Kickstarter from what turns out to be millions of fans who happened to be watching only through Netflix, or iTunes, or DVD box sets. (Of course, none of these streams show the same ads the original broadcast does—but if you're a clever ad agency, you're already doing product-placement instead of interstitials most of the time anyway.)
- hsod 12y ago> Right now, supposedly "unpopular" shows are cancelled, and then immediately get a successful Kickstarter from what turns out to be millions of fans who happened to be watching only through Netflix, or iTunes, or DVD box sets. Can you name any examples of this? The closest thing I can think of is Veronica Mars which was Kickstarted many years later and raised ~5 million dollars from 91,000 backers to make a single movie. I think perhaps the "alternate consumption streams" viewers are not as lucrative as you think.
- coldtea 12y ago>The closest thing I can think of is Veronica Mars which was Kickstarted many years later and raised ~5 million dollars from 91,000 backers to make a single movie. That everyone regretted backing.
- SapphireSun 12y agoI love that they added an easter egg to the actual video. If you hover over the counter, it briefly shows you the negative overflow value. https://www.youtube.com/watch?v=9bZkp7q19f0 https://www.youtube.com/watch?v=9bZkp7q19f0 EDIT: I just realized that YouTube also posted a comment to that effect just below the video. :P
- leephillips 12y agoThe interesting question to me is why this particular video is so wildly popular. I don't generally go in for music videos, but I find this one fascinating and have watched it a dozen times. I read an article that tried to explain to non-Koreans like me the meaning of it all, and apparently there are several layers of parody and social satire. I think I love it for its combination of attitude, surrealism, bizarre humor, and self-mockery, plus the music that seems to fit magically.
- prawn 12y agoThe explanations of Korean parody/satire are largely irrelevant to its success given its popularity elsewhere, surely? I think it's the bizarre visuals that had it spread (why I tweeted it when it first emerged), then catchiness plus a repeatable dance move. It's the Macarena of its time in that regard. Being Korean might've given it crossover appeal into much of Asia? Just a guess.
- lmm 12y ago> The explanations of Korean parody/satire are largely irrelevant to its success given its popularity elsewhere, surely? I think they gave people who would otherwise have looked down on a silly craze an excuse to enjoy the video.
- Shivetya 12y agoin the words of my niece, its fun. She likes the silly man and while the sexual connotations of some things he does might make parents wince, they fly right over her head. She still has that innocence of youth. So why we can enjoy he irreverent humor, the sexual innuendo, she enjoys the silliness at her level. (plus she can do his horse stepping dance)
- orblivion 12y agoI love it because, in a world of fake pop musicians, this guy comes off as such a genuine goof. I can't help but like the guy, I'm very happy for him for this level of success on YouTube. And the song is super catchy. He's one of the very few pop musicians I appreciate (though so far, this is probably the only song of his I care for). The political satire makes it all the more compelling. I love the horse riding on top of a sky scraper.
- gavinpc 12y agoCan't quite tell if this is a joke, but here's a related "story about a bug" from Doug Crockford [0]: I made a bug once, and I need to tell you about it. So, in 2001, I wrote a reference library for JSON, in Java, and in it, I had this line private int index that created a variable called "index" which counted the number of characters in the JSON text that we were parsing, and it was used to produce an error message. Last year, I got a bug report from somebody. It turns out that they had a JSON text which was several gigabytes in size, and they had a syntax error past two gigabytes, and my JSON library did not properly report where the error was — it was off by two gigabytes, which, that's kind of a big error, isn't it? And the reason was, I used an int. Now, I can justify my choice in doing that. At the time that I did it, two gigabytes was a really big disk drive, and my use of JSON still is very small messages. My JSON messages are rarely bigger than a couple of K. And — a couple gigs, yeah that's about a thousand times bigger than I need, I should be all right. No, turns out it wasn't enough. You might think well, one bug in 12 years you're doing pretty good. And I'm saying no, that's not good enough. I want my programs to be perfect. I don't want anything to go wrong. And in this case it went wrong simply because *Java gave me a choice that I didn't need, and I made the wrong choice*. [0] https://www.youtube.com/watch?v=bo36MrBfTk4&t=38m https://www.youtube.com/watch?v=bo36MrBfTk4&t=38m EDIT: is there a reference for formatting comments? I've never been able to find one.
- jfmercer 12y agoI will always upvote anything related to Gangnam Style. Always.
- rodgort 12y agoMea culpa. I can't remember why I didn't fix that when I reloaded the entire schema. At least I widened the video ids.
- ecesena 12y agoI'd be curious to know how they discovered it. Were they monitoring it? Did someone report it? Did an alarm trigger? ...
- tn13 12y agoAm I the only one who thinks that Google is posting this bug(!) just to make the Google plus post popular ?
- prawn 12y agoProbably not the only reason, but it'd be a bonus viral thing for Google+ and YouTube.
- adad95 12y agoThere is Easter Egg in the video counter. Hover with your mouse. https://www.youtube.com/watch?v=9bZkp7q19f0 https://www.youtube.com/watch?v=9bZkp7q19f0
- thibauts 12y agoWhy the hell would you want to store a counter as a signed int in the first place ?
- maaku 12y agoJava?
- jawedkarim 12y agoWhen youtube launched in April, 2005, the initial source code was based on another completely unrelated website that I had worked on before, written in PHP and running on Apache and MySQL. It’s always fascinating how implementations of complex systems evolve.
- diroussel 12y agoWhat was the original site for?
- pavel_lishin 12y agoMaybe some sort of exchange site for Magic the Gathering cards?