News for hackers. Stuff that matters.
Re:How Notion pulled itself back from the brink of failure (... by black_puppydog on Thursday June 17, 2021 @11:44AM (#27540878)
Since it's not discussed in this article: Is there a write-up of the "suboptimal tech stack" and the hows and whys of the rewrite?
Re:How Notion pulled itself back from the brink of failure (... by jitl on Thursday June 17, 2021 @11:52AM (#27540987)
I joined Notion two years ago, so this era predates me, but I can shed a little bit of light:

1. The web UI used Polymer/Web Components. Simon (CTO/cofounder) described this as building on shifting sand as browsers and poly fills changed the standards and things never seemed to work well for long.

2. There was a lot of Redis with Lua action, using Redis instances as a distributed system for some purpose I don’t understand. This never worked well.

3. There was experimentation with graph database like Neo4J which turned out to be slow for the kinds of queries Notion needed to do. Not sure if this was part of the first era or if it was tried out for the rewrite.

Because of all that, they completely rebuilt the product using the most boring/normal technology possible. Today we run on Postgres/Memcached for data, a Redis for rate limit and queueing, and a Typescript/React front-end.

Re:How Notion pulled itself back from the brink of failure (... by reidjs on Thursday June 17, 2021 @12:17PM (#27541314)
As much as I like the idea of webcomponents and graph databases, I'm glad I left a job that was shifting towards using them. As cool as they are, they are a bit too risky to devote serious career time. I really hope webcomponents become a serious choice someday for your average developer, though.
Re:How Notion pulled itself back from the brink of failure (... by mimixco on Thursday June 17, 2021 @06:47PM (#27545305)
We make a product in the same collaboration space as Notion but we're a younger company. Our latest stuff is all Lit (what became of LitElement and Polymer). Today, web components in general (and Lit in particular) work really well on all modern browsers.

For us, with the current state of web components, we see this as the ideal time to move to all web component UIs going forward. We view it as a strategic advantage.

Re:How Notion pulled itself back from the brink of failure (... by bartaxyz on Thursday June 17, 2021 @02:22PM (#27542732)
From the look of the code of their website and the fact that they have 'isReactNative' variable declared, I believe they're using react-native even for their website. Which would make it single frontend codebase for all of their platforms.
Re:How Notion pulled itself back from the brink of failure (... by jitl on Thursday June 17, 2021 @02:55PM (#27543147)
I'm an engineer at Notion. We don't use React Native (I worked on the rewrite of our apps to remove it). There's still a bunch of code that refers to our mobile app platform as reactNative, which is what you're seeing.
Re:How Notion pulled itself back from the brink of failure (... by bartaxyz on Friday June 18, 2021 @04:03AM (#27548345)
Neat!
Re:How Notion pulled itself back from the brink of failure (... by moooo99 on Thursday June 17, 2021 @02:54PM (#27543125)
Sharing the codebase between all apps would definitely be an explaination for the occasionally unpleasant desktop experience.
Re:How Notion pulled itself back from the brink of failure (... by askafriend on Thursday June 17, 2021 @02:48PM (#27543064)
But React Native is a mobile framework...how can they use it on their site? I don't think that quite makes sense.
Re:How Notion pulled itself back from the brink of failure (... by philip1209 on Thursday June 17, 2021 @02:56PM (#27543150)
Re:How Notion pulled itself back from the brink of failure (... by manmal on Thursday June 17, 2021 @03:20PM (#27543442)
This project really has gone full circle.
Re:How Notion pulled itself back from the brink of failure (... by askafriend on Thursday June 17, 2021 @11:20PM (#27547033)
Wow...that's both hilarious and amazing at the same time.
Re:How Notion pulled itself back from the brink of failure (... by ksec on Thursday June 17, 2021 @09:03PM (#27546257)
I always thought they were using Ruby Rails. Looks like I was wrong. What do they use for their backend now?
Re:How Notion pulled itself back from the brink of failure (... by myth_drannon on Thursday June 17, 2021 @12:50PM (#27541680)
I thought UI is in Clojurescript with Datascript, or was it Roam...
Re:How Notion pulled itself back from the brink of failure (... by jitl on Thursday June 17, 2021 @02:56PM (#27543157)
That's Roam.
Re:How Notion pulled itself back from the brink of failure (... by Barrin92 on Thursday June 17, 2021 @05:31PM (#27544699)
Some of the clones use Clojurescript too. Athens and Logseq for example. Seems to be weirdly popular in this particular niche.
Re:How Notion pulled itself back from the brink of failure (... by ronyeh on Thursday June 17, 2021 @12:27PM (#27541430)
Thanks. Interesting to hear what goes on behind the scenes!

Random bug report. On Android while making checkbox lists, I always have to hit enter twice to get to the next line. If I hit enter once, the cursor visually moves down to the next line, but once I start typing the new line gets joined back onto the previous line. I notice this happens when I don't add an extra space at the end of the first todo/checkbox item. Sorry to jump on your comment with a bug report!!

Re:How Notion pulled itself back from the brink of failure (... by jitl on Thursday June 17, 2021 @03:09PM (#27543299)
Interesting, we fixed a bug like this on iOS when iOS 13 came out. I wonder if your keyboard is doing something similar to the iOS 13 keyboard. What phone, OS version, and keyboard software do you use? Does this happen with all keyboards, or just your favorite one?

(I tried on my Pixel 2 / Android 11 with Swiftkey and Gboard in English and Korean, couldn't repro)

Re:How Notion pulled itself back from the brink of failure (... by ronyeh on Thursday June 17, 2021 @07:44PM (#27545734)
I can send this bug report into your regular notion support email.

But I'm on Android 11 on a Motorola hyper one with the default Gboard in English. I just downloaded notion today and my OS has no pending updates.

I can repro 100% of the time.

- [ ] my to-do item$

- [ ] my to-do item $

In the above two examples, if I press enter when my cursor is at the end of the line (indicated by the dollar sign), the top example does the wrong thing. The bottom example works fine.

Re:How Notion pulled itself back from the brink of failure (... by oujunhao on Thursday June 17, 2021 @07:09PM (#27545488)
Not OP, but I have this same issue on a OnePlus 7 Pro with Android 11, using Gboard in English. Interestingly enough, it doesn't happen when using Gboard in Korean or Chinese.

Also, if I tap on the end of a line and press newline, I get another block. If I type something and then press newline, then it happens exactly as ronyeh described (again, only with Gboard in English)

Re:How Notion pulled itself back from the brink of failure (... by mimixco on Thursday June 17, 2021 @06:42PM (#27545253)
Notion blogged (once they fixed the problem) that their original design had all customers' data in a single, unsharded database.