On meta-design and algorithmic design systems - <AUTHOR> http://runemadsen.com/blog/on-meta-design-and-algorithmic-design-systems/

<comment><USER2> This is a compelling little essay. I think the author left out a couple of important points, though.

1\. Design systems may be "algorithmic," but they're primarily mathematical, and equations remain stubbornly hard to use. Metafont failed to attract designers because no one wanted to cook up high-order polynomials to express their visual ideas. (In contrast, Adobe came up with a good-enough interface for Bezier curves, and now the world uses non-algorithmic fonts.) The new class of designers will need solid grounding in at least high school algebra to get their curves and easing functions right.

2\. Any argument about "XXX should learn to code", where XXX is anything other than "aspiring professional software developers," means that there is a significant market opportunity for creating usable software that does not require coding. If people are willing to spend thousands of dollars on bootcamps to learn to code -- when they'd really rather be focusing on their domain problem -- then they're theoretically willing to pay thousands of dollars to _not_ have to learn how to code.

I don't know the state of design software, but if it's anything like other professional desktop tools, it's horrible, creaky software stuck in the early 1990s with very little competition in sight. When I read this essay I can't help but think there's an opening for usable algorithmic design software -- whatever that may look like.

<comment><USER3> I agree with your first point. I don't see designers learning to represent ideas as equations. Not even most of the people who studied Computer Science know the difference between a function and the graph of a function. So I don't see how more difficult concepts can be taught to designers who have no foundation in maths whatsoever. And I don't think that high school maths is really enough. You need a solid knowledge of Linear Algebra to understand how to display a 3D object properly.

Expressing a design as a mathematical expression that generates new representations that follow some guidelines means the designer needs to rigorously understand the very essence of what it is he's trying to do. And then he still needs to know the maths to actually formulate it. This is a tough problem if you start from scratch and I doubt that many designers are really capable of pulling it off.

AFAIK creating those layouts for iOS apps has mathematical reasoning. If you design your app, you basically specify rules to anchor each object on the screen. When the app tries to draw its interface, a linear system of equations gets solved and the solution is the best way to put all the objects on the screen, given the rules that were defined. This gives you an extremely powerful design tool to specify your layout for arbitrary screen sizes.

I would very much hope that they do the same for CSS any time soon.

<comment><USER4> > Not even most of the people who studied Computer Science know the difference > between a function and the graph of a function.

I am surprised by how often I hear this example. Not because people can't define the graph of a function, but because in usual set theoretic terms[1] a function and its graph are the same thing. They are both the set of points (x, f(x)) where x ranges over the domain of f. This is an equivalence that isn't even made by most mathematicians, as they usually denote the graph a function as Γ(f), implying it is different from f itself as a function. Of course they know the equivalence, but prefer to separate the objects notationally for clarity's sake.

[1]: I'm ignoring the notion of a function in category theory, since CS students who are taught math are primarily taught naive set theory, not category theory. Of course, when you aren't working in a category of sets then the graph of a function doesn't make sense, I think.

<comment><USER3> > I am surprised by how often I hear this example.

Huh? That surprises me, too. I didn't know it was so common.

Anyway, I agree that there is an equivalence between a function and its graph. Knowing one implies you know the other. But just because it's equivalent, doesn't mean it's the same. A two-dimensional graph is, after all, a set of tupels in R^2. A function, however, is a mapping from one element in one set to another element in another set.

Mathematically they're very different. I can't draw functions, I can only draw sets. I can't apply sets, I can only apply functions. It makes sense to treat them as different things.

Actually, vector graphics are mathematically specified by graphs of functions, not pixel sets. This makes it possible to zoom in without pixelation, since the function in the graph can be defined analytically (like Bezier curves). If you started out with sets instead of functions, you'd get pixel graphics, since it's not possible to save an infinite set. So the equivalence of a function and its graph holds until you try to implement something.

<comment><USER4> For whatever reason, I hear it as a "challenge" trying to show someone they don't understand math.

But again, I would argue that you're ignoring the difference between an object and its representation for the purpose of communication. A function is defined to be a set of tuples (a relation) with some extra properties. These tuples are the input-output pairs of the function, which is exactly how you define the graph of a function. They are literally the same object, regardless of whether you choose to represent them as a picture or a mapping. The choice of language suggests they are different things because you want to treat them differently (and this is a good thing), but when you get down to the definitions they're the same.

Your example of vector graphics is not a counterexample to this because the sets that define those functions are uncountably infinite. When you render them on the screen to have to approximate them by a finite pixel set, but that is unrelated to the underlying function's mathematical nature.

These set-theoretic definitions of functions and relations are standard parts of an introductory course on set theory.

</comment></comment></comment></comment></comment><comment><USER4> Here's a free meta-design tool I like:

GeoPattern [http://btmills.github.io/geopattern/geopattern.html](http://btmills.github.io/geopattern/geopattern.html)

I'd love to hear about more. Does anyone know of a list of these tools? I'd be happy to compile a list if people provide suggestions.

<comment><USER5> Nice!

I've thought about using a pattern generator to set the background image of my IDE/editor based on the current file name. It'd be fun to see if any side benefits come up, such as:

* Knowing immediately/intuitively if you've switched to the wrong file.

* Triggering the context/ideas you had when you last opened that particular file.

<comment><USER3> Please write a vim plugin for that and let me know :)

<comment><USER4> Seconded.

</comment></comment></comment></comment><comment><USER6> I started writing code as a classically trained designer after my first layoff from an agency many years ago... Something you learn once you cross over, is that this isn't new. A little research and I can start listing design firms that have been around since the late 1980's that promote this multi- disciplinary approach, designers who code, programmers who paint, etc.

Years later;once I picked up heavier languages, from a designers point of view, programming is broken. Point and click is not ideal but slugging through pages of non-human language is worse. Faster at times... but not a solution. Flame away, that's just my opinion from an outsiders point of view.

<comment><USER7> Non-human? What makes you think the languages are non-human? There sure are some _inhumane_ languages around (hehe) but have you ever tried e.g. Common Lisp? There are some very well designed languages around and their source code is as pleasurable to read as its authors were skillful. Of course, I can imagine a graphical s-expression editor which makes it even better to work with Lisp.

</comment></comment><comment><USER8> Would using code that converts data into standard visualizations (e.g. heat maps, sparklines) be considered meta-design? If so, it's not so uncommon (e.g. ggplot2, Tableau, matplotlib, Excel charts…).

