Use perfect hashing, instead of binary search, for keyword lookup - <AUTHOR> https://www.postgresql.org/message-id/flat/E1ghOVt-0007os-2V%40gemulon.postgresql.org <comment><USER2> Some guy called Ilan Schnell wrote a python code generator which uses the very same algorithm, and comes with language templates for Python, C and C++ (and is easy to expand to others), and a dot file generator so you can visualize the graph:

[http://ilan.schnell-web.net/prog/perfect-hash/](http://ilan.schnell- web.net/prog/perfect-hash/)

He also has a superb illustrated explanation of the algorithm, a unique property of which is you get to choose the hash values:

[http://ilan.schnell-web.net/prog/perfect-hash/algo.html](http://ilan.schnell- web.net/prog/perfect-hash/algo.html)

I've been using it for years.

<comment><USER3> Ilan Schnell is not "some guy". He's the original primary author of the Anaconda distribution. One of the main reasons that so many data scientists use Python.

<comment><USER4> Well, he's just some guy, you know.

<comment><USER5> Gag Halfrunt! How's the brain-care biz doing these days? ([https://en.wikipedia.org/wiki/Zaphod_Beeblebrox](https://en.wikipedia.org/wiki/Zaphod_Beeblebrox) )

</comment></comment></comment></comment><comment><USER6> Binary search is a pretty bad algorithm. Sure, it runs in O(log n) time and it's more or less the best you can do to solve the general problem of finding something in a sorted list, but that does _not_ mean it's a good way to create an immutable list of things that can be searched using comparisons.

In particular, binary search has awful cache locality. Until you get very close to your target, you are essentially hitting a random cache line (and maybe even a random _page_ for large lists) for every comparison. This is bad. A B-tree-like structure that is never modified is very easy to make, and it will be much faster.

This came up with the ORC unwinder in Linux. We got something like a 4x speedup by changing from binary search to something a bit more clever to find unwind entries in the table.

<comment><USER7> > In particular, binary search has awful cache locality.

That makes me think of an idea which I'm certain can't be original, but I can't think of the jargon for what it's called.

Suppose you have a fixed-length sorted array, and its binary-search can be visualized as a tree. Traverse that tree in level-order and pop it into a helper-array, arranged much like a heap: The midpoint is first and all left and right children are proceed from there at offsets that you can predict.

So the original array [A,B,C,D,E,F,G] has a data-structure for searching of [(D,3), (B,1), (F,5), (A,0), (C,2), (E,4), (G,6)]

While the high-indexed items will get spread out, the most common and sequential activity occurs all together near the lower indexes, minimizing large jumps. Since each entry has the original index stored, you can always switch back to the initial array when a different strategy (e.g. linear scan) becomes preferable.

<comment><USER8> Take a look at ARRAY LAYOUTS FOR COMPARISON-BASED SEARCHING. TL;DR there are schemes like this called "Eytzinger" and "van Emde Boas".

[https://arxiv.org/ftp/arxiv/papers/1509/1509.05053.pdf](https://arxiv.org/ftp/arxiv/papers/1509/1509.05053.pdf)

The topic of arranging keys like this within index pages (or maybe elsewhere) has come up on the pgsql-hackers mailing list before:

[https://www.postgresql.org/message- id/flat/3B774C9E-01E8-46A...](https://www.postgresql.org/message- id/flat/3B774C9E-01E8-46A7-9642-7830DC1108F1%40yandex-team.ru)

</comment></comment></comment><comment><USER9> SQLite already implemented such mechanism[0] that determines whether or not a given identifier is really an SQL keyword. The result is a single static hashtable (C array of chars) with O(1) lookup result. This is the fastest known implementation for keyword lookup.

[0]: [https://sqlite.org/src/artifact/1f7f2ac1d9f262c0](https://sqlite.org/src/artifact/1f7f2ac1d9f262c0)

<comment><USER10> I'm not clear as to why that'd be faster than what we/PG has done. On a quick skim that allows for conflicts in the hashtable, which our new implementation doesn't? Ours is also a C array (albeit of offsets into one blob of string srather than the strings directly, the higher data density achievable due to that was worth it).

</comment></comment><comment><USER11> So is the idea here to generate a perfect hash table for the known set of SQL keywords in the parser rather than doing a binary search on the fly?

<comment><USER10> Correct.

</comment></comment><comment><USER12> FYI PostGres appears to have over 400 keywords, shown here:

[https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f...](https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/include/parser/kwlist.h;h=adeb834ce82422940cb89798ee18457c17c10853;)

The way I've seen most languages do it is something like this:

        switch (c[0]) {
          case 'c':
            if (strcmp(c, "case") == 0) return CASE;
            if (strcmp(c, "continue") == 0) return CONTINUE;
            ...

          case 'f':
            if (strcmp(c, "for") == 0) return FOR;
            if (strcmp(c, "friend") == 0) return FRIEND;
            ...

        }

I suspect that's good enough if you have a typical keyword list of say 20-100.

I just looked at Clang and it appears to build the list at runtime, using a regular hash table. I think this is because it has to handle C, C++, and Objective C, and they have different sets of keywords.

It seems like they could change it to use something like perfect hashing, and if that's even a 1% win, it would be worth it for the extra build complexity, since C and C++ compilation take up so many CPU cycles in the world.

See lib/Basic/IdentifierTable.cpp.

Although another problem is that the list of keywords depends on whether you're compiling C89, C99, C++98, C++11, etc. But that is a finite list so it seems like it still can be done with code generation ahead of time like PostGres does.

In Oil [1] I use re2c [1] recognize keywords, along with the rest of the complex lexing process, and it works well. It builds a DFA expressed in C code. The slower parts are elsewhere :)

EDIT: In theory, the DFA seems better than perfect hashing because you can bail on the second character if you get "xzoo" and no keyword starts with "xz". I think with perfect hashing yo still have to look at every byte.

The switch statement above also avoids looking at every byte in certain cases.

[1] [http://www.oilshell.org/](http://www.oilshell.org/)

[2] [http://re2c.org/](http://re2c.org/)

<comment><USER13> When parsing C, typedef names essentially introduce new keywords so the table is constantly changing.

<comment><USER12> Yes this is a good point! That's probably why it's dynamic in Clang and not done ahead of time.

FWIW I mention the C Lexer Hack here:

 _The Oil Lexer: Introduction and Recap_

[http://www.oilshell.org/blog/2017/12/15.html#toc_5](http://www.oilshell.org/blog/2017/12/15.html#toc_5)

<comment><USER12> Oops, now I agree with the people below: keywords and type names / identifiers are different :-/

</comment></comment></comment></comment><comment><USER14> We recently started using perfect hashing in V8's parser, also with measurable performance improvement (even over what we had previously, a first character jump table followed by linear search). It's always nice to apply that computer science education to a real world problem.

<comment><USER15> Could you provide a link to the implementation, please?

<comment><USER14> Just a wrapper around gperf:

[https://cs.chromium.org/chromium/src/v8/src/parsing/keywords...](https://cs.chromium.org/chromium/src/v8/src/parsing/keywords- gen.h)

[https://cs.chromium.org/chromium/src/v8/tools/gen- keywords-g...](https://cs.chromium.org/chromium/src/v8/tools/gen-keywords- gen-h.p)

</comment></comment></comment><comment><USER16> From the post:

"The time savings is indeed significant: preliminary testing suggests that the total time for raw [SQL] parsing (flex + bison phases) drops by ~20%."

Very impressive work!

<comment><USER17> Impressive?

They changed one textbook algorithm by another one. It turns out to be faster, but it might as well be slower for certain inputs (which might be common). Also, when they increase the number of keywords in the future, they might have to reconsider the implementation.

<comment><USER18> I think it's impressive, but maybe not for the same reasons as the OP : that means that keyword lookup accounted for at least 20% of total SQL parsing time. That's a surprise to me !

<comment><USER10> Note it's the "raw" parsing time. If you include the semantic parse-analysis phase, i.e. looking up table names etc, it's a much smaller portion.

</comment></comment></comment></comment><comment><USER19> Reading the discussion thread is fantastic. The postgres community culture definitely feels a lot different than some of the other open source projects I've seen.

</comment><comment><USER20> Can someone put this in lay terms for a casual postgresql user?

<comment><USER21> Parsing SQL is made faster.

Imagine a language with five keywords, for simplicity.

      keywords = ["AS", "FROM", "INSERT", "SELECT", "WHERE"];
      tokens = [As, From, Insert, Select, Where];

Now you have a token that you need to interpret:

      let token_raw = "FROM";
      let index = keywords.binary_search(token_raw);
      let token = tokens[index];

As a binary search, that's O(log N) string comparisons. In this worst case, it may try comparing with INSERT, then AS, then FROM before deciding index is 1, but for more keywords you have more comparisons.

With perfect hashing, you devise a single hash function that hashes all possible values uniquely. Now we have something like this:

      tokens = {914576: As, 73932: From, 5791456: Insert, 21596: Select, 86548: Where};

… with all the numbers calculated by hashing the strings at compile time. Then, instead of O(log N) string comparisons, you only need one hash and one hash table lookup:

      let token_raw = "FROM";
      let token = tokens[hash(token_raw)];

<comment><USER22> Why is this necessary at all? The lexer is recognising tokens with a finite state machine, so it already knows which keyword it's got.

<comment><USER23> The lexer knows it has a token, but it still has to match the token identifier to the corresponding keyword. Whether this happens at the lexing or parsing stage doesn't matter much, it's still expensive when strcmp is called a bunch of times for every keyword token.

<comment><USER22> Lexers don't do strcmps, they use a finite state machine to determine tokens. For instance if we have the tokens ALTER, AND, ANY, SELECT, FROM it will compile into a state machine like this:

      switch(str[i++]){
        case 'A':
          switch(str[i++]){
            case 'L': ...
            case 'N':
              switch(str[i++]){
                case 'D':
                  found token!
                case 'Y:
                  found token!
                default:
                  syntax error!
              }
           ...
          }
        case 'S': ...
        case 'F': ...
        ...
      }

Lexers already do this, and in each place where a token is found, it can know which token it was based on the DFA state that it's in.

<comment><USER24> That's the advantage of the state machine, but in such a table the lengths are already known at compile-time, and therefore the final check will be optimized to use a word wise aligned memcmp, which beats the branchy lexer code by miles.

<comment><USER22> I don't understand what you mean, can you elaborate? Are you talking about perfect hashing? Or are you talking about doing multiple strcmps? Or about doing the state machine until you reach a unique alternative, and match the remainder using strcmp?

What I was trying to say is that the lexer is _already_ doing a state machine, and the keyword can be determined from the state of the state machine, rather than re-determining it from the token substring itself.

</comment></comment></comment></comment></comment></comment></comment><comment><USER25> The optimal algorithm is the CHD algorithm - the function can use as little as 1.6bits per key. [http://cmph.sourceforge.net/papers/esa09.pdf](http://cmph.sourceforge.net/papers/esa09.pdf) There are implementations in Python: python chd perfect hashing and in go: [https://github.com/alecthomas/mph](https://github.com/alecthomas/mph) In addition to the author's C code.

<comment><USER26> Space optimal isn't necessarily the fastest.

Note that PostgreSQL code uses 2-graph instead of a more compact 3-graph version. The latter is noticeably more compact: 1.25 vs 2.1 factor.

</comment></comment><comment><USER27> I love seeing all the work and optimizations that get done on Postgres.

Very interesting.

</comment><comment><USER28> Isn't this just textbook perfect hashing? This is literally a primary use case for it.

<comment><USER29> Textbook here would be using goto-based DFA state machine (ragel can generate one).

<comment><USER30> If that would be faster, why not do that then?

<comment><USER31> Because they're using Flex & Bison, not Ragel. The latter is specialized for and excels at defining and applying finite state machines. But while the design of Ragel makes it relatively trivial to build ASTs during the parse, you still have to do it manually. Flex & Bison automate much more of the process of transforming an input stream to a tree. Dropping them and moving to Ragel would be a serious refactor.

FWIW, Flex also builds DFAs. It's just that the design of Ragel is so elegant that Ragel DFA machines are more flexible, easier to compose (both in terms of combining abstract machines and in terms of language-level integration), and yet still incomparably faster. While a straight DFA match should in principle be at least as efficient as a perfect hash[1], this is really only realized with something like Ragel or Intel Hyperscan. As awesome as RE2 is, the performance isn't in the same league as those two; ditto for JIT'd PCREs and re2c--neither are comparable to Ragel or Hyperscan.

[1] At least until the input set grows into the thousands or millions of items --at some point the size of the generated DFA grows faster than and overtakes the size of the generated perfect hash function.

<comment><USER32> Wouldn't a DFA be faster than perfect hashing here if only because non- keywords can collide with keyword hash values, so a strcmp is always going to be necessary regardless of the actual keyword differentiation?

I tried looking at the code to see if they were excluding non-keywords at some other stage - because then this would seem redundant?

<comment><USER24> No, too branchy and bytewise only. This PH is word wise mostly, and the keywords are longer, ~4-5.

<comment><USER32> Still, even the best strcmp is going to involve some byte checking unless the string is exactly divisible into large words.

Wouldn't the efficiency between the two methods mainly depend on the relative odds of non-keywords occurring?

</comment></comment></comment></comment></comment></comment></comment><comment><AUTHOR> see also: Joerg Sonnenberger: Perfecting hashing in NetBSD (P3B, AsiaBSDCon 2013) [1]

[1] [https://www.youtube.com/watch?v=87pUZYERkNQ](https://www.youtube.com/watch?v=87pUZYERkNQ) (youtube)

<comment><USER33> Thanks

</comment></comment><comment><USER34> That remind me, some years ago, I'd created a pull request for redis to use perfect hashing with gperf to parse commands. IIRC, the author turned it down because he was wary of adding the build time dependency on gperf.

<comment><USER24> That's awkward, because the gperf dependency is only needed every 2 years or so, when a new keyword is added. The genererated C code needs to be added to git, and only needs a regen if changed. I do that all the time via gperf or via some perl-generated perfect hash tables, eg for static keywords, Config tables, unicode tables, ... The memory win is always dramatic, like 20x better typically. I also use some standard gperf-fixup scripts for easier inclusion into my code.

</comment></comment><comment><USER35> If your keyword list is small, you can just tweak a Pearson hash function (i.e. random permutation) until you get the desired result: [http://burtleburtle.net/bob/hash/perfect.html](http://burtleburtle.net/bob/hash/perfect.html)

<comment><USER24> Yes, you can, but this approach is better. Pearson would beat CHM on very small CPU's (8-16bit) and it is not guaranteed to find a good permutation. With CHM it's much easier.

Most important thing is to store the keywords for the false positive verification in an continuous const char const* array.

</comment></comment><comment><USER36> Since there is a lot of discussion about alternative solutions to the keyword lookup problem I was wondering, why Tries were not mentioned yet.

Since the current implementation has to do a string compare after the hash, wouldn't a Trie be at least as fast? Am I missing something? Are there other disadvantages?

<comment><USER37> For the trie, you still would have to do multiple character comparisons (on level 1, on average about 13, I guess, given that I read there are 400 keywords, and 26 characters in the alphabet).

Presumably, hashing the string is faster. I think that partly is because it introduces fewer cache misses than walking a trie. Both a this and a trie have to walk the input string, but code using a trie jumps around the trie, while this code only compare to the keyword, stored in contiguous bytes.

Another reason might be that trie-based code is worse for branch prediction logic.

<comment><USER36> Regarding your first point: One possible implementation of tries uses an array with length "size of alphabet" to store the children of a node. So at each node it's just an offset into an array, not multiple character comparisons.

Of course your other points are valid. Thank you for your answer. So I gather the differences are rather subtle. I was wondering if I was missing something bigger.

<comment><USER37> Even assuming just a-z, that array will be mostly empty at lower levels, and most nodes are at lower levels. That's not good for avoiding cache misses.

There are tricks to counteract that (you don't store pointers to lower levels, for example, but offsets, because at typical sizes of a trie you can store them in way fewer bits), and I haven't timed any implementation for decades, but it would surprise me if such an approach would improve performance on lower levels.

You could use it at top level (basically replacing the trie with separate tries for each starting letter)

Also, the 'search for a character in an array' code can be sped up by using vector instructions nowadays (can't find a link for the exact code, but [http://0x80.pl/articles/simd-strfind.html](http://0x80.pl/articles/simd- strfind.html) may give ideas). Whether want to do that because of power usage concerns is a completely different can of worms.

</comment></comment></comment></comment><comment><USER38> Wouldn't decision trees be useful for constructing most efficient perfect hash function?

</comment><comment><USER24> perl, nice!

<comment><USER39> This looks scary: [https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f...](https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=src/tools/PerfectHash.pm;h=bd339e38a22db6975491652e3b638d50d12da301;hb=c64d0cd5ce24a344798534f1bc5827a9199b7a6e#l113)

Isn't there a better option than manually generating C code from a Perl script?

<comment><USER26> Not sure that scares you, code generation or a choice of scripting language?

If you want to avoid a code generation, you can generate a .cdb (constant database) file with the cdbw(3) C API and read it using the cdbr(3) C API.

cdbw(3) [http://netbsd.gw.com/cgi-bin/man-cgi?cdbw+3+NetBSD- current](http://netbsd.gw.com/cgi-bin/man-cgi?cdbw+3+NetBSD-current) cdbr(3) [http://netbsd.gw.com/cgi-bin/man-cgi?cdbr+3+NetBSD- current](http://netbsd.gw.com/cgi-bin/man-cgi?cdbr+3+NetBSD-current)

Some examples of .cdb files on NetBSD:

/usr/share/misc/terminfo.cdb /var/db/services.cdb

If you don't like a particular choice of a scripting language, you can adapt my Lua script:

[https://gist.github.com/alnsn/68f599bc9358fcee122d6175392d77...](https://gist.github.com/alnsn/68f599bc9358fcee122d6175392d779f)

Building and peeling a graph should be identical but the assign step is different. I use non-minimal not order preserving BDZ scheme while Joerg's code is based on the original CHM scheme.

Given keys A, B, C and D, CHM always maps them to values 0, 1, 2 and 3. BDZ, on the other hand, can generate values in a range [0, 2.1 * 4) and it doesn't preserve an order. For instance, one possible mapping in the BDZ scheme is 7, 2, 5, 1.

Alex

<comment><USER24> Nope, cdb is worse than this generator. We've used cdb before. cdb is even worse than gperf.

<comment><USER26> It's down to a quality of implementation. I can give you some hints on improving it if you're interested.

A tiny JIT code generator inside cdb would definitely bring performance on par with a generated C code but it's probably an overkill.</comment></comment></comment></comment></comment>


Apple Restricts 3rd Party Data in iPhone 4.0 - <AUTHOR> http://www.reynoldsftw.com/2010/04/apple-restrict-3rd-party-data-in-iphone-4-0/

<comment><USER2>
           1. All user data captured by an application must be
              for the sole use of that application only (like
              the Facebook app for example). The use of location
              based data for targeted advertising is strictly
              prohibited

           2. You may only send user data to a third party which
              is specific to the services/functionality of your
              application and also only if the user has given
              consent. Example: User updates status on Twitter,
              presses a "Send" button to confirm sending of said
              tweet.

           3. Sending device data to any third party for
              analysis is now strictly prohibited. Think mobile
              analysis services such as AdMob here. Presumably
              you can send this to yourself as the developer
              though.

1 & 2 are pretty reasonable. 3 makes sense given iAd.

<comment><USER3> No, it does not make sense. Instead of trying to build a better service, Apple is just cutting the lifelines of competing services. That is the poster case of unfair competition.

<comment><USER4> I don't think it's cutting competition -- these seem to be consumer protection. Say the popular flurry analytics tool decides they're going to perform background services to track users, you probably wouldn't even be able to opt-out to the tracking... developers adding the Flurry tool probably wouldn't even be directly aware of the invasion of privacy.

<comment><USER5> First, I don't believe that's technically possible to do without an explicit user opt-in, even if we wanted to implement it.

Second, I've never understood why people automatically assume the worst of analytics tools. No one assumes random web startups are selling their username, email and password combos to identity thieves, but if a startup collects some anonymous data for analytics, everyone's eager to assume it's both grabbing stuff that's personally identifiable and using it for some nefarious purpose. My pet theory ties this to our desire to feel important - everyone wants to believe their personal information's both valuable and interesting enough to be worth filching despite the obscene legal risks of doing so. However, it's not.

</comment></comment></comment></comment><comment><USER6> There's a web site that lists iPhone apps that send data to third parties. There really are quite a lot: <http://i-phone-home.blogspot.com/>

I was alerted to it when my own app appeared in their list with two entries -- one for using Flurry analytics, which is true, and another entry for connecting to my own server, which only happens if you're running a pirated version.

I was astounded that someone would be so concerned about their privacy being violated... by the software they stole from me. If they're downloading cracked software from strangers I'd say that's a bigger risk than apps phoning home.

</comment><comment><USER7> Hmm. So ... other developers might turn to old-school analytics packages, which install on their own LAMP / AWS / etc?

It's interesting to get all the data yourself, but it's a nightmare for client projects - suddenly you're manually responsible for supporting + maintaining all client projects ... forever.

(I made one last year, and I've only been using it for my own apps - it's very similar to Flurry - but I never liked losing the data to a 3rd party. Private - I didn't think anyone else would care enough to NOT use Flurry :))</comment>


Fuzzy Logic, Fuzzy Ethics - <AUTHOR> https://reallifemag.com/fuzzy-logic-fuzzy-ethics/ <comment><USER2> > Cyc still proved incapable of more demanding tasks, like digital image > recognition, or more complex gameplay, like chess or Go.

As Cyc wasn't designed to recognize objects in images, or play chess or go, it's hardly surprising that it proved incapable of those tasks.

</comment><comment><USER3> This article gets history approximately wrong. Yes, Cyc failed at its original goals, but it's still going, kind of, and as far as I know was never intended for image recognition. Fuzzy logic isn't used much in science because probability and statistics are the more usual ways to handle uncertainty.

Given its inaccuracy so far, I'm not sure the article is worth finishing?

<comment><USER4> To quote Wikipedia it is:

> attempting to assemble a comprehensive ontology and knowledge base that > spans the basic concepts and "rules of thumb" about how the world works > (think common sense knowledge but focusing more on things that rarely get > written down or said, in contrast with facts one might find somewhere on the > internet or retrieve via a search engine or Wikipedia), with the goal of > enabling AI applications to perform human-like reasoning and be less > "brittle" when confronted with novel situations that were not preconceived.

As explained by Douglas Lenat in a talk in the 1980s, he said his AI efforts had reached a point where there was a mattress on the road blocking him, and he decided to do something about it. As the article ([https://en.wikipedia.org/wiki/Cyc](https://en.wikipedia.org/wiki/Cyc)) alludes to in passing, it started out as an effort to capture the information _needed to understand_ all the entries in a 2 volume encyclopedia", "Cyc" itself is from encyclopedia.

Image recognition? Well, I suppose once you identify an object, Cyc might be useful to reason about it, but....

</comment></comment><comment><USER5> I remember reading about fuzzy logic in a discrete math book. It was exactly the same as basic probability theory. I think the article is overblowing it a little...

<comment><USER2> Not my recollection and I gave a lecture on it (in 1987): [https://web.archive.org/web/20081202004655/http://web.onetel...](https://web.archive.org/web/20081202004655/http://web.onetel.com/~hibou/ai- course/lec02.txt)

There are crisp sets, such as the set of French people. People are either French or not French. It doesn't make sense to say that someone's not very French, for example. But it does make sense to say that there's an 80% chance that someone's French, given other information about them.

The set of tall people is a fuzzy set. It does make sense to say that someone's not very tall. Tallness is a mapping from height to degree of membership of the set of tall people. So, for example, tallness(1.6m) = 0.0, and tallness(2.0m) = 1.0. To find out whether someone's quite tall, you could use the square root of tallness,to find out whether someone's very tall, you could use the square, and to find out whether someone's not tall, you could subtract their tallness from 1.0. And you might want to put a value on whether someone's quite tall but not very rich, for example, or make deductions given this.

Maybe at some deeper level fuzzy logic does reduce to probability theory, but the idea is quite different. It's about vagueness rather than about uncertainty.

<comment><USER5> Maybe that example could be reduced to probability by saying you had an ensemble of different classifiers, each with its own hard cut. Then, you would ask, "what is the probability that a randomly selected judge would call Sally tall?"

<comment><USER6> This doesn't really reduce it though, it just changes the problem from degree- of-tallness to probability-of-opinion.

If I round up a million and people and survey them about whether -1, 0 and 1 are natural numbers, the probability of their opinions don't change whether -1, 0 or 1 are natural numbers.

The probabilities of judgement might be 0.1, 0.55 and 0.92, with confidence intervals. But each of these numbers has a set membership function and each of them is crisp. In fuzzy sets these belong to the set of natural numbers as 0.0, 0.0 and 1.0.

The useful concept that fuzzy sets brought to the table was being able to reason formally over uncertain values. Classical logic operates on crisp sets: all men are mortal, Socrates is a man, therefore Socrates is mortal. Fuzzy sets allows you to retain all the tools of logic over a wider range of statements.

This is widespread in control systems, where being able to reason formally about vague concepts like "too fast" is very helpful.

It's also common in caselaw, which is absolutely jampacked with fuzzy sets. "The purchaser at arm's length without notice". "The reasonable person, similarly circumstanced". "A duty of care". Different sets of facts in a case are ultimately resolved into binding rulings by a judge, but the argument itself has to follow logically from facts, legislation and precedent.

The law is also rightly aware of probabilities, especially in civil cases. "The balance of evidence" is sometimes called "the balance of probabilities". In criminal trials, "beyond reasonable doubt" is mostly about deciding on what follows from the probabilities of the facts presented.</comment></comment></comment></comment>


The Gut Instinct Equation - <AUTHOR> http://www.codesqueeze.com/the-gut-instinct-equation/ <comment><USER2> you are only there when you have users and/or customers</comment>


Computing shortest distances incrementally with Spark - <AUTHOR> http://insightdataengineering.com/blog/incr-short-dist-graphx/

<comment><USER2> Yikes, I had to stop when the author mentioned MapReduce for computing shortest distance. That's one of the problems for which MapReduce approach is extraordinarily bad.

<comment><USER3> A better approach at the scale being discussed in the article would be to...?

<comment><USER4> What does 'scale' mean :) ? Solving graph problems are best done in-memory with a big machine (RAM!), otherwise you are an order of magnitude slower (at least) if you try to distribute. But if you really have no choice I would have a look if some of the graph databases has a good distributed model. My gut feeling tells me that even a bad approach there is faster than spark ...

<comment><USER3> I guess Titan DB would fit the bill: [http://thinkaurelius.github.io/titan/](http://thinkaurelius.github.io/titan/)

Facebook has blogged about scaling Apache Giraph to insane number of Vertices/Edges.

</comment></comment></comment></comment><comment><USER5> I don't think you have a choice, you'll have to use MapReduce if the data is too big to fit into memory. I believe that's what Facebook and Google do:

[https://www.facebook.com/notes/facebook- engineering/scaling-...](https://www.facebook.com/notes/facebook- engineering/scaling-apache-giraph-to-a-trillion-edges/10151617006153920)

[http://googleresearch.blogspot.com/2009/06/large-scale- graph...](http://googleresearch.blogspot.com/2009/06/large-scale-graph- computing-at-google.html)

<comment><USER2> Your 2nd link describes Pregel, Google's distributed graph database specifically built for these kinds of tasks.

They were using Map Reduce prior to that, but it was a cascading mess.

</comment></comment><comment><USER4> If you have a hammer everything looks like a ...

<comment><USER6> unicorn?</comment></comment>


Ask HN: Anonymous bank account? - <AUTHOR> Hi! Is there a possibility to make a anonymous bank account for recieving and sending small payments? Possibly connected with a anonymous debit card? <comment><USER2> You could look at using some altcoins like Monero.</comment>


A Day in the Life of My iPhone - <AUTHOR> http://bits.blogs.nytimes.com/2013/07/29/a-day-in-the-life-of-my-iphone/

<comment><USER2> Sounds kind of stressful to me. Do people who live this lifestyle fear they are missing out on the all the things their phones don't know about?</comment>


Painless NGINX Ingress - <AUTHOR> http://danielfm.me/posts/painless-nginx-ingress.html <comment><USER2> I think this blog post is one turn of the crank away from a truth we're all about to learn: don't hand roll your own Kubernetes ingress.

Dealing with the traffic handling between your users and your code is not a trivial problem. Like all good ops problems, you can fix it with good tools, deep knowledge of those tools, fine-grained observability, and smart people running all that.

This has been the recipe for a couple of really successful SaaS offerings. Individual servers? Datadog. CDN? Akamai / Fastly.

Disclaimer: I work at one of those companies, Turbine Labs, and we're trying to make ingress better. Here's a presentation from our CEO on Kubernetes ingress, and why the specification creates the problems that this blog post is trying to fix. [https://www.slideshare.net/mobile/MarkMcBride11/beyond- ingre...](https://www.slideshare.net/mobile/MarkMcBride11/beyond-ingresses- better-traffic-management-in-kubernetes)

</comment><comment><USER3> This is a great read. I know the _single cluster for all env_ is something that is sort of popular but it's always made me uncomfortable for the reasons stated in the article but also for handling kube upgrades. I'd like to give upgrades a swing on a staging server ahead of time rather than go straight to prod or building out a cluster to test an upgrade on.

I tend to keep my staging and prod clusters _identical_ , even names of services (no prod-web and stage-web, just web).

I'll set them up in different AWS accounts to clearly separate them and the only difference they have is the DNS name of the cluster and who can access them.

Edit: I suck at italicizing and grammar.

<comment><USER4> +100 to this. Why would any sane Op/Inf/SRE choose not to have at least account-level isolation - is it only a matter of cost due to under- utilization?

I prefer to have everything 100% isolated for dev / qa / stage / prod, and have process and tooling in place to explicitly cross the streams. This comes from a history of pain with random dev-to-prod (or worse, prod-to-dev) access and dealing with "real companies" with things like audit requirements.

Having them separate lets you do things like @odammit suggests, upgrade your cluster in staging without affecting your developers or customers.

If you don't want to go that far, you can set up separate AWS accounts that are all tied together via an organization, and you can set up IAM roles and whatnot to share your API keys between accounts. That gives you at least some isolation, but still lets you GSD the same way as if you have a single account.

<comment><USER5> > and you can set up IAM roles and whatnot to share your API keys between > accounts. That gives you at least some isolation, but still lets you GSD the > same way as if you have a single account.

Do not do this. You are defeating the purpose of account level separation if you're sharing API keys between accounts. Each AWS environment should be totally segregated from the others (cross-account IAM permissions only if you must), limiting the blast radius in the event of human error or a malicious actor.

Source: Previously did devops/infra for 6 years, currently doing security

</comment></comment></comment><comment><USER6> Cool read. I don't use Kubernetes but I learned a few things from this blog post that are applicable to my ECS environment.

The NGINX config part is tricky and it didn't come to mind that many programs will try to be smart about machine resources and it won't work in the container world as expected. This was a good reminder. OP didn't mention what Linux distro he's using and what are all of the OS-level configs he changed in the end of the day; I'd like to see that (was there any config not mentioned in the post?).

It's awesome that OP had lots of monitoring to guide him through the problem discovery and experimentation. I need more of this in my ECS setup. I didn't hop on the Prometheus train yet, by the way.

<comment><AUTHOR> > OP didn't mention what Linux distro he's using and what are all of the OS- > level configs he changed in the end of the day.

I'm using Container Linux, and yes, I did a few modifications, but I intentionally left them out of the blog post as someone would be tempted to use them as-is.

I'll share more details in that regard if more people seem interested.

<comment><USER7> I'd be interested to hear more.

</comment></comment></comment><comment><USER8> Shameless plug! The insights in this article are pretty deep but if you're looking for just a clumsy step 1 to setting up the NGINX ingress controller on Kubernetes, check out what I wrote:

[https://vadosware.io/post/serving-http-applications-on- kuber...](https://vadosware.io/post/serving-http-applications-on-kubernetes/)

The most important thing that I found out while working on the NGINX controller was that you can just jump into it and do some debugging by poking around at the NGINX configuration that's inside it. There's no insight in there as deep as what's in this article, but for those that are maybe new to Kubernetes, hope it's helpful!

</comment><comment><USER9> "Most Linux distributions do not provide an optimal configuration for running high load web servers out-of-the-box; double-check the values for each kernel param via sysctl -a."

This is not true, if you run Debian / CentOS7 / Ubuntu, out of the box the settings are good. The thing you don't want to do is start to modify the network stack by reading random blogs.

<comment><AUTHOR> > This is not true, if you run Debian / CentOS7 / Ubuntu, out of the box the > settings are good. The thing you don't want to do is start to modify the > network stack by reading random blogs.

I agree these are good defaults, but they are not meant to work well for all kinds of workloads. And yes, if things are working for you they way they are, that's okay; there's no need to change anything.

On the other hand, I personally don't know _anyone_ who runs production servers of any kind on top of unmodified Linux distros.

<comment><USER10> > On the other hand, I personally don't know anyone who runs production > servers of any kind on top of unmodified Linux distros.

You are so, so so lucky... lol. I say that as someone who has come across a desktop CentOS install on a server on multiple occasions, complete with running x-org and like 3-4 desktop environments to choose from, along with ALL of the extras. KDE office apps, Gnome's office apps, etc... HORRIBLE.

</comment></comment></comment><comment><USER11> NGINX also has their own ingress controller (in addition to the kubernetes community version): [https://github.com/nginxinc/kubernetes- ingress](https://github.com/nginxinc/kubernetes-ingress)

</comment><comment><USER12> Great read!

>> "Let me start by saying that if you are not alerting on accept queue overflows, well, you should."

Does anyone know how to effectively keep a tab on this on a docker container running nginx open source? I have an external log/metrics monitoring server that could alert on this, but I'm asking more on the lines of how to get this information to the monitoring server.

<comment><USER13> It sounded like there's a config directive to have Ingress Controller push all its metrics into Prometheus?

<comment><USER14> If it's helpful at all, here's a concrete example of a k8s nginx setup that exports-to/is-monitored-by prometheus: [https://github.com/bitnami/kube- manifests/blob/master/common...](https://github.com/bitnami/kube- manifests/blob/master/common/nginx-ingress.jsonnet) (Start at [https://engineering.bitnami.com/articles/an-example-of- real-...](https://engineering.bitnami.com/articles/an-example-of-real- kubernetes-bitnami.html) if you would prefer to approach that repo top-down)

</comment></comment></comment><comment><USER13> Am I correct in assuming that there is the Kube Service IP routing happening via iptables DNAT to get the request into the Kube running the Ingress Controller, and then the Ingress Controller is on top of that routing traffic to another Service IP which also has to go through the iptables DNAT?

<comment><AUTHOR> No. By default, the NGINX ingress controller routes traffic directly to pod IPs (the Service endpoints):

[https://github.com/kubernetes/ingress/tree/master/controller...](https://github.com/kubernetes/ingress/tree/master/controllers/nginx#why- endpoints-and-not-services)

<comment><USER13> Thank you. So there is a DNAT to get to the Ingress Controller but from there at least it's direct routing to the service endpoint(s)? Does that mean the Virtual IP given to the Service is basically bypassed when using Ingress Controller?

TLS termination at the Ingress Controller and by default unencrypted from there to the service endpoint?

I found this useful: [http://blog.wercker.com/troubleshooting-ingress- kubernetes](http://blog.wercker.com/troubleshooting-ingress-kubernetes)

Interesting discussion here: [https://github.com/kubernetes/ingress/issues/257](https://github.com/kubernetes/ingress/issues/257)

It seems like a lot of overhead before even starting to process a request!

<comment><AUTHOR> > TLS termination at the Ingress Controller and by default unencrypted from > there to the service endpoint?

We are doing TLS termination at the ELB (we're running on AWS).

> Interesting discussion here: > [https://github.com/kubernetes/ingress/issues/257](https://github.com/kubernetes/ingress/issues/257)

Great, thanks!

Regarding ways of updating of the NGINX upstreams without requiring a reload, I was just made aware of modules like ngx_dynamic_upstream[1]. I'm sure there are other ways to address this in a less disruptive way than reloading everything, so this is probably something that could be improved in the future.

[1] [https://github.com/cubicdaiya/ngx_dynamic_upstream](https://github.com/cubicdaiya/ngx_dynamic_upstream)

<comment><USER15> May I ask how you are automating the ELB/TLS configuration and how that ties into the Ingress controller? Do you somehow specify which ELB it should use? We're in a similar situation.

<comment><AUTHOR> You can annotate any Service of type LoadBalancer in order to configure various aspects[1] of the associated ELB, including which ACM-managed certificate you want to attach to each listener port.

[1] [https://github.com/kubernetes/kubernetes/blob/master/pkg/clo...](https://github.com/kubernetes/kubernetes/blob/master/pkg/cloudprovider/providers/aws/aws.go)

<comment><USER15> Thanks a lot, this will save us quite some time.

</comment></comment></comment></comment></comment></comment></comment><comment><USER16> Thanks for sharing your experience. I've got great insights to double check in my current environment.

Could you share which version of NGINX you found the issue with the reloads? Which version the fix was released?

PS.: I find it interesting/brave that you use a single cluster for several environments.

<comment><AUTHOR> > Could you share which version of NGINX you found the issue with the reloads? > Which version the fix was released?

I'm using 0.9.0-beta.13. I first reported this issue in a NGINX ingress PR[1], so the last couple of releases are not suffering from the bug I reported in the blog post.

> I find it interesting/brave that you use a single cluster for several > environments.

I'm not working for a big corporation, so dev/staging/prod "environments" are just three deployment pipelines to the same infrastructure.

As of now, things are running smoothly as they are, but I might as well use different clusters for each environment in the future.

[1] [https://github.com/kubernetes/ingress/pull/1088](https://github.com/kubernetes/ingress/pull/1088)

</comment></comment><comment><USER17> Great read! Especially the part on ingress class which I didn't know about. Would you mind sharing some of your grafana dashboards?

</comment><comment><USER18> I still don't really understand the benefit of an Ingress controller versus just a Service > Nginx Deployment.

<comment><USER19> It's the most confusing part of Kubernetes IMO. It's a load-balancer with a very restricted feature set so what is it good for?

The main issue it tries to solve is how to get traffic from outside of the cluster to inside. The ingress resource is also supposed to be orthogonal to the ingress controller so that if your app is deployed on AWS or GCP (in practice it's not true though).

With the nginx ingress controller the main advantage I see is that you can share the port 80 on the nodes between multiple Ingress resources.

</comment></comment><comment><USER20> ingress+overlay network confusion was the reason why we moved from k8s to Docker Swarmkit.

I still keep hoping for kubernetes kompose ([https://github.com/kubernetes/kompose](https://github.com/kubernetes/kompose)) to bring the simplicity of Docker Swarmkit to k8s.

Or will Docker Infrakit bring creeping sophistication first and eat kuberentes lunch ? ([https://github.com/docker/infrakit/pull/601](https://github.com/docker/infrakit/pull/601))

</comment><comment><USER21> Why does everyone use reverse proxies? It seems complex and inefficient. Why not serve xhr's and other dynamic content from the app server(s) and static content from a static webserver?

<comment><USER22> What would you use to provide a single endpoint to multiple instances of an app server?

<comment><USER23> There are scenarios where your app servers might be varied as well -- I've leveraged reverse proxies in front of a PHP application that had parts in .NET and parts in Go, for instance.

Technologies/competencies change as projects evolve, and being able to effortlessly reorganized and reroute is so profoundly powerful.

<comment><USER21> Sure, I'm symphatetic to this kind of "in the trenches" application of reverse proxies - just not doing it by default.</comment></comment></comment></comment>


How can we make our products known by lots of people? - <AUTHOR>

Plz answer me, thanks. <comment><USER2> Sorry, but there is no short cut. The best way to get the word out is to create something worth talking about.

There are usually just two reasons someone will talk about your company:

(1) You either have a phenomenal product; (2) You have phenomenal customer service.

If you're a first time entrepreneur focus on the customer service first.

In the very early stages, it's inevitable that your product is going to suck. Don't worry about it. Everyone's product sucks at the beginning. You can compensate for your sucky product by creating a culture of out-of-this-world customer service from day one. Send virtual hugs to your customers and give people a reason to spread the word about your company! Over time, continue to listen to your customers and keep iterating your product so that it sucks a little less each day...

When the quality of your product catches up to the quality of your customer service, you'll be in a great place.

</comment><comment><USER3> <http://laughingcomputer.com>

</comment><comment><USER4> Go to <http://startupli.st></comment>


I have a different view on stack ranking - <AUTHOR> http://theludwigs.com/2013/08/i-have-a-different-view-on-stack-ranking-than-the-spate-of-critical-microsoft-articles/ <comment><USER2> As someone interested in someday building a development firm on a partner/associates model, I really appreciated reading the different perspective in this article. "Up or out" is controversial but in certain kinds of companies it can make a lot of sense. It can be a way to adapt your company's organization and culture to the reality that most programmers only stay in a job for a few years anyway.

I think the author is right about people complaining in part because Microsoft is not growing. A corporation is compelled to expand in order to provide promotion opportunities to newer members.[1] If there were places for good- but-cursed-with-better-team-mates team members to go, stack ranking wouldn't seem such a problem.

[1] See David Maiser, Managing the Professional Service Firm, for this principle applied to partner/associate service firms.</comment>


Unnoficial design concept for Windows 9 - <AUTHOR> http://eiskis.net/windows9 <comment><USER2> "Manual window management is awful. Windows 8 ditched windows in favor of fullscreen apps. Traditional desktop window paradigms are powerful but obsolete."

Just NO NO AND NO, I can't be the only one who hates the new Windows interface, I want to be able to place my windows where I want them not be forced to use full screen for everything, or rely on some automated way to place them, I know better than the OS how and where I want my windows.

Sorry but I had to get that out of my chest, I can't deal with the new Windows interface, it annoys me.

Microsoft please stop trying to force a tablet/touch interface into a desktop computer it just doesn't make any sense.

<comment><USER3> I wholeheartedly agree with you. This "reinvent the classical desktop" trend really annoys me. Traditional desktop environments like Win 95 up to 7 or Gnome 2 are imho closest to the ideal, they have many many years of evolution behind them.

Mistakes that are being made:

1) Thinking that touch is superior to mouse, that touch is the future. That's simply untrue, mouse is quicker and more productive.

2) Focusing on first-time users too much, forgetting experienced users. Example - animations - nice at first, but get annoying quickly.

3) Trying to unify the tablet and the desktop interface. The optimal interface for tablets and for desktops are different.

For me the ideal desktop environment would be:

\- take the classical desktop concept

\- do a design update (Gnome 2 or Win 7 aren't especially pretty, the design looks outdated)

\- add some nice features without changing the whole concept, e.g. some tiling support, useful keyboard shortcuts etc.

<comment><USER4> I am reminded of the Henry Ford quote "If I had asked people what they wanted, they would have said faster horses."

The design idioms seen in Gnome 2 and Windows 7 are essentially highly refined versions of what existed on the Apple II OS. Personal computers and what we use them for have come a long way since then and it makes sense to redesign the UI to reflect this. Often this means getting your hands dirty and trying new things. Also - first time users are going to be around for longer than experienced users ;)

<comment><USER3> Yes, this Steve-Jobsian reasoning is exactly what leads to bad UI designs: "People don't know what they want and if they don't like our UI, it's in some way their fault."

I don't have anything against designers trying new things - unless they are trying them on me. For me, Win 8 or Gnome 3 is clearly a downgrade in terms of user experience.

</comment></comment></comment></comment><comment><USER5> "Manual window management is awful. Windows 8 ditched windows in favor of fullscreen apps."

Wrong. Manual windows management is just what a professional needs. The window manager will never know what is the best position and size for your programming editor/environment. It will never know where is the best position and size for your preferred debug window. And how to place and size your browser windows for API documentation.

Sure, a typical computer user needs only a full-screen browser window. But when you're really trying to get work done, Microsoft's "new" concepts are just wrong.

<comment><USER6> Manual window management on Windows can be awful. With decent window managers one can hold keys (alt in my case) and then drag or resize windows easily by dragging the mouse. They snap. And you can have more key combos for things like snap to left/right, maximise, minimise, always in front, etc.

Ever since getting used to this (in XFCE), using windows in Windows feels incredibly annoying and infuriating.

<comment><USER7> Windows 7 onwards has keyboard shortcuts - WinKey + cursors moves the windows to snap to half of the screen (top, bottom, left, right) and learn the Alt- Space-then X to maximise and Alt-Space then R to restore. If you happy using the mouse, Windows snap to the edges of the screen. There is also a utility you can get for shortcuts very similar to the Mac OSX ShiftIt tool but I can't remember the name of it!

<comment><USER8> I like the Ubuntu version where Alt-Space-X does maximize and restore (depending on current state). One shortcut less to learn.

<comment><USER9> Well, that'd be Win+↑ for maximize and Win+↓ for restore/minimize on Windows (contrary to what your parent writes, there is no built-in shortcut of making a window take up the top half of a screen).

</comment></comment></comment></comment></comment><comment><USER10> Am i the only one who does not like "touch" on a desktop/laptop. It is not the revolutionary input method that makes everything magical. I want to think in boxes (desktops) not a fluid streams of desktop space.

We need something else for the desktop.

<comment><USER11> It is even less appropriate on a server OS - I have no idea what they were thinking making Windows Server 2012 use the same touch oriented start menu replacement nightmare....

[Having to use a demo VM that has 2012 installed at the moment and I'm finding it _incredibly_ annoying].

<comment><USER12> Been using 8 for about a year and have no problem with the start screen without a touch interface - the workflow is pretty much identical to 7: Press the Windows key and type part of the name of what you want, with the bonus that it's significantly faster at giving results.

If you do end up having to select something in the menu, you now have more space to see what's available and modifying the layout to match your usage is a lot more accessible.

<comment><USER13> > Been using 8 for about a year and have no problem with the start screen > without a touch interface - the workflow is pretty much identical to 7: > Press the Windows key and type part of the name of what you want, with the > bonus that it's significantly faster at giving results.

A full-screen menu appearing on top of whatever I am working on completely breaks my flow. It's immensely distracting to me. As a result, I literally never use it. Instead I use Launchy [1] which is well behaved and keeps within the confines of a very small dialogue box.

That doesn't completely fix Windows 8, though - there's still a bunch of touch-orientated stuff that there's no native way to deactivate.

[1] [http://www.launchy.net/](http://www.launchy.net/)

<comment><USER14> I find Gnome 3 suffers the same issue. When I'm searching I know what I'm looking for 99% of the time, it's just a glorified accelerator combo, I don't need a full screen full of distractions.

</comment></comment></comment></comment></comment><comment><USER15> Am I right in thinking with this design you can only have one app as a point of focus at a time? So assuming I'm doing development, I can't be in my IDE, with a browser open on a particular stack overflow question, while having the app I'm debugging open in front of it all and some other app also in view showing diagnostics?

Instead, I'd have to flick back and forth between the apps like a headless chicken?

[Edit] Actually, take his example apps as a suggestion. He's running VLC to watch star trek, but can't watch it at the same time as say using the browser. In a traditional window set-up, you can just set VLC to stay on top and overlay a portion of the screen while you can continue doing something else (like using the browser).

Although the concept looks pretty, it almost seems to be a step backwards in available functionality.

<comment><USER3> All of the new desktop environments I know of (Win 8, Gnome 3, Unity) are steps backwards. The classical desktop concept (taskbar + floating windows) has tens of years of evolution behind it. If there was a better concept, it would have been invented before.

<comment><USER16> I'm sorry, but that's just a terrible way of thinking about things. If we assume things that have been around for a while have reached their apex by virtue of them having been around for a while we'd never make any progress.

<comment><USER17> Let's forget computers for a while and think about good ol' pen and paper. Ask yourself these questions:

      Do you use a desk?
      Do you use paper?
      Do you use folders?
      How big is your desk?
      How do you keep the papers on your desk?
      Do you hold up one sheet to read and one sheet exclusively?
      Do you keep a bunch of sheets side-by-side and compare them to each other?
      Do you like to open folders repeatedly or open a few papers from each folder?

No amount of design innovation can suppress the quirks and foibles of human nature. Quite often, aesthetic engineering survives an encounter with a user just as well as a battle plan does while encountering the enemy.

</comment></comment></comment></comment><comment><USER18> _Manual window management is awful. Windows 8 ditched windows in favor of fullscreen apps. Traditional desktop window paradigms are powerful but obsolete._

In any multi-monitor situation living without manual window management is awful. What they need to do is to offer a choice instead of forcing users down a specific path.

<comment><USER8> Fullscreen apps are especially fun on 27" 4k displays!

</comment></comment><comment><USER19> Manual window management isn't the perfect UI paradigm for anyone, regardless of input method. Being able to overlap by a few pixels isn't necessary for me.

A simple way to see where window management _should_ have gone is to look how it has changed within applications, where the resistance to change is lower. 15 years ago it was all MDI applications, where the idea that a doc has a window . Soon people realized that noone really needs to overlap their word documents windows, or move their photoshop tool dialog by 3 pixels, so more modern applications used docking managers to snap and tile their workspace together to use as much of the available area as possible.

As usual in the demos and mockups of both Win8 and this concept, the applications demonstrated happen to be simple communication apps, media players and so on. I'd like to see Photoshop, Visual Studio, AutoCad etc. that actually have a large workspace with several confgurable areas. I don't think it would be horrible to lose the movable windows, but I'd want something as powerful in return: Windows should manage the desktop the way a good desktop application manages its different areas.

<comment><USER20> Exactly. People need resizable panes, not overlapping windows.

</comment></comment><comment><USER21> Although this is a much better looking concept than what is currently available in Windows 8 I still do not understand how it solves anything for people who actually need to do development on these machines. I would hate to have to do development in an IDE such as Visual Studio or Eclipse while being restricted to this sort of interface.

Trying to force a tablet interface on a desktop machine is simply not acceptable. It makes matters even worse when you look at a server operating system such as Windows Server 2012. That is simply the biggest FAIL for an interface on a server OS I have ever seen.

<comment><USER22> Reminds me of [http://www.datamation.com/news/tech-comics- windows-8-1.html](http://www.datamation.com/news/tech-comics-windows-8-1.html)

I'm starting to get feeling, that Microsoft consciously abandons PC as a workstation with a fully functional OS model and moving towards dumb browser- only tablet-like terminal. And I bet that some cloud based, .NET like IDE for Windows developers is on their plans.

..and I'm sooo happy that I can do all my development work on Linux machine.

<comment><USER21> That sounds extremely likely if you look at the way they are going. I completely agree that I have never looked back since I started using Linux instead. If I truly need a Windows machine I will spin up a virtual machine.

</comment></comment></comment><comment><USER23> The best thing that could ever happen for Linux is for Microsoft to follow in the footsteps of Windows 8, with their design for Windows 9.

</comment><comment><USER24> I like it. I think the 2+ decades old idea of resizable and draggable windows is becoming a nuisance. With 5+ windows overlaying each others, the desktop becomes a chaotic mess.

People who say they need to be able to have multiple windows on screen should really be having multiple monitors if they don't already. Because even with high-res monitors, most productivity applications (IDEs,Excel,etc) are unusable anyway when not in full screen.

The drag&drop can be easily solved by dragging content from one app to another by dropping on their desired app icon on the taskbar. Or have dedicated share button to other apps like how Android does it.

<comment><USER2> I disagree, first of all I already have multiple monitors, and while my IDE is maximized on my main monitor, the secondary monitor has multiple windows with documentation, file manager and logs, or other stuff depending on what I am working on.

About the drag&drop I have a problem with that, supose the application supports more than one place to drop with different functionality, how do you solve that?

<comment><USER24> I used to do this too actually. Throwing a bunch of windows to my secondary screen. But over time, I realized I don't use them at all over time. Sticky notes are all over it and it was just a mess.

Now I try to have only two things open at once to streamline my work flow. Everything in excess, I try to have it my IDE when possible using plugins.

</comment></comment></comment><comment><USER25> It looks fancy and pretty and all that, but I would probably hate using it for the same reason I hate using Windows 8 right now.

Yes. Manual window-management is tedious and in an ideal world _should_ be obsolete, but I don't think this is the solution either.

Basically, I hate this automatic window-management more than I hate manual window-management and then we've not really gone anywhere useful.

For reference, I use tiling WMs in Linux and I'm happy with that, but I can see how that's _not_ a solution for most people. We need to reach a middle- ground somehow.

</comment><comment><USER26> Not too surprising to see lots of people here who would prefer a gradual evolution of Windows toward a touch interface. Bouncing back and forth between legacy Windows and "Modern" UI is obviously unsatisfactory. But, remember that Microsoft tried a gradual, familiar evolutionary approach three times previously and failed. Where were you then?

Now Microsoft has a new kind of failure. Is evolving it in this proposed direction or any other going to succeed? I think this proposal is good. It helps the "bouncing back and forth" problem. One problem is that Microsoft has different security models for "Modern" and legacy apps. (Never mind what kind of sense it makes to have a stronger and weaker app security model in the same OS.)

Here is a potential irony: Ubuntu Touch is an evolutionary approach to bringing a conventional implementation of the desktop metaphor to touch. I could see using an Ubuntu tablet. It probably won't be widely popular since it will have some touch-unfriendly legacy in it. But it might end up being a better evolutionary path than what Microsoft chose. But I'd know what I'm getting and probably be comfortable with it.

</comment><comment><USER27> I did my own design idea on the next version of windows, but didn't go so far as calling it "Windows 9" [http://pedalpete.github.io/windows_idea/](http://pedalpete.github.io/windows_idea/)

This design is much 'nicer' than mine, and probably more progressive. I would have liked to have seen what was returned in the search, and the layout of a search.

</comment><comment><USER28> As far as touchscreen-compatible window management goes, I'm not sure it gets better than ChromeOS.

For example, the keyboard shortcuts for snapping a window left or right let you customize how wide the window is after the snap. So for example, alt + ] snaps the window to the right half of the screen. The same shortcut again grows the window to 90% wide, then 80%, then 60%, and finally back to 50%. So if I want whatever I'm reading to be decently wide at the cost of letting my SSH window take up slightly less than half the screen, I can make that happen without a mouse. Or for a good responsive site, 20% or 30% of my screen is all the site needs.

In addition, when I have two windows each taking up 50%, hovering on the window edges they share them brings up an additional handle that lets me adjust the width of both windows simultaneously (if I want). Why can't Windows do that?

Finally, there's a keyboard shortcut for centering a window on the screen, which I am a total sucker for.

</comment><comment><USER29> I don't agree with Microsoft.. but i also don't agree with statements like "Just NO NO AND NO...I want to be able to place my windows where I want...I know better than the OS how and where I want my windows" and "Wrong. Manual windows management is just what a professional needs." At least, it is not true for me. Manually placing and resizing windows, lowering and raising them, that is sooo much mouse work which reduces my productivity, i'm happy that in 99% of my workflow i do not need to do that kind of stuff anymore, but when i want the freedom i can just fall back to that ..

I think Microsoft got the point with their tablet-orientation fullscreen-only- apps, driven by touchscreen interfaces, but agreed, forcing everyone into that (currently coupled with the dual-old-desktop-mess) is ridiculous, user-hostile and typically Microsoft. This inofficial Windows 9 concept does not really help either.. IMHO they are looking for what tiling window managers ([http://en.wikipedia.org/wiki/Tiling_window_manager](http://en.wikipedia.org/wiki/Tiling_window_manager)) have implemented since a long time (without being driven by the touchy- concepts), without taking away any freedom like Microsoft always does it, because MS thinks they know what's best for their users? :

• Provide automatic placement for windows, fullscreen, halfscreen, spiraled, any layout which makes sense for you. • Have the nice side-effect that they are much more controllable by keyboard only, increasing productivity even more (at least for developer's kind of work) • Provide the freedom, that if you want to, you can just take windows and resize them freely like default window managers

Introducing and playing with new concepts still is the right, however i think MS should stop forcing users into every new concept, but leave the freedom for the advanced user to customize to their style... if i have ever to go back to windows i hope there is a tiling window manager with the features i am accustomed to ;)

</comment><comment><USER30> My one complaint about Windows 8 is that I can't use Win+# to switch to the fullscreen apps. I wouldn't even mind the fact that they took up the entire screen if I was able to navigate to and from them with ease. The way to navigate between the full screen apps is with Win+tab which forces me to use two paradigms for task switching. I'm sure this irks alt-tabbers as well.

</comment><comment><USER31> I was wondering what the difference is between the hatred for the win 8 change compared to the change from win 3.x to 95 (nt 4)?

Was it just because not so many people used win 3.x and so ms could change it without so much moaning?

If metro was developed instead of the windows 95 start menu, would it have been hated as much??

</comment><comment><USER32> It's optimistic to think VLC will be available for Windows 9. It's still not out for Windows 8.

<comment><USER33> My Windows 8 laptop next to me is playing a video using VLC.

What you meant to say was that VLC does not exist for the MetroUI (I forget what that POS is called these days).

<comment><USER34> Here you go - VLC doesn't have a Windows Store App.

</comment></comment></comment><comment><USER35> Windows had to give us choice to use old windows 7 style, or windows 8 style for touch. Right now for enterprise I see, that for companies it is no difference to teach how to use Ubuntu or new windows 8. Windows 8 put OS from leader position on PC to mobile OS for touch devices.

</comment><comment><USER36> Here is what I want from an OS UI:

[http://williamtpayne.blogspot.co.uk/2013/10/gui-ng- desiderat...](http://williamtpayne.blogspot.co.uk/2013/10/gui-ng- desiderata.html)

Perhaps not to everyone's taste, but hey-ho.

</comment><comment><USER37> <useless>

"Personalization

Users are given control over the desktop background that gives personality to the user experience."

\--

What the fuck???!

If they advertise like that then why don't they just sell Windows 95 again?

</useless>

</comment><comment><USER38> This is almost done with Rainmeter and [http://omnimo.info/](http://omnimo.info/). Pretty useful on my B121 tablet.

</comment><comment><USER39> Not a fan of this design. Its hard to distinguish what UIs go with what and everything generally seems all thrown together in one UI with no demarcation.

</comment><comment><USER40> This is somewhat like the 10/GUI concept from 2009: [http://10gui.com/](http://10gui.com/)

</comment><comment><USER41> I want more desktops not less. Not having native support for multiple desktops is a shame in 2013.

</comment><comment><USER42> I fail to understand how this is any different from a skinned Android tablet interface.

</comment><comment><USER43> This would be interesting to see as a linux distro, and more realistic to boot (zing).

</comment><comment><USER44> Please make this for Ubuntu.

<comment><USER45> I think Linux would be the perfect place to test these assumptions, or concepts. There have been some distros that implement new looks (ElementaryOS). It would be an interesting idea to implement these concepts on-top of Linux.

</comment></comment><comment><USER46> There's also a more intuitive eavesdropping functionality for NSA agents in the new Windows OS.</comment>


Ask HN: Compiler frameworks for AST Transformations? - <AUTHOR> Are there any compiler frameworks that tools to parse code (C/C++ at a minimum), and analyse, transform, and manipulate the AST?
We've been using the Rose compiler framework (http://rosecompiler.org/) in our group for some time. However, it's not my favorite and I'd like to use an alternative.
I've been wondering if there was something similar that was better maintained and supported. LLVM seems like an obvious choice, but it's too low level to be really effective. We would end up writing a lot more analysis to discover things that are obvious at high-level representations ("Is that a for loop?").
Looking for something: 1) very accessible; other people should be able to build and use my transformations with relative ease. 2) well documented; no mysterious functions and types that I have to use. 3) easy-to-use/intuitive (for compiler writers).
Thanks! <comment><USER2> I think it is great that you are into this kind of stuff. I am as well, as I find it one of the most interesting things to do. "The AST" is subjective, however. We know it is a tree data structure, but most compilers implemented it differently. Also, AST generation is typically derived from the parsing stage, then the AST is taken to be compiled. I think you should look into GNU Bison.

<comment><AUTHOR> Bison is a great tool for parsing grammars.

However, I'm more looking for a tool that, on its own, can be used as a full compiler, with the added ability to put myself in the middle of the front and back end.

LLVM has a similar ability where you can develop a pass over the IR and manipulate it.

</comment></comment><comment><USER3> [https://github.com/cil-project/cil](https://github.com/cil-project/cil)</comment>


IPad doesn't obey DHCP lease expiration under certain conditions. - <AUTHOR> http://arstechnica.com/apple/news/2010/04/ipad-fails-networking-101-how-to-earn-it-a-passing-grade.ars

<comment><USER2> "41 iPads have been seen and 22 have exhibited the problem, eight to the degree of having been blocked from further access to the network"

Presumably they all have the same software, so they're not banning machines that exhibit a problem so much as those whose owners behave a certain way.

</comment><comment><USER3> Can this be patched through a software update?

<comment><AUTHOR> It may be a firmware update, but there wouldn't be many technical reasons they can't correct this. Worst case is that they could shut down their network stack before going to sleep (what ever you wish to call that mode).</comment></comment>


3rd Circuit Protects Public School Students' Off-Campus Social Media Speech - <AUTHOR> https://www.eff.org/deeplinks/2020/07/historic-opinion-third-circuit-protects-public-school-students-campus-social-0 <comment><USER2> That link didn't work for me. Try this one: [https://www.eff.org/deeplinks/2020/07/historic-opinion- third...](https://www.eff.org/deeplinks/2020/07/historic-opinion-third- circuit-protects-public-school-students-campus-social-media)</comment>


Can I Interest You In a Stem-Cell Burger? - <AUTHOR> http://www.unlimitedmagazine.com/2011/03/can-i-interest-you-in-a-stem-cell-burger/ The wild world of in-vitro meat. <comment><USER2> Yum, sign me up! Meat without the animal cruelty and unsanitary conditions sounds like a win for everyone involved. It may also end up being far cheaper than 'natural' meat, due to economies of scale and fewer processing steps.

On a side note, we'll be able to have chicken grown in steak-sized and steak- textured pieces, or have a beef drumstick, or REAL turkey bacon. The future has so many cool new recipes!</comment>


Ask HN: If I build it, will you pay? (Open photo sharing service on S3) - <AUTHOR> This idea has been stirring in my head for several months but today in the car I realized the vision in full.
TLDR; If I build a photo sharing service based on Amazon S3 (and CloudFront) would you pay to use it? You'd upload photos through the service into your own Amazon S3 bucket - meaning you have 100% control over the photos. Low resolution copies (for sharing) will be stored on your CloudFront distribution.
<comment>--
The details
The state of photo sharing is absolutely horrible. Most people upload photos to Facebook and I won't even go into the 1001 reasons why their photo service is abysmal. Some use Picassa or Flickr, while better than Facebook they still control the destiny of your photos. Flickr's got APIs - so that's a start but it's not trivial to get all your photos and their meta data (comments, tags, etc).
What I'm envisioning is a frontend for YOUR photo collection that resides in an Amazon S3 bucket you own. A good interface to upload photos, share them, and control privacy. The whole point of this is to be open and let you retain ownership of your photos.
Lots of potential features on the roadmap but what I described is phase I.
My guess is the cost would be in the $1-2 / month range + any S3 costs you'd incur yourself. I'm hosting about 18 GB of photos and it costs me around $2 / month.
</comment><comment>--
The team (me)
Who the heck is this dude and what are his qualifications? My website is at http://www.jaisenmathai.com. I was a co-founder of a photo sharing startup back in 2004. We shut down shop in 2007 but you can see it here: http://photos.jaisenmathai.com/users/jmathai/photos/tags-tavin,favorites/.
I'm pretty positive I can build the first version of this out in a couple weeks (with a basic UI).<p>If you're a graphic artist and want to provide ongoing design services then you can have an account for free :). </comment><comment><USER2> Wouldn't pay. I don't feel the pain from any of these photo sharing service. The storage is not the issue, I think its distribution. Imgur, flickr, picassa, facebook.. all work fine in my opinion. The magic of facebook is that I can upload and have to do nothing for distribution because all my friends and family can already see it.

If you are speaking of a tool for developers then I would like to know more details, but yes I have paid for image services that will resize and dump them into my bucket.

<comment><AUTHOR> Sounds like you might not be the target. If you're not worried about the durability or long term management of your photos (and owning them as much as you can) - then Facebook is perfect with it's distribution.

The idea of making it available for developers is an interesting one. I hadn't considered it but if there's enough interest to build it out for some consumers then making it work for developers shouldn't be a stretch.

</comment></comment><comment><USER3> I would definitely pay for a service like this. It would be even more convenient if you handled billing for S3 for me while me still retaining ownership. I would pay a premium on top of S3's services. It would also be neat if you could frame this as a Mozy or Backblaze for photos only... Emphasize storage rather than community like Flickr and Facebook do.

I don't know if I'm your target demographic though:

> Hobbyist photographer

> Flickr Pro account user

> 29 years old

> Upload ~15-20 photos a month mostly because I use flickr as a showcase > rather than storage

> Shoot in RAW

EDIT: Also... Please do not use a dark background. Or, if you do, please give users the option to customize the theme. Dark backgrounds are extremely irritating to me.

<comment><AUTHOR> Yea, a Mozy for photos is a decent way of looking at it.

I haven't even got to thinking of how the site would look but I presume it'd be theme-able and let you provide your own CSS if you wanted.

I really don't want to dictate anything about your photos. I want to provide the utility of uploading/resizing etc.

I do this for myself and after 6 years and a few thousand photos I realize how valuable it is. I also know that the chances that my kids will be able to see their photos is orders of magnitude higher than if I were uploading them to Facebook.

Just want to spread the love :).

</comment></comment><comment><USER4> Short: I would pay.

Long: I would love to see some features that other sites haven't put in yet.

1\. The ability to upload from a computer or via e-mail (from a cell phone, for example).

2\. The ability to automatically repost pictures to specified Facebook galleries and Twitter.

3\. Robust tagging/sorting/searching systems.

?. An offline system with a searchable database that you could synch with the cloud system would be amazing, so you could organize photos on your computer in the same way and keep everything synched up.

Edited for clarity.

Another thing that would bring over a lot of people I know is the ability to automatically import flickr/picasa photos and tags. Most people won't move from established galleries because it's such a pain to relocate all of that history -- they're locked in.

<comment><AUTHOR> Thanks for the feedback. All of those are great features. #3 is my favorite though :). Ideally it would be open enough that adding "modules" would be easy. Not exactly sure what that means, perhaps an API with OAuth so others can build apps. Really interesting...but definitely phase II.

<comment><USER4> I feel bad saying this, but I'd also want some kind of guarantee or something that the service wouldn't shut down in a few years, since you mention that you did this before and shut it down.

<comment><AUTHOR> Well, that's part of the beauty of this. I can't guarantee the service wouldn't be shut down but you're in the same boat with any other provider you go with.

The essence of this service is that even if I went AWOL you'd still have your photos and meta data in an easily accessible form (your S3 account and a SQL dump of the meta data).

I'd love to open source the "front end" code so you could port it simply by running it on your own server. The actual photos would never have to be migrated since....tada - you own it and it's not bound to the service I'm offering to provide.

<comment><USER4> It sounds like you're trying to sell both the service AND the software. Why not just offer to sell the software to anyone who wants it for X dollars, and for the people who don't want to host it themselves, run it for them for Y/mo?

<comment><AUTHOR> I hadn't really given it too much thought. The intention wasn't to make money off of it. Some money to cover expenses but I'd love to not be the one managing it, having nodes of these sites all around the web.

But that's lofty - so a hosted solution is a bit easier to swallow - and I'd be happy doing that as well and breaking even (time/energy/stress, etc).

</comment></comment></comment></comment></comment></comment><comment><USER5> You need to eat the S3/CloudFront costs and bake it into the price. Almost nobody has an AWS account. The people that do are either using it for work/startup stuff, or are like me and get annoying $0.12 charge every month.

<comment><AUTHOR> I wouldn't have to bake that into the price. If you signed up you would have your own AWS account and get billed for storage directly.

<comment><USER5> You don't get it. Getting billed for storage directly is not a feature 99% of the people on the Internet want.

Make it simple for your users and don't get cute with pricing models.

<comment><AUTHOR> I do understand what you meant but wanted to clarify a few things.

1) This is really for 1% of people on the Internet (possibly less). Facebook is great for the majority but not for people who want to retain ownership and original versions of all their photos that they are confident they can get anytime they want.

2) I agree about making it simple. But I am not really interested in making it simple at the cost of the main vision of this idea - letting users "own" the photo (meaning it resides in their own amazon bucket). Unless there's a way to use FPS to do this I probably wouldn't consider "simplifying" it the way you mentioned.

This is more of a pro bono idea than one I wanted to or intended to make a lot of money on. I already have those ideas I'm working on :).

</comment></comment></comment></comment><comment><USER6> Idea is interesting. I don't think I would pay for the service, granted I'm not your target audience (I don't use flickr, photobucket, etc.).

Also, I'd go with $12-$24 a year instead of $1-$2 a month. Just looks nicer, and converts a lot better.

<comment><USER4> Unless he went with $1.20 a month and pointed out that it's only 10 cents a month (echoes of Sprint's old 10 cents a minute ad). Then not only would he have a robust feature set to compete, but also a pricing advantage over Flickr.

</comment></comment><comment><USER7> This sounds similar to what Jungle Disk offers, but focused on pictures. The way they approach it is that they give users 5GB per month for a $2 per month fee for storage. On average, this should cover the AWS costs and leave some margin for Jungle Disks. I think any additional storage charges after that are billed at the rate of AWS or Rackspace since they are compatible with both (I believe they are owned by Rackspace). I think this approach makes it less intimidating to consumers who have no idea what AWS is.

<comment><AUTHOR> There are plenty of services like that - which I'm not terribly interested in copying or spinning off as a "photo" version.

I do this myself for my own photos and thought others would enjoy and pay for a service that did the say. I love that my photos are backed up on S3 and it's not someone else's Amazon account. I own it and can do whatever I want with my photos.

I agree that it's a bit intimidating. My original idea was to see how many technical people were interested - hence posting the question on HN :).

</comment></comment><comment><USER8> I wouldn't pay. I don't even know 1 of the 1001 reasons you think Facebook's photo service is abysmal.

Who is the target user for your service?

<comment><AUTHOR> Here's a good answer by someone else :). <http://news.ycombinator.com/item?id=2184735>

As far as target, I'd presume people who want to keep control of their photos and keep them for the long term (10+ years). Who knows what's going to happen with all those Facebook photos 10 years from now.

</comment></comment><comment><USER9> Can you list a couple of the worst parts about Facebook's photo service?

I'm not a Facebook user, but I do know that photos are one of the _main reasons_ why people use (love, are addicted to, etc) it.

Maybe even compare your improved solutions to the poor features of Facebook's service. Thanks, and good luck!

<comment><USER3> It's vertically integrated to be social. As such, the following are not considered important:

> Original photo size (additionally, optional sizes)

> EXIF data

> Compression

> Sharing as a link, embed, BBCode, etc. -- anything outside of Facebook can > be done by copying image URL, but that URL can change without a moment's > notice.

It's designed for people who take snapshots, not for photographers or artists.

<comment><AUTHOR> Yea, that's a pretty good synopsis :).

</comment></comment></comment><comment><USER10> Does Dropbox have an API that gives read/write access? Being able to drop photos into my dropbox and having them resized and uploaded automatically would be killer. Also much more user friendly than AWS for non geeks.

<comment><AUTHOR> Unsure if Dropbox has an API to do that. The original target was geeks which is why I asked on HN.

Dropping photos into a directory and having those resized and uploaded is just a script that looks for photos in a given directory and posts them to any of the photo sharing sites with an API, no? But then you don't really own the storage of your photos (or at least aren't billed for it - which implies some level of ownership).

</comment></comment><comment><USER11> I would probably pay. My dream solution would back up my pictures and the let me share the ones I wanted to share. (Not a photo hobbyist, just like to take lots of pictures.)

<comment><AUTHOR> That's precisely what this service would solve. The photos are backed up on S3. You don't really ever have to worry about switching services or anything since it's bound to your Amazon account and your S3 bucket.

</comment></comment><comment><USER12> can't you share photos on dropbox? and you would still have complete access to your original files.

<comment><AUTHOR> Probably, but you don't really have a great interface for photos. Dropbox is for files and works for photos but photos have such different properties than most files.</comment></comment>


Lessons for Consumer-Focused Startups (from Accel Venture Partners) - <AUTHOR> http://www.scribd.com/doc/196036/178375296TheElusiveGreatConsumerExperience

<comment><USER2> Just like everything on scribd, this would be much better as an HTML document.

</comment><comment><USER3> Jesus... what's up with reinventing the wheel? Just use a normal HTML, for god's sake: we are people, not printers. I already developed a habit of skipping PDFs while surfing, now I'll need to start avoiding links to scribd.

Why work so hard to make your product worse?

</comment><comment><USER4> I agree: overnight success may be programmed over a weekend, but it also has to be grown with care like a garden.

I've heard "buy some customers" a few times myself, and while it's possible for me to think like that, who as a customer would want to be treated that way? Not me. This article is an excellent, level-headed summary.

-Matt</comment>


Binding of Isaac: Afterbirth 109 controversy - <AUTHOR> http://kotaku.com/the-binding-of-isaacs-new-secrets-sound-completely-nuts-1740324627 <comment><AUTHOR> Just as a clarification: The developer realeased a patch on the 109 hour.</comment>


Hundreds of apps have hidden tracking software used by the government - <AUTHOR> https://www.androidauthority.com/government-tracking-apps-1145989/ <comment><USER2> DUH

We have known this for decades</comment>


The images and stories behind the most epic game tattoos on one man - <AUTHOR> http://arstechnica.com/gaming/news/2010/12/the-images-and-stories-behind-the-most-epic-game-tattoos-on-one-man.ars <comment><USER2> How is this on topic?

On-Topic: Anything that good hackers would find interesting. That includes more than hacking and startups. If you had to reduce it to a sentence, the answer might be: anything that gratifies one's intellectual curiosity.

Off-Topic: Most stories about politics, or crime, or sports, unless they're evidence of some interesting new phenomenon. Videos of pratfalls or disasters, or cute animal pictures. If they'd cover it on TV news, it's probably off- topic.</comment>


Show HN: Instant map chat using Google maps and socket.io - <AUTHOR> https://round.io/chat <comment><USER2> Interesting idea. Curious if it is open source.

<comment><AUTHOR> Feel free to view source. It's basically 250 lines of jacascript, css and html mixed together in two days. Plus a super simple socket.io server

</comment></comment><comment><USER3> Too weird. Some nice features can be added, like nicknames, private messages and something.

</comment><comment><USER4> very fun concept. I guess there is no way around "location spoofing"? I was in north korea which is obviously not true.

</comment><comment><USER3> Is it down already?

</comment><comment><USER5> I like it... add DM.</comment>