Another example of a parametric meta-logo is the one Wolfram created for the National Museum of Mathematics (MOMATH), see [http://blog.wolfram.com/2013/02/28/behind-the-scenes-at- the-...](http://blog.wolfram.com/2013/02/28/behind-the-scenes-at-the-national- museum-of-mathematics-meta-logo/)

</comment><comment><USER9> Some examples of algorithmic design for page layouts: [http://engineering.flipboard.com/2014/03/web- layouts/](http://engineering.flipboard.com/2014/03/web-layouts/) and [https://thegrid.io/](https://thegrid.io/)

(disclaimer: I work on the latter)

<comment><USER7> I find this quite fascinating _but_ : My browser settings include a font-size option, at least the first link's demo breaks with adjusted font sizes. (E.g. minimum font size == 15).

(Theoretically) If I would report a bug against your product, complaining that your layout breaks when I force font sizes in my browser, would you try to fix it or tell me that 99.9% of all users don't set font sizes and I shouldn't too?

<comment><USER9> the issue here is that we use pre-measured GSS ([http://gridstylesheets.org/](http://gridstylesheets.org/)) on the site for perf reasons, and the intrinsic sizes of things were measured using the defaults. We could probably detect that you're overriding them and switch off the pre-measurements in that case. I'll talk with the GSS devs.

<comment><USER7> I suspected that this was the case. In my opinion that means GSS is fundamentally broken and the fact that nobody thought of that kind of discredits the whole thing...

The fact that 70% of "modern" websites already have the same bug doesn't justify it imho.

<comment><USER9> GSS handles it just fine, pre-measured GSS which isn't even yet an officially documented feature, doesn't.

But anyway, would be nice if you could document your setup and the problem you're seeing at [https://github.com/gss/engine/issues](https://github.com/gss/engine/issues)

</comment></comment></comment></comment></comment><comment><USER8> See also: Procedural generation

[http://en.wikipedia.org/wiki/Procedural_generation](http://en.wikipedia.org/wiki/Procedural_generation)

</comment><comment><USER10> Could you call an AI meta-meta-designer creative?

It would work out what things can be designed, then define the rules to design them.

<comment><USER11> Exploring a meta-rule space isn't hard.

Exploring a meta-rule space and finding rule sets that create results that humans find interesting is _much_ harder.

If you skip that you tend to create systems that seem too random, or too repetitive and obvious.

This is why most algorithmic art is so uninteresting. It falls on one side or the other of the randomness/repetition valley, without hitting that sweet spot that the best human creativity finds.

That's not even thinking about emotional associations, intellectual abstractions, social awareness, and models-of-mind. You might need all of them to make a genius-level creative AI, but I'd guess that the more you have, the more likely you are to get something worth keeping.

<comment><USER12> That's why I find "augmented intellect" so much more interesting as a concept than "artificial intelligence".

Truly autonomous behavior is out of reach of our reasoning systems, using most known approaches to AI. But if you put a human in charge of the creative part, and complement it with the automation capabilities that simplify the repetitive parts, the result is a win-win match combining the strengths of both.

<comment><USER10> I guess that's the continuation of automating tasks and building up. Push more and more work to the computer / AI. We've been going through writing higher level languages, and the article is describing going a step higher again.

Fascinating stuff!</comment></comment></comment></comment>


Drupal 8.0.0 Released - <AUTHOR> https://www.drupal.org/news/drupal-8.0.0-released <comment><USER2> Significant update to Drupal from the previous version (7.x)</comment>


Fake News Is Still Fooling Facebook's Fact-Checking Systems - <AUTHOR> https://onezero.medium.com/how-fake-news-is-still-fooling-facebooks-fact-checking-systems-fa8b0e0255b8 <comment><USER2> The news has become so bad today so every news source is basically fake news. In my country for example, the national television is so obviously biased it's ridicolous.

They are spreading more fake news than most of their alternative media competitors. Basically everyone I know trust these alternative media way more than the mainstream media. I don't know about the US but in Sweden the mainstream media is the one responsible for the overwhelming majority of fake news.

There is a difference though. When these "troll sites" or alternative media sites spreads fake news it's often outright lies but when mainstream media spreads fake news it's mostly about leaving important details out and not disclosing events and information that is relevant. They are experts in taking things out of context and paint the picture they want to paint. They seldom lie but they are still not telling the truth.

I'll even give you an example, Dagens Nyheter ([https://dn.se](https://dn.se)) is one of the biggest media outlets in Sweden. They had an ad bought by China that spread fake news about the Hong Kong protests and pro-China content.

Like, how are people supposed to believe anything they say about such things as foreign affairs (for example) when they are funded partly by fucking China?

<comment><USER3> > The news has become so bad today so every news source is basically fake > news. In my country for example, the national television is so obviously > biased it's ridicolous.

"It's all fake news" is cover for propaganda outlets, and while mainstream news gets things wrong occasionally, they get a lot right, and also they course correct and offer corrections when they get things wrong.

There's a huge difference.

<comment><USER4> The MSM in the US is almost entirely corrupt. It's proven time and time again that it will push agendas, hide facts, kill stories, make things up...

If you doubt what I say I suggest you spend some time looking into MSM coverage of Epstein and Weinstein. Just recently it was leaked that ABC news killed an Epstein story for political reasons _then_ tracked the whistleblower down at their new job at CBS and got CBS to fire them.

I suggest reading Ronan Farrow's Catch and Kill to get an accurate take on the current state of journalism:

[https://en.wikipedia.org/wiki/Catch_and_Kill](https://en.wikipedia.org/wiki/Catch_and_Kill)

<comment><USER5> Yes to all of that but that is still 100x better than a completely fabricated story about Politician X dying when they are in fact living published on houston-star-ledger-journal.com. That's fake news. The examples you stated are not fake, but examples of yellow journalism and other fourth-estate power grabs.

<comment><USER6> Completely fabricated, eh? The big outlets don't do that, eh?

[https://twitter.com/JessicaGKwong/status/1200208471599321089](https://twitter.com/JessicaGKwong/status/1200208471599321089)

<comment><USER3> She got fired. What happens to "reporters" at propaganda outlets that post "news" that they know is fake?

<comment><USER7> And what happened to Dan Rather after "rathergate"?

They could "afford" to fire a little known reporter.

And then there is the phenomenon of entertainment disguised as news which many people take for news which infuse enormous amounts of opinion and bias in their reporting.

The only ones which make a decent attempt at impartiality is PBS with their national news. Their local news tends to have intrusions where news is colored with opinion and bias, unfortunately.

<comment><USER3> No one on this thread is saying news is perfect. But what some people seem to be saying is that propaganda outlets are just the same as people who at least try and do real news, which is pretty horrible. That's how the propaganda wins.

<comment><USER7> The news is bipolar. On occasion they "want to seek the truth". At other times they "want to do what's right".

Those two things often diverge. The "what's right" has a lot of latitude and is open to the interpretation of the reporter and editor it also may hide the truth.

And also there is "agency". Some reporters want to be "agents of change". That's not their job. It's not their job to make nuclear uncool and put Jane Fonda front and center. If they had looked at the issue critically and scientifically we might not be in the pickle we're in with regard to energy production.

</comment></comment></comment></comment></comment></comment></comment></comment></comment><comment><USER8> Facebook profits from fake news by allowing politicians to publish outright lies, so I'm not surprised that fake news is "fooling" Facebook's fact- checking.

Sources:

\- [https://www.theguardian.com/technology/2019/nov/27/facebook-...](https://www.theguardian.com/technology/2019/nov/27/facebook- only-dutch-factchecker-quits-over-political-ad-exemption)

\- [https://www.nytimes.com/2019/10/12/technology/elizabeth- warr...](https://www.nytimes.com/2019/10/12/technology/elizabeth-warren- facebook-ad.html)

Deactivated my Facebook account today. Hope to delete someday.

<comment><USER9> I mean, it sort of has to be. Ultimately Facebook is only allowed to operate because politicians allow it to. Pissing off too many politicians is an existential threat to Facebook.

That's not to totally absolve Facebook btw; a major part of what needs to happen is a huge amount of transparency so that constituents can pressure politicians correctly.

<comment><USER8> I don't see how it's a requirement to allow politicians to lie. For instance, both Twitter and Google now prohibit political advertisement entirely. Facebook could follow suit. They'd just make less money.

<comment><USER10> Political ad spend is a tiny amount of facebook's revenue. It has nothing to do with money and everything to do with Zuck's politics

<comment><USER9> It's not about overt advertisements, but standard viral communications that the platforms live and die on.

</comment></comment></comment></comment></comment><comment><USER11> I actually don't want Facebook removing 'fake news.' There are, of course, some obvious examples of fake things spreading around. But what about the less obvious examples? Where do we draw the line?

Social media companies should not be the arbiters of truth. I don't want Facebook or Google deciding for us what truth is. If the speech is illegal, like defamation or direct calls to violence, it should be taken down. Other than that, falsehood should be countered with truth rather than removal.

If you look at Fox News vs CNN, you'll see completely different versions of 'truth'. Any 'fact' these days can be labeled as fake news or a conspiracy theory. Both sides are doing it. But it would be far worse if there were only one version rather than two.

<comment><USER12> This is the only viable way forward. They need go back to being a dumb platform, just like ISPs are dumb pipes.

<comment><USER13> Why? What if a technology company wants to build a website that caters to a certain value system? Why should they not be allowed to do that?

<comment><USER14> Because they insist of having it both ways. Whenever it's convenient to them they claim to be dump pipes.

But this is only valid until it comes to maximize profits. Then suddenly they are (heavy handed) editors.

<comment><USER13> > _Whenever it 's convenient to them they claim to be dump pipes_

Can you provide an example of Facebook ever claiming they are just "dumb pipes" and how that claim had any material impact on their business? Are you suggesting Facebook is potentially guilty of false advertising?

<comment><USER11> Is Facebook a publisher? In public it says no, but in court it says yes [https://www.theguardian.com/technology/2018/jul/02/facebook-...](https://www.theguardian.com/technology/2018/jul/02/facebook- mark-zuckerberg-platform-publisher-lawsuit)

<comment><USER13> So what? "Publisher" has no legal meaning in the context of a website, so who cares what they say they are?

</comment></comment></comment></comment></comment></comment></comment><comment><USER15> There's no financial incentive to do fact checking and there is enormous political pressure not to. Ironically, from parties that will thoroughly censor Facebook when they can.

But more interesting, given much of the thread has somehow become an anti- press tirade, is how easy it has been for the new style autocrats to reuse the cry "Lügenpress!" just by translating it.

And while it is becoming increasingly unfashionable to say so; there is such a thing as truth, it is knowable and, there are conscientious people who follow facts wherever they lead and report them.

<comment><USER16> > And while it is becoming increasingly unfashionable to say so; there is such > a thing as truth, it is knowable and, there are conscientious people who > follow facts wherever they lead and report them.

And most of mainstream journalism (as well as many alternative outlets) still strives to do this. Yes, they make mistakes and have their own biases (they are human, after all), and they often have conflicting incentives (they'd like to feed their families) but they really are trying to find the truth.

I recently got into in argument with my conservative Christian in-laws about this. It was surreal for me to need to be arguing the position that there is absolute truth out there—even if we can never know for sure in this lifetime. As a progressive millenial, I thought the postmodern post-truth perspective was supposed to be mine!

<comment><USER17> > there is absolute truth out there—even if we can never know for sure in this > lifetime

Yes, it does seem strange that they would be opposed. Are you sure they understood your main statement the way I quoted it above?

<comment><USER16> > Yes, it does seem strange that they would be opposed. Are you sure they > understood your main statement the way I quoted it above?

It was in the context of discussing the Trump administration, especially the impeachment process (how we got there is a long story...). They kept falling back on "there's two sides to every story..." as if that precludes us from attempting to seek truth.

I'm sure if pressed, they would agree that objective truth exists (it's hard to be an evangelical Christian and not hold this view). But they seem bewildered at the prospect of actually trying to seek it out. Gaslighting has truly taken its toll.

<comment><USER17> I too find it bewildering to uncover the truth when there's evidence on both sides; that's why I made [https://en.howtruthful.com/](https://en.howtruthful.com/)

<comment><USER15> We should also distinguish between statements of fact which do have truth value vs statements of opinion which don't.

"Is Hillary a bad person?" asks an opinion and has no objectively wrong answer.

"Did Hillary run a child abuse ring from a pizza parlor?" is objectively either true or false regardless of how many people believe it.

Relativism may have started with the intent of pointing out this distinction (eg the 19th century firm belief that "Primitive societies are bad") before being over generalized.

</comment></comment></comment></comment></comment></comment><comment><USER18> the problem of fake news is fundamental to the way Facebook operates. It's a noise-generating machine by design. Instead of trying to play whack-a-mole with fake news the saner alternative would be to architect communication systems in ways that don't allow this bottom-up virality. Associate some cost with the proliferation of posts, say limit the number of contacts users can have and how many people see their posts, bring it down to communal or human scale. Everything else is just trying to fight a hurricane with a hairdryer.

Should be obvious that it directly interferes with the business model of the company so it's probably never going to happen.

<comment><USER19> >Should be obvious that it directly interferes with the business model of the company so it's probably never going to happen.

Bingo.

Facebook started out as social media platform for humans, now every local news station, your favorite burger joint, and any "news" website on the web can have a Facebook profile convincing enough to look legit.

Instead of fixing the news on Facebook lets take the news out of Facebook.

Which is almost as impossible as "directly interferes with the business model of the company so it's probably never going to happen."

<comment><USER16> I don't think that corporate presence on Facebook is really the problem. Facebook is designed to maximize user engagement. That doesn't conflate with truthfulness of content (user- or corporate-posted)—in fact, often times it's the opposite. Of course, this isn't new—yellow journalism was a big problem in the early 20th century. But Facebook's algorithm—and the ease of starting new media outlets—makes it orders of magnitude worse.

</comment></comment></comment><comment><USER13> Fake news is a cultural problem that can't be solved algorithmically. A large portion of the people sharing and consuming fake news don't care that it's fake. We have to train the next generation to mistrust social media platforms as a general rule and work to encourage the concept of meaningful discourse and communication outside of these platforms.

</comment><comment><USER20> You would think users are savvy enough not to trust non-mainstream websites. We have found the best way to avoid fake news, is to read the "good" stuff. Instead of trying to determine if an article is bad, we try to see how good an article is. It is an important difference in how we approach the news.

The only way to truly understand a topic is to read many viewpoints and make an independent decision. But who really has time for all that?

A plug for what we are working on : [https://www.thefactual.com/static/extfaq.html](https://www.thefactual.com/static/extfaq.html)

I linked to the FAQ on purpose, since it might answer some of the questions you might have.

We analyze articles everyday from tons of news sources, score them for bias, reputation of the author, reputation of the site and how opinionated the writing is. Our software then clusters articles based on what story its covering and then rank and sort them. It's all available for free.

We even have a daily newsletter : [https://www.thefactual.com](https://www.thefactual.com)

Sorry if this comes across as too promotional. But we see the problem being mentioned in a lot of places and it's exactly what we have been trying to solve and would love to get more people to use it and give feedback.

</comment><comment><USER21> At my country (Bolivia) during the coup we noticed real news being reported as fake news and take down, fb tools don't really work in either side real or fake.

</comment><comment><USER22> You can either have limitless "free speech" or get rid of fake news, or to use the correct term: lies and propaganda.

Either you take down the propaganda spreaders, no matter if by legal measures such as netblocks or jail (for domestic propaganda), by war (in case of Russian state propaganda) or by a team of elite soldiers (for those operating in unwilling-to-cooperate third states) or you lose the liberal society we enjoy.

The earlier societies realize they are at a new form of war, the better. But as long as people excuse Russian or Chinese propaganda with free speech, nothing will be done and eventually free speech itself will be lost. Hongkong shows what China wants - Europe and the US should _not_ think they are immune from CCP demands. Hell, we _provide_ China and Russia with the weapons against us - and no, nothing Facebook does is anywhere close to enough to _not_ be a weapon in itself! Their moderation rules are intransparent to outright crazy, the teams understaffed and overworked.

</comment><comment><USER23> "Seen from the viewpoint of politics, truth has a despotic character. It is thereforehated by tyrants, who rightly fear the competition of a coercive force they cannotmonopolize, and it enjoys a rather precarious status in the eyes of governments thatrest on consent and abhor coercion. Facts are beyond agreement and consent, and alltalk about them – all exchanges of opinion based on correct information – will contributenothing to their establishment. Unwelcome opinion can be argued with,rejected, or compromised upon, but unwelcome facts possess an infuriating stubbornnessthat nothing can move except plain lies. The trouble is that factual truth,like all other truth, peremptorily claims to be acknowledged and precludes debate,and debate constitutes the very essence of political life."

Excerpt from Truth and Politics by Hannah Arendt in the Feb. 25, 1967 issue of The New Yorker magazine. Highly recommended.

</comment><comment><USER24> Never in my life would I have imagined a population expecting the advertising companies to police the truth.

</comment><comment><USER25> I haven't had a Facebook account for a long time. Few decisions I've made have improved my life so drastically.

Just get off Facebook. They're a terrible company, people shouldn't be supporting them, and your life will be better without it.

</comment><comment><USER26> > even though its executives had evidence that Russian agents were behind some > of it

Oh this dude is against "fake news" and then starts pushing the whole Russian bullshit again? This article is fake news. Lame.

Russian ad farm scammers buying a few thousand ad impressions for ads featuring BLM, Jill Stein, Jesus' advice on masturbation, and other such topics designed to attract curious clicks, all as documented in the government report, is not Russian election manipulation and it's dishonest to continue maintaining that it was. Also Russia's not the only hotbed for ad farm scams nor even a particular hotbed. Ad farms are grown globally in countless net nooks and crannies.

Why not refuse to accept ads promoting clickthrough to bogus ad farms filled with stolen content instead? That would actually do some good. Oh but might eat slightly into ad profits, so no can do.</comment>


PostgreSQL HA cluster failure: a post-mortem - <AUTHOR> https://gocardless.com/blog/incident-review-api-and-dashboard-outage-on-10th-october/ <comment><USER2> I've been involved in various Postgres roles (developer on it, consultant for it for BigCo, using it at my startup now) for around 18 years.

I've never in that time seen a pacemaker/corosync/etc/etc configuration go well. Ever. I have seen corrupted DBs, fail overs for no reason, etc. The worst things always happen when the failover doesn't go according to plan and someone accidentally nukes the DB at 2am.

The lesson I've taken from this is it's better to have 15-20 minutes of downtime in the unlikely event a primary goes down and run a manual failover/takeover script then it is to rely on automation. pgbouncer makes this easy enough.

That said, there was a lot of bad luck involved in this incident.

<comment><USER3> How does pgbouncer make this process easy? Just because there are less connections to go to the final DB? I've also got a random question you might be able to answer (having a hard time googling)... when using pgsql in streaming replication mode, are created functions replicated/updated to everything else as well?

(just learning about postgres and saw an opportunity to ask someone in the know) Cheers!

<comment><USER4> > are created functions replicated/updated to everything else as well?

Yes.

Note if those functions have an implementation compiled from C, you do need to install the .so on the standbys though.

<comment><USER5> You need the .so's on the replica's simply for the database structure, but afaik, it's only the on-disk format that's being synchronized, functions are not executed on the replicas. I'm not even sure this would throw errors if the .so's would be missing - but it will give problems when a replica is promoted to the new master.

<comment><USER4> I agree: it's only because you need them when you fail over.

</comment></comment></comment></comment></comment><comment><USER6> > _Fortunately, as part of some unrelated work we 'd done recently, we had a > version of the cluster that we could run inside Docker containers. We used > it to help us build a script that mimicked the failures we saw in > production. Being able to rapidly turn clusters up and down let us iterate > on that script quickly, until we found a combination of events that broke > the cluster in just the right way._

this is the coolest part of this story. Any chance these scripts are opensource ?

<comment><USER7> We plan to open source it as soon as we can. Tiny bit more work to do, then review from a couple of people in the team, then we make it public. :)

<comment><USER6> Thanks for this !

</comment></comment></comment><comment><USER8> Since I am investigating HA with PostgreSQL right now and have bitter experience of Pacemaker 'HA' instances that have been anything but, I am looking at Amazon Aurora and Microsoft's (in preview) Azure database for PostgreSQL offerings. I would really appreciate any insight from others who are already using them (we intend to do some PoC work shortly).

Our dev team also came up with some pertinent questions, which we have put to both companies, but if anyone else can comment from experience that would be fantastic:

* Is the product a fork of PostgreSQL or a wrapper round the current version?

* Will the DB engine keep in lock-step with new PostgreSQL releases or might they diverge?

* If the DB engine keeps in lock-step, what's the period between a new version of PostgreSQL being released before its incorporated in the live product?

* When new versions of Amazon Aurora/Azure DB for PostgreSQL are released will our live instance get automatically updated or will we be able to choose a version?

<comment><USER9> I can comment on Amazon Aurora:

> Is the product a fork of PostgreSQL or a wrapper round the current version?

Aurora is a fork: they've re-written a significant chunk of the engine. Note that Amazon also offers RDS PostgreSQL, which is a managed version of the "regular" PostgreSQL engine. RDS PostgreSQL also offers a HA setup (no version upgrade without downtime, however). It works quite well.

> Will the DB engine keep in lock-step with new PostgreSQL releases or might > they diverge?

Amazon promises to keep it in lock-step. How soon they will release an upgrade to a major version remains to be seen.

> When new versions of Amazon Aurora/Azure DB for PostgreSQL are released will > our live instance get automatically updated or will we be able to choose a > version?

Minor version upgrades are applied automatically. For major version upgrades, it's unclear at this time (there hasn't been one yet for Aurora PostgreSQL), but I think it's unlikely they will be applied automatically.

</comment></comment><comment><USER10> I think the root issue is that PostgreSQL does not offer an HA solution that works out of the box with minimal configuration, resulting in people using broken third-party ones and/or configuring them incorrectly.

They should either provide one or "bless" an external solution as the official one (after making sure it works correctly).

The other problem is that GoCardless setup an asynchronous and a synchronous replica instead of 2 synchronous replicas (or preferably 4+), resulting in only two points of failure, which is not enough.

<comment><USER7> Pretty much number 1 on my Postgres wishlist.

</comment></comment><comment><USER11> Makes me sad that running your own instances is now an "elephant in the room." No pride in old-school do-it-yourself nerditry these days :/

<comment><USER12> Getting HA right is _hard_. DIY-ing it incurs risk, possibly deliberately, out of Not-Invented-Here-ism.

Source: PostgreSQL DBA for over a decade; have built multiple HA environments; have seen many ways of "doing it wrong", and how those can end up biting their creators.

<comment><USER13> On the other hand:

With hosted Postgres, when a failure does happen, isn't it much harder to get at the log files? They seem extremely useful to diagnose the problem and make sure it doesn't happen again, as the article shows. What's your experiene here, can you get at logs easily with hosted Posgres offerings?

And it seems the only way to get reliable Postgres HA for everyone, and to weed out the bugs, is if more people run Posgres HA themselves. For example, I find Stolon and Patroni great, but I would be more relaxed about them if they had 100x more users.

<comment><USER12> We aren't using hosted postgres (much, yet). We provision EC2 instances and self-manage it. Failover is scripted, and manually invoked as needed.

None of us trust any of the automated failover solutions enough to use them. We want human judgement in that loop, even if it means being woken at 3AM to push the button. It's _that_ hard to get right.

Just one incident like The Fine Article's is well more than our entire infrastructure's total downtime for the rolling year, and we have hundreds of postgres instances.

Done wrong, automated failover is a net _increase_ in risk. And, in case my thesis is somehow unclear, _it 's hard to get right_.

</comment></comment></comment></comment><comment><USER14> This is why you should be extremely wary of anything that is only run once in a a blue moon. And very wary of such things that when run, are being run to save your bacon.

<comment><USER12> "Your backups are only as good as their last successful restore."

<comment><USER15> [https://feedbin.com/blog/2017/05/05/testing-huge- postgresql-...](https://feedbin.com/blog/2017/05/05/testing-huge-postgresql- backups-for-37-cents-a-day/)

</comment></comment></comment><comment><USER16> "The RAID controller logged the simultaneous loss of 3 disks from the array. All subsequent read and write operations against it failed."

People seem to forget that adding a RAID controller creates a single point of failure instead of removing one. :-)

<comment><USER17> Always use software RAID. I'd rather loose 30% on efficiency than creating a single point of failure with a random hardware. Software RAID on modern OSes (Linux, FreeBSD, ... ) are pretty darn reliable and fast.

<comment><USER18> And the SATA/SAS controller of your Mainboard is invincible? Or the Mainboard itself? Or the CPU? What's your backup solution if they are faulty?

<comment><USER17> I use two different controllers in JBOD mode. Each controller manages half of HDDs. Then I build cross controller software RAID 1. That is, I choose two disks from separate controllers to build raid 1. Last but not least, all HDDs are mixed from different vendors across controllers.

For CPU, RAM there is no other option. you have to replicate stuff.

</comment></comment></comment></comment><comment><USER19> Pacemaker is known to wreak havoc if it gets angry. The usual path to quick recovery when the cluster goes crazy like this is to make really sure what's the most up to date replica, shut down Pacemaker completely, assign VIP manually to a healthy replica and promote it manually. Then once you're up and back in the business figure out how to rebuild the cluster.

<comment><USER20> If this is indeed true, doesn't this negate the purpose of pacemaker to begin with? It's like anti-software. When you run with it in your environment, to recover from a failure (which seems to me what HA software should be about) you have to turn it off first or else it will destroy your recovery attempts.

It's like a perverse version of chaos-monkey, except you want it to destroy you when you are most vulnerable.

<comment><USER19> It's great when it works as expected. When it doesn't... then the fun begins. I've found it quite fragile, components versions sensitive, configuration sensitive, etc. Most of the time I've seen Pacemaker gone crazy Pg itself was happy to cooperate once the Pacemaker was out of the way. The unknown/weird Pacemaker failure modes were a real (and scary) problem.

I guess the lesson here is not to rely entirely on some HA black magic and always have procedures in place for the 'HA black magic failed us' moments. And team trained to deal with situation like this. It's only software so it will break sooner or later.

</comment></comment></comment><comment><USER21> Good write-up. I'm curious about two more things:

1\. What caused the crash on the synchronous replica? Was it just a coincidence and completely unrelated to the primary failure?

2\. Given the three conditions necessary for the cluster to break, was the behavior of the Pacemaker software expected? I.e., was this a gotcha that should be in the Pacemaker documentation, or a bug?

<comment><USER7> 1\. Unfortunately the logs don't give any detail there. Most likely something arrived down the replication connection that the process couldn't handle, and it crashed.

2\. Our understanding now is that INF is the strongest preference, whereas -INF is a veto. It would be very cool to have this confirmed 100% by someone who works on Pacemaker!

</comment></comment><comment><USER22> The end of this post mortem was a bit handwavy TBH. I feel like they didnt dig deep enough, and the problem was the backup VIP, not the two processes crashing at once and the backup VIP.

I think by still allowing the backup VIP to run on the sync replica the same mistake is being repeated, there will always be the possibility of a situation where the VIP cannot be moved when promotion is required. That replica should be doing nothing but sitting there waiting to save the day, and if they want the backup VIP to be highly available they should provision 2 async replicas.

</comment><comment><USER23> I too am coming up on a need for no-downtime HA failover for Postgres. I too am not allowed to use a hosted PaaS-ish solution like RDS. I was considering Citus's multi master impl (I don't need to spread the load, just need HA). I had not considered Pacemaker. Has GoCardless investigated this option and have any insight to give? HA has traditionally been a real pain point for traditional RDBMS's in my experience.

<comment><USER7> To be honest we've not looked into Citus in any depth.

My early impression of it (can't speak for the rest of the team) was that it was mostly aimed at sharding analytics workloads, but parts of the docs (e.g. [https://docs.citusdata.com/en/v7.1/admin_guide/cluster_manag...](https://docs.citusdata.com/en/v7.1/admin_guide/cluster_management.html#worker- node-failures)) make it sound like it handles OLTP workloads too.

Maybe I've been ignoring it for bad reasons!

EDIT: Managing Postgres clusters is something that a lot of people are working on. Thought I'd mention two projects that have me excited right now:

      - Patroni https://github.com/zalando/patroni
      - Stolon https://github.com/sorintlab/stolon

Stolon's client proxy approach in particular looks interesting, and reminds me of how people are using Envoy ([https://github.com/envoyproxy/envoy](https://github.com/envoyproxy/envoy)), albeit as a TCP proxy rather than one that understands and can do fun stuff with the database's protocol. I wonder if we'll start to see more Envoy filters for different databases!

<comment><USER24> Craig from Citus here. Since we grew transactional support a couple of years ago and a number of the features we've supported since then much of our traction has come from those outgrowing single node Postgres and needing more performance. So in short we're very much focused on handling and supporting OLTP workloads.

We do also support some analytics workloads, less so data warehousing, when there is a need for end user facing analytics where higher concurrency and real-time responsiveness is key.

</comment></comment></comment><comment><USER25> I'm told that MySQL replication blows Postgres out of the water by my company's data team, but they could just be biased since that is their area of expertise. I work on server code and don't really have much familiarity with the operations of running replica chains.

Postgres seems like a better choice for personal projects since it has a lot of nifty features. I'm also wary of Oracle, but that's my own attitude talking. For a startup eventually wanting to scale, would the better choice be to use MySQL out of the gates? Am I being mislead about Postgres clusters and availability?

Serious (naive) question; not wanting to start a flame war.

<comment><USER26> Having ran MySQL in prod for a decade and PostgreSQL in prod for half a decade I can say without doubt that your data team is telling fibs.

Firstly we consider that there are multiple replication possibilities of both technologies- however I'm going to assume the defaults because that's pretty much what everyone uses except if there's an actual case for using something else. It's the exception.

But by default MySQL uses statement based replication (in a weird binary format with log positions and stuff) and postgresql does logical replication (as in, you transmit the binary differences of what you'll be doing to the replica's database files directly and the replica just follows along)

Both of these approaches have trade-offs depending on what you want.

Statement based replication is great if you want to have _different_ datasets on each side, You can transform the data or remove huge chunks of it on a slave and use it for a dedicated purpose. However that applies the other way, you can never really be 100% sure that your replica looks exactly like your master.

this bit me a few times with MySQL when I assumed that because the replica was 'up to date' with the master and it was set to read only, that the data had integrity- it absolutely did not.

<comment><USER27> I don't think the claim of MySQL replication being better is related to statement vs. row vs. binary diff. I think it is about the tooling and community knowledge about replication, and about running MySQL in large scale production environments in general.

MySQL is run more often at extremely large scale (Facebook, YouTube, Twitter, Dropbox, etc.) than Postgres. That results in very battle tested and/or featureful tooling like orchestrator ([https://github.com/github/orchestrator](https://github.com/github/orchestrator)), MHA ([https://github.com/yoshinorim/mha4mysql- manager](https://github.com/yoshinorim/mha4mysql-manager)), ProxySQL ([http://www.proxysql.com/](http://www.proxysql.com/)), and gh-ost ([https://github.com/github/gh-ost](https://github.com/github/gh-ost)), along knowledge and best practices shared by those organization.

<comment><USER28> What are anybody's real-world use case for proxysql?

I have been toying with the idea of using it for local devs to access our prod DB for reads (for accurate data) and using a local DB on their machines for writes.

Not sure how to handle UPDATEs, though.

<comment><USER29> Use cases for ProxySQL: many.

\- failover

\- query routing (e.g., for sharded deployments)

\- caching

\- workload stats/metrics

\- query rewriting

etc.

</comment></comment></comment></comment></comment><comment><USER30> There are specialized tools like Patroni ([https://github.com/zalando/patroni](https://github.com/zalando/patroni))

<comment><USER31> I like Stolon: [https://github.com/sorintlab/stolon](https://github.com/sorintlab/stolon)

</comment></comment><comment><USER32> If you are running HA in AWS RDS, how would you compare your experience with the above? What are the types of RDS failures modes that you have experienced?

So far I've discovered that TCP keepalives are quite important, otherwise your queries may hang forever after failover (or at least for the default timeout which is like 30 minutes). The connection does not get broken otherwise by the failover.

<comment><USER4> Here are a couple gotchas I've seen on RDS:

\- If you are running a MultiAZ instance, it is supposed to fail over automatically, but if the problem is in the networking, then you can still effectively lose service. One way around that is to run a read replica in another AZ, and use a Route53 entry with a health check to send traffic to the read replica if the primary isn't reachable. You'll still need to promote the read replica to a master though.

\- If you restore from a snapshot, the new EBS volume only pulls blocks of data from S3 as they are requested. So these reads are a lot slower than normal. If you have a large database you could have degraded performance for days. Here is some more info about this: [http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs- resto...](http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-restoring- volume.html)

</comment></comment><comment><USER33> I am astonished that, in the two years, you had not already handled 100+ scheduled failovers. If your HA is good, customers don't notice, and if not, you find out when there are fewer of them (and in daytime!), and fix it.

Probably by now Pacemaker would have been abandoned. A hundred drills would have been enough to flush out these behaviors. If you are afraid to run drills on production equipment, you should be running them on a full-scale production testbed, ideally with mirrored production traffic. With a production-scale testbed, two years is enough to run thousands of risk-free failovers.

Not doing frequent production failure drills is just irresponsible.

</comment><comment><USER34> I'm seeing the term "HA" being used a lot in the comments here, what does it mean?

<comment><USER35> high availability

</comment></comment><comment><USER31> Stolon with etcd or consul is a far superior solution for HA postgres.

</comment><comment><USER36> Stop pretending that there's a magic bullet called "multi-master" and "transparent promotion". Your apps are super simple. Their DB interactions are super simple. Learn how to do federations and all these problems will go away.

<comment><USER12> It's curious that you decry some kinds of "magic bullet" in favor of another.

How about "there are no magic bullets, _full stop_ "?</comment></comment>


The tiny Wyoming creek that connects the Atlantic and Pacific Oceans - <AUTHOR> http://twentytwowords.com/the-tiny-wyoming-creek-that-connects-the-atlantic-and-pacific-oceans/

<comment><USER2> I seems like a bifurcating stream would be unstable. Does anyone here know how common they are and how long they last?</comment>


Bill Gates explains why China will build the first 4th gen nuclear plant - cat-dev-null http://nextbigfuture.com/2016/03/bill-gates-explains-why-china-will.html?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+blogspot%2Fadvancednano+%28nextbigfuture%29 <comment> cat-dev-null Salient ideas: [https://www.ted.com/talks/taylor_wilson_my_radical_plan_for_...](https://www.ted.com/talks/taylor_wilson_my_radical_plan_for_small_nuclear_fission_reactors)

Disclaimer: I used to worked for a US nuclear engineering consultancy which wound down in the late 90's because there was insufficient new or existing business; it was sad to see carbon-heavy technologies be pushed with FUD and a lack of innovation in terms of comprehensive safety and cost reduction. It seems that prior, big, expensive designs (PWR, BWR) reactors are inherently less safe due to high-pressures and massive complexity (just look at the control systems operations manuals Vol I..XVIII). It would be good for ventures to try both the "tiny fission masses printed in wells on a chip" and the molten salt approaches in order to deliver far safer, mass-produced fission gen sets.

</comment><comment><AUTHOR> The US is only building 4 new nuclear power plants, while China is building half of the new ones in the world.</comment>


How Food Replaced Art as High Culture - <AUTHOR> http://www.nytimes.com/2012/10/28/opinion/sunday/how-food-replaced-art-as-high-culture.html <comment><AUTHOR> "A curry is not an idea, even if its creation is the result of one. Meals can evoke emotions, but only very roughly and generally, and only within a very limited range — comfort, delight, perhaps nostalgia, but not anger, say, or sorrow, or a thousand other things. Food is highly developed as a system of sensations, extremely crude as a system of symbols."

I think this is really wrong, but I feel like this is a good pointer to where we are heading in fine cuisine. The false dichotomy in the article is between Old Masters and organic markets/good risotto). But a better apples-to-apples comparison would be between contemporary art and contemporary cuisine. If you compare the emotional experience between an Alinea or El Buli vs. something like Dia:Beacon, it seems like it's getting much closer. I would absolutely describe the experience of eating at Alinea as "emotional" and full of ideas.

The interesting thing is that art isn't just about emotion - it can involve emotion, but it can involve a lot of other things too. What I look forward to is cuisine that can be self-critical, hostile, sarcastic, naive, quiet, empty, etc. What would the Agnes Martin of food look like? The On Kawara? The Merlin Carpenter?

I think we're generally getting more sophisticated in our cultural appreciation for lots of reasons, including the internet allowing much easier dissemination of sophisticated ideas and the flattening of accessibility to good cultural curators. Unlike this author, I don't think food is replacing art: it's just thriving alongside. There's a rising tide that's raising all the cultural boats. I'm really bullish on contemporary art for this reason.</comment>


Mike Rothenberg allegedly wired $5.2M from bank without permission - <AUTHOR> https://techcrunch.com/2016/09/20/mike-rothenberg-allegedly-wired-5-2-million-from-silicon-valley-bank-without-investor-permission/ <comment><USER2> _" Indeed, one employee, David Haase, is currently suing the firm for breach of contract, saying it owes him more than $109,000 in business expenses that he accrued on a personal American Express card at Rothenberg's direction."_

This is mind-boggling. Why would an employee agree to do this? If my employer is desperate enough for cash that they want me to open a personal credit line for corporate expenses, what chances are there that the company will ever be able to pay back what it owes me?

The linked article[1] gives more details:

 _" Haase says in his suit that in May, he opened the account with Rothenberg's approval "for the purpose of acting as a credit line for the day- to-day expenses incurred by RVM." These included business expenses charged by Rothenberg's "numerous administrative assistants at his direct request." Part of those expenses included payroll, according to our sources."_

The company is charging _payroll_ to an employee's personal credit card? Either they don't have a bank account, or their bank account has nothing in it, or their funds are frozen pursuant to some legal matter. None of these would make it likely that the money would ever be paid back to the employee.

But there's more:

 _" Another former senior executive said Rothenberg owes him at least $40,000 in back wages. Another third employee has filed with the California Division of Labor Standards Enforcement for $70,000 of unpaid wages from the firm."_

$70K is a lot of missed paychecks, even for an employee with a rather high salary. Why would people continue working for a company that makes clear to them that it doesn't have the money to pay them?

[1] [https://techcrunch.com/2016/09/04/a-former-rothenberg- employ...](https://techcrunch.com/2016/09/04/a-former-rothenberg-employee-is- now-suing-over-breach-of-contract-and-more-than-100k-in-amex-charges)</comment>


No One Wants to Buy Those Stolen NSA-Linked 'Cyberweapons' - <AUTHOR> https://www.wired.com/2016/08/no-one-wants-buy-stolen-nsa-linked-cyberweapons/ <comment><USER2> > $865 dollars

Ah, that well known unit, the dollar^2</comment>


X marks the spot: NASA selects site for asteroid sample collection - <AUTHOR> https://www.asteroidmission.org/?latest-news=x-marks-the-spot-nasa-selects-site-for-asteroid-sample-collection <comment><AUTHOR> thread with media: [https://twitter.com/OSIRISREx/status/1205195181135298560](https://twitter.com/OSIRISREx/status/1205195181135298560)</comment>


Yelp is using your Facebook info without permission? - <AUTHOR> http://www.yelp.com/ I don't know how I fee about it. I've been a long time user of yelp, but using my Facebook information without prior permission seems off base to me. Thoughts? <comment><USER2> It's called "Instant Personalization".

[http://gigaom.com/2010/04/22/facebooks-instant- personalizati...](http://gigaom.com/2010/04/22/facebooks-instant- personalization-is-the-real-privacy-hairball/)

Old instructions on how to turn it off, back when it was simple:

[http://gadgetwise.blogs.nytimes.com/2010/04/23/how-to-opt- ou...](http://gadgetwise.blogs.nytimes.com/2010/04/23/how-to-opt-out-of- facebooks-instant-personalization/)

But of course, facebook doesn't want you to turn it off so they made it a few clicks:

<http://www.youtube.com/watch?v=j0Ei3HNeQkc>

</comment><comment><USER3> I have the Disconnect extension for Chrome installed so I can't see what the submitter is trying to get me to see. Can someone fill me in?

I'll be an intern at Yelp this summer, so I'd like to know what I'm getting into if shady things are happening.

<comment><USER4> I assume the poster is looking at instant personalization on Yelp (<http://www.facebook.com/instantpersonalization/>), which was introduced last April.</comment></comment>


HackerOne and Former MySQL CEO Marten Mickos Interview - <AUTHOR> https://openchannel.io/blog/what-ive-learned-with-marten-mickos/ <comment><USER2> I always find it interesting to listen to Marten's ideas and thoughts. I met him in 2007 (back when he was CEO of MySQL), and have been following him since. I then met him a few more times when I moved to Silicon Valley. Direct, honest, great at delegating and empowering his employees.

</comment><comment><AUTHOR> Ideas on remote working and open source, but also shows that someone like him is still willing to help growing companies by being a guest, which is pretty cool!</comment>


How to Interview a Designer - <AUTHOR> http://www.quora.com/Jason-Putorti/How-to-Interview-a-Designer <comment><USER2> "Trial and error. Give him or her a UI component to redesign, or present a problem you've been facing and ask for some ideas on how to solve it."

Asking for ideas is cool. But I don't personally agree with having to re- design something on the fly for them. If I don't come up with the ideal solution in a short time, I don't think it should make-or-break the job. Design needs time, just as much as any other craft.

Actually, I remember one company offered to interview me after viewing my portfolio. They asked me to re-design a news website as a test. Since they are a really big firm and well-known agency, I did it. After seeing two iterations, they rejected me.

I eventually got a job at another well known agency (without having to do any tests). Funnily enough, the news agency whose website I had re-designed in that previous interview test signed up with the agency I was currently working with. Thus, in the end, I ended up actually doing the real work.</comment>


Ask HN: AngularJS vs Backbone vs Ember? - <AUTHOR>

Hi guys,
I'm starting a new project and am wondering what are the pros and cons of each framework over the other?
Thanks! <comment><USER2> Angular beats Backbone like a prison rape scene. I wrote the peepcode backbone todo app in 1/3 the code using angular (over here: <https://github.com/ludicast/angular-peepcode-todo>, n.b. I haven't had time to update to newest Angular)

Haven't used ember, but I do mancrush ykatz, so sure he is taking it to good places.

</comment><comment><USER3> You first need to consider what _kind_ of framework you want.

Backbone is a very light MVC framework that provides you a few minimal tools for structuring your project. It doesn't get in your way, and it won't have any performance issues. On the other hand, it doesn't hold your hand, and it doesn't help you solve any especially hard problems. A simple demo app tends to look very clean when implemented in Backbone, but anything more complicated will require you to write a _TON_ of code. (By design; Backbone only provides functionality that everyone will need, regardless of the type of project.)

The other two you listed are heavier, and more opinionated. They will do a lot more to help you, _if_ you're working the way they think you'll work. If you aren't, they can be counter-productive; it's not hard to miscode something to get a major performance penalty.

I evaluated every framework I could get my hands on, and settled on Knockout. It's quite similar to AngularJS and Ember, but feels more mature than either, and has great documentation. Its killer feature is it's two way bindings between the DOM and the JS models.

My project is basically a very complex CRUD app; I've got tons of complex, deeply nested records I need to display and let users edit; a good, fast, clean UI for doing so is crucial. My initial spike using Backbone bogged down in endless boilerplate to try and keep everything in sync, and tons of ugly JQuery code to manipulate the DOM. (And was buggy to boot, which I'm sure was my fault, but highlights that Backbone can have a somewhat rough learning curve.) Knockout, however, made it a snap. My code was shorter, cleaner, easier to write and maintain, and fast.

So, my suggestion: Backbone if you're comfortable with writing all the functionality you need from scratch, and just want a little structure for your app. On the other hand, if you want a very robust framework for writing CRUD apps with a rich UI, and want to make your life easy, go with Knockout.

(Ember and Angular are good too, but in my view they're too similar to Knockout. There's just no compelling reason to choose them, given that Knockout is more mature and polished.)

<comment><USER4> AngularJS has very many similarities with Knockout, except the templating vocabulary is completely extensible (you can create components by creating new HTML elements and modify behavior of existing elements using custom element attributes).

Also in contract to KnockoutJS, AngularJS doesn't require any special wrappers for your model (no ko.observable() all over the place), which means that it's less intrusive and allows you to create models the way you want them to be (need a native array, primitive or custom type? no problem).

</comment></comment><comment><USER5> Our front-end team did extensive research on this that wrapped up a just a couple days ago. They landed on angular and have been very happy. I'll see if I can get one (or more) of them to comment on their findings.

</comment><comment><USER6> In order to make a reasonable choice between js MVC frameworks, the best is to write on your own a small app and decide for yourself. During my research, I have the following chart. 1\. JavascriptMVC 2\. AngularJS 3\. Backbone All the rest (Ember, Knockout, Dojo) aren't nearly close to the 3 winners. Backbone and Angular were described quite good. So, I'll add what I've loved about JavascriptMVC (JMVC) and what problems it solves out of the box: Problem 1: How to structure the project? Where are 100+ variants to structure the folders of the project. It's important when is grows. JMVC has automatically generated empty project with very clean structure: separate folder with models, and separate folder per module for controllers and views. Problem 2: AMD AMD is built in into JMVC Problem 3: jQuery support JMVC is built on jQuery, so no collision happens what so ever Problem 4: Documentation JMVC has plenty of ot including API description, tutorials and active community Additional sugar: It has built it google closure compiler and minifier and checks your js code and optimize it; It has built in documentation script that generates documentation out of comments. Thus, JMVC is not just an Javascript MVC framework, it's great set of tool for the development of serious heavy apps.

</comment><comment><USER7> Angular is fast and easy for development. Very ittle boiler-plate and comes with easy UI bindings. I feel it's perfect for smaller projects where separation of logic isn't as important. Angular has the ability to grow in complexity if you need it too.

Backbone comes with a lot of boilerplate, but honestly is worth it if you have a larger front end app. Being able to have your data trickle though your models and views in a concise structured way can make changes as well as fixes much easier in the long run. Backbone's persistence functionality is pretty phenomenal as well.

Ember relies pretty heavily on Handlebars. If you're game to use that for your client side rendering than it could be a good option. Ember looks similar to Backbone but makes a few things easier such as computed properties and bidirectional bindings. I haven't touched it much yet as I'm currently working in Backbone and Ember's current lack of an "official" persistence mechanism turned me off a bit.

All three of these are great frameworks. Angular is easier to pick up but Backbone has more users and more users means someone has probably ran into a problem that you possibly will and has already asked a question on StackOverflow. That alone can be invaluable.

</comment><comment><USER8> I have the same problem at the moment. I think I'll do backbone and move to Ember. I remember reading somewhere the google people is saying AngularJS is their experiment, so lots of things might get deprecated or change. I wouldn't bank on it if its pace of changes is crazy.

<comment><USER9> AngularJS v1.0 was released couple of weeks ago. There are too many internal apps at Google to break the API, so I wouldn't be afraid of this.

</comment></comment><comment><USER10> I'm interested in this too, I did find a blog post which does some comparisons: [http://codebrief.com/2012/01/the-top-10-javascript-mvc- frame...](http://codebrief.com/2012/01/the-top-10-javascript-mvc-frameworks- reviewed/)

<comment><USER4> That post is unfortunately incorrect. The author claims that AngularJS doesn't have "composed views" which is very unfortunate because out of all the frameworks he listed Angular's component composition model is by far the best, he just didn't bother to investigate it despite several users pointing out the error in the discussion under the post.

<comment><USER11> It also mentions that "asynchronous UIs" (ie, optimistic save: server callbacks don't block, if something bad happens you'll solve it in a callback) need some sort of operational transformation (think google wave), but I think this only applies if you are writing real-time multi-user apps (chats, google docs, etherpad, etc) which is the overwhelming minority of mobile apps.

</comment></comment></comment><comment><AUTHOR> Thanks for the comments, guys. I've just experimented with AngularJS and have managed to build most of what I need in less than a week.

As a side project, I might attempt to work with the other frameworks as a comparison.

</comment><comment><USER12> I find AngularJS the best.

</comment><comment><USER13> vs Knockout?

<comment><USER14> Knockout is great. I've been using it heavily for the last year.</comment></comment>


New elastic polymer self-heals in just one minute - <AUTHOR> http://arstechnica.com/science/news/2011/04/new-elastic-polymer-self-heals-in-just-one-minute.ars <comment><USER2> That's pretty cool. I can't wait to see it for sale on inventables.com or some similar site.

<comment><AUTHOR> inventables.com <\-- wow, that is even cooler, never seen that one before. Thanks for posting that (my arduino pet projects just go insanely more interesting).

<comment><USER3> inventables is neat, but I find most of the stuff can be had more cheaply elsewhere

<comment><USER4> Yeah, I agree - I think you are paying for the convenience for what are essentially samples. Which is worth a lot - tracking down all o the materials and ordering them would be a time consuming task, if you even knew they existed -- this is in my opinion a fair tradeoff.

</comment></comment></comment></comment><comment><USER5> can I get this on my motorcycle fairings? replacing those is a pain $$$</comment>


Tell HN: Why you should submit your stuff as a blog posting - <AUTHOR>

Self posts are strongly discounted on HN, if you post a question or an article without a link then you will find that there is a good chance that you will not be getting any traction at all.
The reason for this is that self posts are discounted at (and this is a guess, maybe PG can correct me) roughly 40% of what it would take to get a similar frontpage ranking for a regular post.
So even if your well formulated article that you posted on HN (nice, because you are obviously not in it for the advertising revenue) is voted up a few times its chances of being really discussed are very slim indeed.
On the other hand, you could post an external link to an article about prostitution ( http://news.ycombinator.com/item?id=1075970) or the latest episode in one of the soaps (http://news.ycombinator.com/item?id=1075944) and you'd be guaranteed plenty of discussion.
The practical upshot of this is that if you really want an answer of if you really want to discuss a subject and you think that it is not mainstream enough to catch a couple of upvotes in the first half hour you can more than double your chances by posting it elsewhere and then submitting the link.
I don't pretend to understand the reason behind the penalty assigned to 'Ask HN' style posts and articles that are posted as original content on HN, I just notice that plenty of those seem to drop sight unseen whereas lots of trivial content makes the homepage without too much trouble, as long as it is on an external site.
We'll see if this post is self-defeating ;)
To see how big this effect is, as long as this post is on the homepage you can check it against other posts with links that have roughly the same number of points and age. <comment><USER2> -1. Why didn't you post this on your blog ? :D

<comment><AUTHOR> > We'll see if this post is self-defeating ;)

But compare the position this entry has on the homepage with the others around it, the key metric is (points / age), and you'll see that linked posts with a lesser score by that metric still rank much higher.

</comment></comment><comment><USER3> Did you get this from looking at the source code?

<http://github.com/nex3/arc/blob/master/news.arc>

<comment><AUTHOR> No, just by observing the various postings and how they appear and disappear on the homepage.

I think this is one of the main reason why plenty of Ask HN style threads are gone before anybody gets a chance to look at them.

They're unpopular by definition, after all they ask the audience to do something (answer a question), this adds to that.

Then today I saw an Ask HN that was doing exceptionally well, and I noticed that the only thing that caused it to be ranked so high was that it was an external link.

<comment><USER4> Here's the comment about some downweighting for lightweight sites. <http://news.ycombinator.com/item?id=294439> Here's one confirming the downweighting of self posts, though without saying the modifier. I remember the modifier as being 0.7, for what it's worth. <http://news.ycombinator.com/item?id=304058>

<comment><AUTHOR> Thanks for digging that up.

The original posting is this:

<http://news.ycombinator.com/item?id=303605>

And that's what PG comments on, see the thread.

The interesting bit is that there are some self posts (such as that specimen) that clearly deserve their 'weighting' but there are plenty of others that do not, and these fall victim to the collective punishment meted out to all submissions without urls.

I estimated the .4, so apparently it is even less.

<comment><USER5> I think that many of the Ask YC or Tell HN posts tend to get more votes more easily, so the weighting makes sense even good posts of that sort. I noticed this in the source while we were asking for advice, but we still got a lot more spotlight with the Ask HN tag than when we tried to do similar things with blog posts. The weighting makes sense to me.

<comment><USER6> _I think that many of the Ask YC or Tell HN posts tend to get more votes more easily_

Yes but do you wonder why that is?

From my own experience I know if I only have a minute or two, I hit on "New", scan down for Ask/Tell HN and then if they are decent posts, immediately upvote them. So sure, Ask/Tells get more votes from me _because they are more likely to have unique content_ as opposed to the Nth million Apple Tablet rumour.

Moreover, even though I couldn't be further away from startup circles, it is clear that HN is clearly a startup community, and Ask/Tells are the posts that are most likely to tap that vein - so I upvote them in line with what I think are the community values. I mean, if I don't upvote a "Review my site" plea, what am I here for?

I'm not sure why exactly the ranking penalty for that is so large. It's all very well to say "well post it on your own blog", but the style of discourse over a blog posting is considerably different for what I see in Ask/Tells; the comments on the latter are generally more supportive as they are seen as a plea for help and less as an attempt at self-promotion - precisely because they are more transient. Moreover, an Ask/Tell in a way is a debate on neutral ground, whereas comments on somebody's personal blog post don't quite have the same dynamic.

</comment></comment></comment></comment></comment></comment><comment><USER7> _nice, because you are obviously not in it for the advertising revenue_

Just because you link to your blog doesn't mean you are getting ad revenue (ex, my blog has no ads).

I personally feel that Ask HN posts are weaker because they are transient. To Ask HN is to have a discussion that lasts maybe a day with a small number of (relatively) like-minded people. A blog post will be more visible for "longer" (I don't recall any Ask HN posts showing up on Google, so their lifespan is basically their front page time), and represents a stronger commitment to the point made. Not all blogs have comments, but generally they do, and are open to a wider audience than HN.

</comment><comment><USER8> It's pretty sad self posts are discounted, since they IMHO are one of the best parts of HN.

</comment><comment><USER9> The practical thing is that when you submit as a blog post, other people might link to you. Noone is going to link to a post they read on HN.

But a blog post? Oh yeah.

Remember my rant a few weeks ago about how the Crunchies were the kid's choice awards of the web? That got picked up by LA Times and they linked to my post in one of their stories. I doubt that'd happen if I posted the same exact thing as a "Tell HN" post.

</comment><comment><USER10> _The practical upshot of this is that if you really want an answer of if you really want to discuss a subject and you think that it is not mainstream enough to catch a couple of upvotes in the first half hour you can more than double your chances by posting it elsewhere and then submitting the link_

This has always been the recommended approach by pg.

</comment><comment><USER11> Sounds to me like HN is a victim of its own success and is rapidly going the way of Digg. There's a reason people write "trivial" content: It gets clicks.</comment>


Red Hat loves .NET - <AUTHOR> http://redhatloves.net/ <comment><AUTHOR> Not an april fools.</comment>


How Couchbase helped OMGPOP break all the records with Draw Something - <AUTHOR> http://blog.couchbase.com/how-couchbase-helped-omgpop-break-all-records-draw-something

<comment><USER2> Couchbase is awesome. Not sure why we don't hear it more frequently when talking NoSQL -- it's a natural fit for massive client-server games.

</comment><comment><USER3> Couchbase Server is a great solution for all mobile applications because the scaling and the schemaless database.</comment>


Microsoft admits that its Windows 10 upgrade campaign went too far - <AUTHOR> https://www.extremetech.com/computing/241587-microsoft-finally-admits-malware-style-get-windows-10-upgrade-campaign-went-far <comment><USER2> Great. Now all that's left is to admit that the "let's track everything users do on their Windows computers" campaign went too far as well. Hopefully not after Windows 10 is already on 1.5 billion PCs and they've already fully exploited all of that data, like their doing now with the "apology" for the upgrade campaign, half a year after it's no longer in effect anyway.

<comment><USER3> Sort of like stealing a bicycle and then ask for forgiveness when caught.

</comment></comment><comment><USER4> The forced reboot for Windows Updates in Win10 is also very aggressive. I believe you get a choice of [Now] or [Later], where Later does a surprise reboot in N minutes -- without even letting you save your open documents.

<comment><USER5> Or, if you leave it on overnight, you'll get a reboot with no notice at all. I strongly recommend that you disable the Windows Update service, with the caveat that you enable it once a month or so when you can reboot.

</comment></comment><comment><USER6> Why apologize now? The damage is done, their big net has upgraded millions of unintended users. I can only speculate at what their next deliberate and calculated move will be.

My money(figuratively) is on subscription fees are coming. How will they deprecate the non-payers, more ads? They wouldn't black screen millions, would they?

</comment><comment><USER7> I remember the @MalwareMinigun @BrandonLive tweets.</comment>