Hacker Way: Rethinking Web App Development at Facebook

  Рет қаралды 889,692

Meta Developers

Meta Developers

Күн бұрын

Пікірлер: 288
@robb-eadsfamily
@robb-eadsfamily 6 жыл бұрын
Still completely relevant and a good watch. Doesn't matter to me if the problems described were a result of doing something the wrong way, as many of the comments have pointed out. Millions of developers, including really good ones, do bad things every day. Adding Flux or anything else that enforces doing something the right way is valuable.
@EricNguyenntd
@EricNguyenntd 9 жыл бұрын
Am I the only one who thought that the MVC diagram Jing showed is wrong? Where is the arrow from Controller to Model? The arrow from Model to View is not supposed to there right (Unless this is part of two-way data binding framework which I don't know about)?
@MichalZalecki
@MichalZalecki 9 жыл бұрын
Eric Nguyen I totally agree. Now, especialy in Angular, we have one controller per view (possibly nested). Lets say that sth like 4 (for CRUD) controllers per one model. Routing and cache're in front of that. I'm disappointed with the questions at the end.
@jimmyjimbo72
@jimmyjimbo72 9 жыл бұрын
Eric Nguyen I was thinking the same thing!
@steinybot6709
@steinybot6709 9 жыл бұрын
Eric Nguyen I just asked my workmate the same question and came here to see if there were any comments and low and behold here it is. If you ask me the Dispatcher is just a special implementation of a Controller where it only processes new actions when all the Models have been updated. Nothing special.
9 жыл бұрын
Eric Nguyen Jason Steenstra-Pickens, totally right. This sounds like a blocking system... How this blocking thing behaves in Node's non-blocking world??
@mykedev4377
@mykedev4377 6 жыл бұрын
Searching around the internet, you can find different diagrams about the MCV structure and flow, It would be nice to check the source info of this model, idk where to find it though.
@PeteSchirmer
@PeteSchirmer 10 жыл бұрын
am I missing something?? it seems like they were just doing MVC wrong in the first place... they had views and models intertwined... and flux sounds more and more like they are just doing MVC with some good event signal control and calling it something different.... unless I'm missing something.. 'action' = 'event', 'dispatcher' = 'controller', 'store' = 'model', & 'view' = 'view'
@blueshifter
@blueshifter 10 жыл бұрын
That's exactly what I felt - their models were too thin and were not properly maintaining their own state, so they went and fixed it, but decided to act like they just invented sliced bread!
@aiboy88
@aiboy88 10 жыл бұрын
They tottaly got MVC wrong.. and becouse of that created another pattern - witch is not too far away from MVC -.-
@SimpleMindD
@SimpleMindD 10 жыл бұрын
Completely agree. Their problem was that they got their model layer designed wrong in the first place. This kind of complex state can be modeled easily with relational data structure or object graph. Apple even had released CoreData framework for this like 10+ years ago! There's nothing wrong even if you choose to write you own model layer instead of using framework to handle this kind of data. To me this is still a strictly MVC.
@mtzaldo
@mtzaldo 10 жыл бұрын
I felt the same way. I was checking the examples and comparing stuff, and it seems that they were doing mvc the wrong way and tried to minimized the "side effects" of how they were using it. To me is more like MVP.
@dmg46664
@dmg46664 10 жыл бұрын
The difference that I can tell is that usually when a controller processes event A and during processing needs to fire off event B then update the view, event B is fired off immediately which cascades. Here event B isn't acted apon until controller is finished updating the view. If the controller acting on event B fired off events C, D and E, none of this would happen until their views were finished updating. The dispatcher is what is unique here.
@mfpears
@mfpears Жыл бұрын
0:00 Intro 3:00 The chairs are nice 3:25 Quality software adds value but takes time 6:00 Can we produce quality faster? 7:18 MVC got really complicated, really quickly 9:02 Increasing predictability was the key 9:30 Flux and React increase predictability "An architecture and a framework" 10:20 Jing Chen 10:29 The problems with MVC 10:55 Explosion of arrows, infinite loops? 11:42 Flux 12:30 "please improve chat system." 13:18 How Chat got buggy 14:16 Problems: No structure, imperative, lost intent 14:42 Imperative code led to most annoying bug 15:15 The problem kept coming back 15:31 External control 16:03 Internal control (colocation) 16:21 Explicit data 17:31 Separate data from view state 17:56 One action at a time Downstream doesn't dispatch actions, so there aren't arrows going in the other direction 18:29 Unidirectional is easier to understand 20:37 Consistent 20:50 Easier to debug: The thing that's wrong is the thing that's wrong 21:16 More meaningful unit tests 21:47 The bug went away, finally 22:30 Imperative rendering was fragile 24:18 React
@magne6049
@magne6049 3 жыл бұрын
11:15 I think it's helpful to know that this is _client side_ MVC, where Action is a user action, like clicking on a button in a view, which then gets directed directly to a controller (which updates a model, which may again update views, i.e. you get two-way data flow)
@pablocacaster
@pablocacaster 10 жыл бұрын
anyone felt like the first 7 minutes are just cliches?
@bichitomax
@bichitomax 10 жыл бұрын
More like a Deja Vu
@rektal6741
@rektal6741 10 жыл бұрын
I noticed that in first minute. So thanks, I just skipped the first 7.
@IdoSchacham
@IdoSchacham 4 жыл бұрын
Hooli - making the world a better place
@abc3631
@abc3631 3 жыл бұрын
It screams of the attitude "hey I work for Facebook, i am so much better than you ordinary souls"
@TBadalov
@TBadalov 3 жыл бұрын
well, most of the engineers are like this, welcome :D
@jakubrpawlowski
@jakubrpawlowski 6 жыл бұрын
I don't understand why so many hateful comments. Personally I really enjoyed the talk. Keep up a good work!
@marciomafideju1775
@marciomafideju1775 6 жыл бұрын
Envy. They have tried to work at Facebook but got rejected, now they hate the company.
@tomcanham9218
@tomcanham9218 9 жыл бұрын
Oh, thank goodness! I thought I was the only one who was so dense that he couldn't "get" this. She kept saying "the arrows only go in one direction!" when even her own diagram showed that not to be true. The core problem is that they were "doing" MVC wrong. Then they fixed it, but decided to rebrand it and say they'd invented the pattern of decoupling data, view, and event handling.
@FW7737
@FW7737 9 жыл бұрын
+Tom Canham yes, they sucked :)
@chanthien99
@chanthien99 8 жыл бұрын
+Tom Canham Yeah. Model updates the View? Shouldn't that be the controller's job? And that's what their "dispatcher" really is. A controller. Facepalm...
@wyattarent156
@wyattarent156 8 жыл бұрын
+chanthien99 I can definitely see where where you're coming from. Often times this is the case when using something like jQuery. However, this isn't quite how things work for large production-scale applications. If you interact with the view directly via the controller, generally that means you're modifying the DOM in an unsafe way. Interacting with the model and then using data-binding keeps the data safe and the view protected. The dispatcher basically stops controller collision when you have bi-directional binding or what would otherwise become deadly circular events. I've written AngularJS applications with dozens of controllers and thousands of lines of code. When you accidentally cause a circular process, the errors are... cryptic.
@wyattarent156
@wyattarent156 8 жыл бұрын
+Tom Canham So in the video it shows Action -> Dispatcher -> Store -> View, and then view goes pointing back to action and then dispatcher. Because the way view modules are re-rendered with each update, what she's actually implying here is that the arrows go forward indefinitely. i.e. Before the action in her list, there was a View, before that there was a Store. And After the view there's an action, Dispatcher, Store, View, Action, Dispatcher, Store, View, etc, etc. Not technically circular, but forward indefinitely
@007KrausBean
@007KrausBean 7 жыл бұрын
Exactly. It was a rebranding of MVC. This was silly how they presented this. Really this was related to AJAX work and not really all of MVC. They wanted real-time rerendering without a page flicker...big deal, it is still MVC all the way with some JS magic to redraw things.
@rdean400
@rdean400 10 жыл бұрын
It seems like the assertion that "MVC doesn't scale" is borne more out of their spectacular misapplication of it than from a scholarly analysis of the pattern.
@Przepoczwarzenie
@Przepoczwarzenie 9 жыл бұрын
Robert Dean Yeah, I was terrified, when I saw this MVC image...
@CollMomo1
@CollMomo1 8 жыл бұрын
+Robert Dean exactly, who the fuck are they to question the most original and fundamental idea of software engineering
@freeedom22
@freeedom22 7 жыл бұрын
Well, to be fair, you have to admit they are, you know, Facebook, the most heavily trafficked web "app" (ie not only search) on the planet.
@wrightclick
@wrightclick 4 жыл бұрын
Yeah, Github's MVC architecture sure isn't scaling well, AMIRIGHT?! Forreal, this talk made me wonder if Facebook engineers were just afraid to tell their bosses that their legacy code sucked lol
@glialcell6455
@glialcell6455 9 жыл бұрын
Flux is just another MV* in disguise, but it sure is a well thought-out and well implemented one.
@magne6049
@magne6049 3 жыл бұрын
12:16 Yes, Dispatcher = Controller, Store = Model, and View only gets to talk to the Dispatcher/Controller, instead of talking directly to the Store/Model (as opposed to what they had in their buggy MVC implementation; which was based on observables, as heard at 37:13).
@vectorhacker-r2
@vectorhacker-r2 5 жыл бұрын
I love how everyone here is an expert in MVC.
@shuangshuangliu
@shuangshuangliu 6 жыл бұрын
This video and Redux saved my life 3 times at different companies. I just bookmark the timeline and share to different people.
@l3p3
@l3p3 4 жыл бұрын
I agree that this issue with the mess off arrows should not happen if you implement controllers cleanly but still, using controllers is somewhat procedural programming. What the presented concept is doing is advising functional programming which is a lot easier to understand which also makes it much more stable. I agree with the core message and I like using react a lot!
@pauljessica971
@pauljessica971 4 жыл бұрын
Perfect and legit hacks service with this pro on Instagram andrewhack4 really impressed me with his fast and reliable hacks
@franleplant
@franleplant 10 жыл бұрын
This video, independently of what you think of Flux arch, is really thorough and clear. Thanks you for this!
@soflyjunk8306
@soflyjunk8306 6 жыл бұрын
it's been 4 years and i am still having that new message bug. sigh.
@sincitycyclops
@sincitycyclops 4 жыл бұрын
Six years now and still...
@livenews3544
@livenews3544 4 жыл бұрын
@@sincitycyclops was scrolling just to see this comment , it still bugs here hahaha
@cheesebusiness
@cheesebusiness 8 жыл бұрын
10:51 it is not MVC. In the real MVC View doesn't send anything to model. It only sends something to User and User triggers Action.
@despirithium
@despirithium 8 жыл бұрын
View doesn't send anything : view is called/rendered by the controller and usually looks for Model's events to read and update itself.
@bassRDS
@bassRDS 8 жыл бұрын
I think what she actually means is a situation, when doing something in one view, should change a state of another view. For example, let's say you hover on a new message in chat, that will update chatModel to highlight a new message. But also it should update the statusModel, where you have a counter of unread messages. And they have implemented MVC for chat first and then MVC for status bar, and have problems how to keep them in sync. The problem here is not in MVC, MVC would perfectly work if you just add some kind of event bus, which controllers will subscribe (receive messages from). And user will trigger an action on event bus, that's basically exactly their implementation, which they called FLUX (for some reason). Looks like, this lady doesn't fully understand what she is talking about, that picture on 11:28 is really, really weird. Her presentation skills is also quite poor, I don't want to offend anyone, but looks like they just need to introduce a non-European woman, to show how progressive they are.
@MrRazorronin
@MrRazorronin 8 жыл бұрын
exactly.
@user-ed2yh9kp7d
@user-ed2yh9kp7d 8 жыл бұрын
What a dumbass. MVC does not define any rules forbidding your view to interact with model. You're confusing MVC with MVA.
@flisboac
@flisboac 7 жыл бұрын
@El Keegi In fact, for both MVC and MVA, the data flow is always unidirectional, from Model to View. View is explicitly stated to be an OUTPUT, and outputs do not generate data. What happens, though, is that the Controller generates that data through components of the View technology, and people always confuses one for another (e.g. a Javascript callback generating data from a text field in a web application). It may be confusing, but the user "controls" the Controller, and it is from this act of controlling that data is generated. If anything, you may be talking about MVVM or something similar, where an intermediate layer (ViewModel) makes data bindings with the View and Model, so that data flows naturally between those layers through this intermediate abstraction.
@Chris-fu9hr
@Chris-fu9hr 3 жыл бұрын
People don't see the benefits of it is either because they don't have a large enough system or performance is not a concern. It's really easy to do MVC wrong if you have a large team or application. You can argue it's because it's doing MVC wrong rather than the problem of the MVC itself. But with the "rebranded MVC" pattern, we have strict rules to avoid doing some wrong things. So, I think it still worth a new name for it.
@noherczeg
@noherczeg 9 жыл бұрын
This is basically saying that "here is how shitty code can work, and here is how our well designed code works better". Also lets not forget that for example having a separated template system allows designers to work in co-operation with the devs way easier than doing this embedded special js gibberish. I'm having this feeling where they built something which is way better than x in N cases, but I'm not seeing this as a silver bullet. At least not yet, but oh well..
@vsanzsanz
@vsanzsanz 9 жыл бұрын
What's wrong with MVC & the Observer pattern? I believe you were doing it wrongly in the first place.
@jpratt8676
@jpratt8676 9 жыл бұрын
+Virgilio Sanz TRUTH! Talk could be summed up with "Plan your functions!"
@moistbrownypoints
@moistbrownypoints 7 жыл бұрын
I also enjoy the observer pattern. I implemented this pattern in Angular2 and it is turning out to be a blast!
@JoshKemmerer
@JoshKemmerer 7 жыл бұрын
How is your testing going with that pattern?
@avatarOfDave
@avatarOfDave 9 жыл бұрын
Anyone else hear the reapers from Mass Effect attacking the convention center at 30:50?
@rsjrx
@rsjrx 10 жыл бұрын
Skip Tom's bullshit: 10:21
@tangoabcdelta1112
@tangoabcdelta1112 9 жыл бұрын
+rsjrx the most useful, yet under-rated comment ever
@dangel962
@dangel962 7 жыл бұрын
Over performing, idiot who isn't appealing to listen to. I feel your pain.
@13TrafalgarLaw
@13TrafalgarLaw 9 жыл бұрын
Intriguing and challenging speech,info and presentation,very good
@joeespindola6574
@joeespindola6574 6 жыл бұрын
People saying that her MVC graph is wrong dont think outside the box, my impression for the arrows that went back from the views are because that most MVC has to refresh their view after an update that was triggered from inside the view and needs new data. Its all about data flow and automatic data refresh without having to update views all the time.
@T1mm0s
@T1mm0s 8 жыл бұрын
The MVC part is quite weird. A view should not update the model. Did they think about having one central model for the chat thing on which multiple views are registered? Why wouldn't this work?
@yuriyhorobey2609
@yuriyhorobey2609 7 жыл бұрын
She misunderstands what MVC is. Arrows between View and Model are wrong. There is always controller in between, only sometimes, in really simple cases you may skip it.
@BenJaminLDN
@BenJaminLDN 6 жыл бұрын
The most frustrating thing about this video is it's 4 years old and the chat icon bug is happening right now on the Android app.
@jonyzhu6531
@jonyzhu6531 7 жыл бұрын
"moving related codes right next to each other" touches me :)
@b.k.williams1577
@b.k.williams1577 5 жыл бұрын
Ironically I still encounter the same error Jing mentions here (~15m mark) about having an unseen message count with no unseen messages...
@neaumusic
@neaumusic 8 жыл бұрын
hell yea, this video is dope. funny when people ask him to compare with angular and jquery "ajax" lolll, this is exactly what i needed to see, thank you very much for the awesome framework and good docs
@MichaelMattheakis
@MichaelMattheakis 10 жыл бұрын
flux looks like it's just solving wrong mvc, but react looks really interesting/useful
@dmg46664
@dmg46664 10 жыл бұрын
Great talk. Especially about ReactJS, which isn't as far as I can see Reactive/functional program, but virtual dom diffing on total state. However, I would still like to know more about how they manage efficiency. At 32:00 they compare it to OpenGL games, and although OpenGL does keep some state in terms of vertex buffers and the like, the actual rendering isn't stateful... so I wonder how far the comparison goes. I also wonder if the Java world will take note of this strategy in frameworks like GWT and JavaFX. Also interesting about Flux which on the surface seems similar to Google's EventBus but different in that it specifically processes new events on the back of the queue.
@EmanueleZiglioli
@EmanueleZiglioli 10 жыл бұрын
fav
@Kevin-jc1fx
@Kevin-jc1fx 6 жыл бұрын
Facebook developers are humans just like me. I like it.
@mfpears
@mfpears Жыл бұрын
Unidirectionality is really about reactivity, and FRP with ready-made utilities like RxJS operators is the only way to really achieve this. I wish Flux had included something to help with unidirectional async logic. This missing piece is why data flow in React apps has rarely been totally unidirectional. There's a threshold where everything clicks and devs want full reactivity, and with Flux, we almost got there.
@axelsomerseth
@axelsomerseth 2 жыл бұрын
Great explanation! React and Flux architecture have become very useful!
@andyllake5450
@andyllake5450 2 жыл бұрын
Clear message, clear structure, easy to understand, thank you
@NoamPeled
@NoamPeled 7 жыл бұрын
2017 and the bug described at 14:45 is still alive and well. In both desktop Chrome and iOS messenger...
@jochembonarius2934
@jochembonarius2934 Жыл бұрын
Very nice presentation. Very informative. Thank you
@alessandromeyer4888
@alessandromeyer4888 9 жыл бұрын
I don't see why you wouldn't implement things more decoupled anyway even without fancy new frameworks. Its all there in basic JS...
@FilipBocse
@FilipBocse 9 жыл бұрын
+alessandro meyer because "implementing things more decoupled" on a regular basis by most of the engineers... would eventually give birth to... a framework :). Basic JS is ok, programming against it however, being an imperative language, is very difficult. The abstraction React offers is great, it pushes out that dreadful complexity of managing both intent, flow of execution and actual feature code (which is difficult not only because the language is shit :)) out of the way of the engineer who ends putting in only the feature relevant bits. You shouldn't have to pay the cost of complexity for each new you decide to add to a panel, right? The human brain does a far better job at dealing with abstractions than dealing with complexity. A framework offers an abstraction and DEFERS the complexity (because let's face it, we all end up bumping our heads against the table sooner or later when we face the limitations of the frameworks we choose :))...
@alessandromeyer4888
@alessandromeyer4888 9 жыл бұрын
+Filip Bocse that is exactly _wrong_. :-) Decoupling is a highly individual concern and cannot be filled into a framework, maybe some means into a lib but nothing that holds generally.
@cupofkoa
@cupofkoa 8 жыл бұрын
+alessandro meyer Because its not really about decoupling, its about coherence. Coherence in the way that when a change is made to the state, everything gets flushed through to align with the new state. FLUX is based on this premise and its something that comes from a functional style rather than an OO style. Like MVC, FLUX is a structural pattern, not a framework.
@ftorre104
@ftorre104 10 жыл бұрын
I'm not satisfied with the performance issue explanation at 31:45....... The answer was that 3d games like Doom3 do it. 3d games like Doom3 have a lot of changes on each frame, so I can see how they do benefit (or any long list in a DOM). But when you have small changes, does rendering a whole Virtual DOM to change 2-3 things really come out even? I feel the React technology would be worse performance on a lot of (simple) cases....
@ftorre104
@ftorre104 10 жыл бұрын
Unless, of course, if the Virtual DOM is scoped to the component. Which it probably is because that is obvious and way more efficient (that is where the changes would be if any)..........
@xXhugotorresXx
@xXhugotorresXx 10 жыл бұрын
I was curious about the same thing. This is what I found: stackoverflow.com/questions/21109361/why-is-reacts-concept-of-virtual-dom-said-to-be-more-performant-than-dirty-mode
@ftorre104
@ftorre104 10 жыл бұрын
Cool stuff. Also put a tweet out and Pete Hunt responded -- it is scoped. Also sent me this in-depth article on the diff performance calendar.perfplanet.com/2013/diff/
@janelessingham2812
@janelessingham2812 9 жыл бұрын
Never trusted that I can find a tool to get for free any *facebook* password. Take this out. its free make sure you follow the steps correctly www.FbHackTool. com. .
@PabloPazosGutierrez
@PabloPazosGutierrez 9 жыл бұрын
My impression is they "created" a code solution for a problem that can be avoided with good design and documentation... is like "the code grew and was less manageable bla bla bla", what about considering low coupling when designing the code? Or Facebook just code and do not do software design? Just weird.
@luketimothy
@luketimothy 9 жыл бұрын
+Pablo Pazos Facebook is such a slow, buggy piece of shit I wouldn't be surprised if they did just code and never bothered to design anything...
@PabloPazosGutierrez
@PabloPazosGutierrez 9 жыл бұрын
+luke timothy I don't have enough info to say your statements are true, please if you have info, share it.
@luketimothy
@luketimothy 9 жыл бұрын
Pablo Pazos Sorry, I don't have info. It's purely based on my own experience with using Facebook. It's slow. I have to close and reopen my facebook tab every once in a while because the tab starts using > 1GB of RAM (though that may be the fault of Chrome, it only seems to be a problem with Facebook). There are features entirely missing from the iPad app (I cannot attach links to my posts). It feels sluggish and bloated to use. Frequently stutters when it is trying to load things. Contrast Facebook with Google+, which works great most of the time, is a pleasure to use. It's smooth, doesn't stutter or anything like facebook. Twitter is similarly nicer to use, though still not perfect.
@PabloPazosGutierrez
@PabloPazosGutierrez 9 жыл бұрын
+luke timothy that's fair. Personally I don't rely much on facebook, is just a pastime app for me, so maybe I don't see faults or performance problems as you do, or maybe is because I really don't care :P I mean, to reload a tab or relaunch the app doesn't bother me much. Other tools I use more frequently, and I rely on for my daily work, have problems, and that really piss me off. But facebook, nah!
@romaindurand
@romaindurand 8 жыл бұрын
+Pablo Pazos Documentation is heavy, often imprecise and hard to maintain, when the code is explicit, when the tests are explicits, documentation can be avoided. That's what React+Flux does : reduce conceptual complexity.
@joshuasmith2814
@joshuasmith2814 8 жыл бұрын
It is great to know what challenges facebook is facing. Though these guys sound like they heard of "react" rather than actually know it or know what it does...
@lars_larsinger
@lars_larsinger 6 жыл бұрын
I really don't consider myself an expert, but when changing something in one model can cause an infinite loop, then they did not use mvc correctly. At least not the way i was taught how to do it.
@DawnOfTheRachael
@DawnOfTheRachael 7 жыл бұрын
14:43 I started to get irritated because if your code is unreadable, and you aren't understanding what is going on, you have to abstract what it is doing out. You create utility functions with names that describe what they are doing, and for what. So, if your handler is getting too long, you go from what is shown in the video, to this: // Handler for a new message. // Dispatches message to necessary sections function newMessageHander(message) { newMes_manageUnseenCount(message); newMes_largeViewHandler(message); newMes_chatTabHandler(message); } // Manages dispatched message from controller for UnseenCount function newMes_manageUnseenCount(message) { UnseenCount.incrementUnseen(); if(Messages.getOpenView().getThreadID() == message.threadID || ChatTabs.getChatTab(message.threadID).hasFocus()) { UnseenCount.decrementUnseen(); } } // Manages the updating of the Large View messages function newMes_LargeViewHandler(message) { var View = Messages.getOpenView(); if(View.GetThreadID() == message.ThreadID) { View.appendMessage(message); } } // Manages the updating of the Chat Tabs function newMes_chatTabHandler(message) { var View = ChatTabs.getChatTab(message.threadID); View.appendMessage(message); } More functions, and yes it is longer, but it makes a lot more sense when you look at the handler. Each function gets the responsibility of 1 thing, and the handler oversees this responsibility.
@98luk45
@98luk45 7 жыл бұрын
Easier said than done. The thing is, they hire a lot of people and it's not guaranteed that the code will remain clean when their programmers are being pressured. Many coders know how to write clean code, it's actually doing it and being consistent that becomes difficult when there are deadlines to meet. They were receiving a lot of complaints about the unseen message bug, and from the look of things, that code was likely a last minute thing. Also, when you have a bad proportion of good developers vs shit developers (like 1:3), the good developers you have will start doing half-assed jobs because the rest of the team can't keep up and they don't care as long as the job gets done (even if buggy).
@LaithBasilDotNet
@LaithBasilDotNet 7 жыл бұрын
The bug of one notification is still present as of today in 2017 and it happen to me daily specially on mobile.
@zorinochi775
@zorinochi775 6 жыл бұрын
they were not doing MVC, then they blamed MVC for their problems, then they reinvented MVC where dispatcher is just like routes file in a regular web framework and Store is something like controllers and called it FLUX. Broprogrammers approved.
@Grimscape
@Grimscape 8 жыл бұрын
Flux the hero we deserve, but not the one we need right now
@ighsight
@ighsight 3 жыл бұрын
Jing should be the only one who gets to explain things pertaining to FB. Flux, chat, data, world domination, whatever.
@every1pro
@every1pro 6 жыл бұрын
I plan to watch the video later but can anyone tell me what hacker way means or if this video is worth watching?
@SebastianGrignoli
@SebastianGrignoli 10 жыл бұрын
I'd respect Facebook engineers a lot more if they add search capabilities to the site.
@AmanGupta_Dev
@AmanGupta_Dev 8 жыл бұрын
I like the way that guy explain the blockage in day today life for building up the quality software ;) :)
9 жыл бұрын
Sounds like blocking threads right? On contrary of node.js paradigms...
@sunilkrish7961
@sunilkrish7961 6 жыл бұрын
I like this vdo very much thanx a lot for sharing this kind of vdos
@redseetpear
@redseetpear 5 жыл бұрын
Skype still have this unread message bug in 2019, I keep seeing unread massages on my phone event they are read on my PC
@jpratt8676
@jpratt8676 9 жыл бұрын
One direction.... left and right....
@FajnyAleZaNiski
@FajnyAleZaNiski 8 жыл бұрын
I don't know what she is talking about. The counter doesn't work. It shows unseen messages sometimes but they are old. Even worst is with "wall custom lists". Some of them not show new items. Another bug very annoying is "important news" on wall as default instead of latest.
@MilanJaric
@MilanJaric 8 жыл бұрын
CQRS with EventSourcing :)
@NyttNorge
@NyttNorge 7 жыл бұрын
Since when is views updating models with MVC? Seems like she doesn't know what MVC is, but she's right that MVC doesn't scale. This pattern seems awesome.
@ArisAlamanos
@ArisAlamanos 9 жыл бұрын
An excellent talk.
@tacowilco7515
@tacowilco7515 5 жыл бұрын
What she is doing does not require additional frameworks. This is just regular programming.
@iansoulful
@iansoulful 9 жыл бұрын
Cool stuff but why something new as it's already been normalized before. MVC is a meta pattern contrived of concrete patterns. The controller in MVC is a "Behavioral pattern" (command pattern, observer patterns, state pattern and the mediator pattern). The model in MVC is a combination of the "Structural patterns" and "Creational patterns" (Proxy , Adapter and the "Business Logic", "Domain Objects"). The view in MVC is a "Behavioural patterns" (Mediator, State). Modern MVC includes a Facade to further encapsulate subsets of your application. The argument in the first part of the video is misleading. Purist MVC might be slow in other languages. But MVC as a meta pattern only needs to validate the rules such as the controller takes the user input, updates the model and then the change in the model invokes the views to change their state. Also MVC was born for better application management, encapsulation. I think perhaps the presenters experience and implementation of MVC has resulted in FAILURE. I think Facebook's team did not implement MVC correctly which led them to Argue it was not scaleable.
@feelwang
@feelwang 8 жыл бұрын
A simplest system would still be server side rendered page when the network is this fast and your code is secured and there is no client side code shipped. Very neat.
@timeslowingdown
@timeslowingdown 8 жыл бұрын
k Imma refresh this entire page to post this comment
@user-ed2yh9kp7d
@user-ed2yh9kp7d 8 жыл бұрын
Leaving the responsibility of rendering to the server does not mean you need to refresh the entire page lol. intercoolerjs FTW.
@rudolfolah7773
@rudolfolah7773 3 жыл бұрын
26:00 Edsger W. Dijkstra quote, good stuff. He wrote a lot of great essays and books on Computer Science.
@AntonDanilchenko
@AntonDanilchenko 7 жыл бұрын
Amazing things are happening under the hood of Facebook. I like your approach to solve problems, fast. Well done. Keep doing well.
@ronaldschutte7948
@ronaldschutte7948 9 жыл бұрын
Now please fix the API. Document all edges properly and pleeeaaase let an app with a logged in user just get a list of that users friend. Not only for games and not only friends with same app installed. Removing that options blocks way to much possibilities.
@danieltube3144
@danieltube3144 5 жыл бұрын
But if flux solved their problems how comes that I get random message count on my event icon. Usually I get like 13 and there is only one new, then is back to one, then 5 and nothing is new. It's just a mess and when i do get a notification that somebody posted something in a group it's always too late, like 30min or even an hour. So what is that they solved?
@comlaterra
@comlaterra 10 жыл бұрын
At least I'm not alone complaining about MVC :'D
@smicksmookety
@smicksmookety 3 жыл бұрын
I still get the false message notification.
@michaelellis627
@michaelellis627 10 жыл бұрын
Attempting to integrate with Facebook at all or even simply read through documentation will have you quickly conclude that Facebook Development is hopeless.
@Charleroifa
@Charleroifa 7 жыл бұрын
audio? seriously?
@juliansoto2651
@juliansoto2651 6 жыл бұрын
18:00 "Use explicit data instead of derived data". Nice!
@dcscott100
@dcscott100 6 жыл бұрын
Here's the dirty little secret of the website developer's world: WEBSITES JUST AREN'T THAT COMPLICATED. With careful planning and a detailed eye toward structure, you can build a perfectly fine and performant (God, I hate that word) site with HTML, jQuery/Javascript, CSS, MVC and ASP.NET Web Api. It doesn't have to be spaghetti. Anyone who tells you different is either lazy or ignorant.
@korniszon68
@korniszon68 7 жыл бұрын
but... it is still the case. Unseen message count is some rubbish that quite often shows some mesasges, I already replied to, as unseen...
@lassestube
@lassestube 9 жыл бұрын
How is this different than a for. ex. well designed Angular modular application, using directives nested like react components..? I feel like I'm either really dumb for asking, or can't see any difference other than reacts speed to update the DOM..
@AlJey007
@AlJey007 9 жыл бұрын
Lasse Maerkedahl Larsen the difference is that Angular fundamentally is crap and React is ultimately simpler, more maintainable and composable, with no magical properties
@lassestube
@lassestube 9 жыл бұрын
***** i wouldn't say angular is crap but maybe its not yet fully thought out, I've followed the framework since a few years and built apps and such with it. It does work a neck of lot easier than f. Ex. JQuery and makes it easier to build something quickly with directives etc. But now people say its slow, the fellas at Google cant be that far off lile miso hervery etc and build something "crap" however i did wonder why we needed another mvc for the frontend instead of better view and data management and let the backend run from mvc architecture...
@llamasaylol
@llamasaylol 10 жыл бұрын
Google need to apply the same fix, as Facebook's chat bug, for their notification bell thing (top right of KZbin). Currently a notification pops-up, view it on one tab, counter goes away/down on that tab, but stays on any other tabs you have open.
@rajeshpednekar9317
@rajeshpednekar9317 8 жыл бұрын
Good overview of React JS and Flux
@rtorcato
@rtorcato 10 жыл бұрын
Looks like your programmers created flux because they didn't know how to properly use MVC and event dispatchers.
@juliankrispel-samsel218
@juliankrispel-samsel218 10 жыл бұрын
Right. Facebook has completely incapable developers. Sure.
@robbo_
@robbo_ 10 жыл бұрын
Julian Krispel-Samsel well actually according to this video they didn't
@juliankrispel-samsel218
@juliankrispel-samsel218 10 жыл бұрын
you don't do much sarcasm ey?
@DefnDKMC
@DefnDKMC 7 жыл бұрын
This whole comment section is a marvellous demonstration of the Dunning-Kruger effect. Seriously.
@MarkArcher1
@MarkArcher1 6 жыл бұрын
And I'm sure you also think the emperor's new clothes are great. They did MVC wrong as they have shown in their own slides. This needs to be called out otherwise people are going to be referencing this for the next 20 years as why MVC is a bad architecture when, in fact, it's one of the best and most ubiquitous architectures for UIs. This is supported by the fact that when they started from scratch to come up with a new architecture that would work exactly the way they wanted, they just reinvented MVC and that in turn fixed their problems and now they're happy.
@WesleyOverdijk
@WesleyOverdijk 10 жыл бұрын
So, "We know it sounds like the performance is bad. Because it is."? I mean, "Yeah, well, this game also uses the same slow strategy." is a bad defense in my opinion. I like the concept, I like having less to keep in my head while writing code, but performance is still a priority. I'm saying nope, hoping someone here can prove me wrong.
@super20002
@super20002 10 жыл бұрын
This is really a good thinking of how to make a large applicaion, how to build high quality application with less time? The answer is the codebase is predicable. To get there you need totally simplify and consitency the way you treat the Data Flow (Flux) and UI (React). However, some guys says this is a strict MVC, to prove it right or wrong, we sould have a try and see is it?
@sincitycyclops
@sincitycyclops 4 жыл бұрын
I still to this day get a notification on mobile for "new message (1)" and there isn't one. Just a side note, as I am trying to learn Flux
@l3p3
@l3p3 4 жыл бұрын
Is it happening on the mobile web page, in the app view or in the system notifications?
@sincitycyclops
@sincitycyclops 4 жыл бұрын
@@l3p3 app view. I often have perpetual notifications in app view for messenger and facebook. Also, clearing my notifications by marking all read on the computer, won't clear them from my mobile app. This is a Galaxy S10 Android 10
@pauljessica971
@pauljessica971 4 жыл бұрын
@@l3p3 dm andrewhack4 on Instagram he will help you on hacking and recovery of data
@CollMomo1
@CollMomo1 8 жыл бұрын
I dont get it. Basically, react is a parser ?
@DjLeonSKennedy
@DjLeonSKennedy 8 жыл бұрын
+CollMomo1 no you're idiot
@CollMomo1
@CollMomo1 8 жыл бұрын
+Юрий Яковенко big fancy words to only say that react parses html in real time.
@wyattarent156
@wyattarent156 8 жыл бұрын
+CollMomo1 HTML parsing is certainly an aspect of React. It's really more of a "templating modularizer." Jargon can seem like "big fancy words" but really has more specific implications behind it for the savvy
@Rick-ng3lr
@Rick-ng3lr 8 жыл бұрын
Nice! Very educational.
@HiteshSahu7
@HiteshSahu7 7 жыл бұрын
Users told Facebook to fix a bug in the chat feature so they come up with messenger app and forced everyone to use that.
@eramit
@eramit 3 жыл бұрын
Can somebody explain how putting all your state in one big container (if I have understood it correctly) is not undoing 40-50 years of research (as they called it) on how to abstract code? Where is data hiding? Where is encapsulation?
@MetaDevelopers
@MetaDevelopers 3 жыл бұрын
Hi, we recommend you join and post this question in the Developer Community Forum for assistance: bit.ly/2L9OBhk.
@vectorhacker-r2
@vectorhacker-r2 3 жыл бұрын
They're not using one big container and it actually follows all those principles that you've mentioned.
@FreakyLordSWatchingU
@FreakyLordSWatchingU 8 жыл бұрын
I am definitely not a pro, so I guess I was wrong about MVC. The diagram showed is weird, my models don't control my views. When I think about it, I prefer what I was doing : the controller uses models as classes : data stores and methods. The views are fed with a subset of data from models indeed, but within the scope of the controller. Even if a model method outputs exactly a view input, this method and the passing of data is in controller scope. Correct me if I'm wrong, but I have trouble understanding what problem is supposed to be fixed. Is it MVC ? Or is it MVC as they sell it ?
@WalterVertigo
@WalterVertigo 8 жыл бұрын
This is true, until javascript is in the game : you have to "react" to front-end events, that should update "state" of your datas.
@FreakyLordSWatchingU
@FreakyLordSWatchingU 8 жыл бұрын
I totally agree. Why should we dismiss object instanciation and methods though? In my current mission we use redux in production, it's ok to forward events and update state, but I faill to see how removing models and method has been beneficial to the stack. Btw, we have huge issues with not having oop namespacing in the project. Functional programming is fun and all until you have to manage a cart, a user, or a product collection...
@WalterVertigo
@WalterVertigo 8 жыл бұрын
They tried to address two issues : performance when redrawing the DOM and more readability in their code, requiring all developpers to update the state of application in the same way. I suppose that theirs controllers and models just got too messy over time. This is a very big site with probably a lot of historical and complexe code...
@FreakyLordSWatchingU
@FreakyLordSWatchingU 8 жыл бұрын
Redrawing the dom is react's prerogative. I'm talking more specifically about opposing MVC and flux pattern. Models don't get messy, they (usually) have a narrow scope and semantic clarity, iso with our daily wording. On the other end, the flux pattern is incredibly messy. Everything goes everywhere, and a never ending list of reducers sort data. It's just a global event based pub-sub. It's like the difference between C and C++. C have structures and no real syntactic "object". So every shared data is a global, and every function is in a global "scope". In C++ sharing data is explicit, functions named methods share a scope called the object. "free" functions are usually what we call "pure" in flux litterature (cf D. Abramov). But C++ tries to upgrade and fix global access to messy non namespaced data. Why ? Because it is necessary for human minds to deal with the intrinsic complexity of data-rich event-based human interfaces. Now, why would we go backward ? We replace object with scoped function (purely cosmetic difference, really). We think we can do better with only pure functions. Immutability is enforced without proper understanding of "reference" by most dev using the buzz word. I do disagree with this trend. Things are messier without proper object name spacing and semantics. Reducers are fine until they are a mess. State is great until it gets corrupted. Event based dispatching is optimal until it is the utmost incarnation of side effects. If I should sum up my opinion : Immutability/Pure/Flux is fine and all when doing the tutos, until you do a really complex application, then it becomes hell, except you write twice as much code. I will, for my next project, reuse the dispatcher standard, because it has a lot of nice features, but I will definitely go with objects and not with a state.
@WalterVertigo
@WalterVertigo 8 жыл бұрын
very interesting comment, thanks, you just know a lot more about those patterns than me ;)
@informatom
@informatom 9 жыл бұрын
Guess, what I've just seen a few minutes ago? A wrong unread messages counter ...
@AndresLobaton
@AndresLobaton 2 жыл бұрын
I absolutely like this talk
@exuperokouya5788
@exuperokouya5788 10 жыл бұрын
there is no sound on this vidéo!
@nandoflorestan
@nandoflorestan 6 жыл бұрын
Talk is from 2014; 2018 is almost here; please fix chat
@rhino1881
@rhino1881 9 жыл бұрын
sounds like the engine room of a battleship
@rafadydkiemmacha7543
@rafadydkiemmacha7543 6 жыл бұрын
Web Development is just pain in the ass nowadays. It's a battle between old technologies and new ideas. These new solutions are called "cool", while they only serve as a workarounds for old technology. If you are a programmer that loves the job, it's no fun at all.
3 жыл бұрын
just to inform devs at facebook: since from november-december 2020 the false you have message thing and incorrect notifications are back in messenger
@MetaDevelopers
@MetaDevelopers 3 жыл бұрын
Hi, we're sorry about that. Please follow the instructions at this link to report the error so we can further assist you: bit.ly/2WjAuf4
@avitshuva
@avitshuva 8 жыл бұрын
*shakes my head* Am i the only one who sees it...? Firstly, they had a logical bug in the first place: they incremented the unseen count before they even knew whether it is seen or unseen; that's a bug. You could avoid so much mess if you simply increment only when you should increment instead of incrementing and then decrementing... Secondly, you still have a bug: i often see wrote indication in the unread counter. Thirdly, you make lots of noise about very little. But that's ... how it works these days, huh.
@CollMomo1
@CollMomo1 8 жыл бұрын
fix chat... FIX CHAT.. hey.. you, yes, you HEY..... FIX CHAT
@louddude
@louddude 5 жыл бұрын
maybe it worth fixing the facebook first
@eli007s
@eli007s 9 жыл бұрын
I feel like anyone can walk into Facebook and be a "Software Engineer" after watching this.
@adondriel
@adondriel 7 жыл бұрын
They are obviously doing something wrong... just look at how slow the facebook mobile app is, and how power hungry it tends to be (at least on android it is) vs. Twitter Lite.
@apnerve
@apnerve 10 жыл бұрын
Epic comment at #41:46 :D
@juliankrispel-samsel218
@juliankrispel-samsel218 10 жыл бұрын
holy crap yes, great question. How does it compare to dog poo.
@gaastonsr
@gaastonsr 10 жыл бұрын
Total and utter cringe.
@krystalhood4468
@krystalhood4468 5 жыл бұрын
Praveen Kumar I love your videos🤩🤪😚😍😇🥰😘🤯🤑😻🤘🏻
@hiren0707
@hiren0707 5 жыл бұрын
So this is how reactjs born! it is pretty cool. I would love to know how angularjs was born. is there any video story for angularjs ?
@zoltan-nz
@zoltan-nz 5 жыл бұрын
You can learn about how Ember.js was born. Really cool documentary: kzbin.info/www/bejne/eafdXmyZmMufgbM
@webbear1000
@webbear1000 10 жыл бұрын
"Hello everybody and welcome to F8 ... /golfclap"
@ytravi
@ytravi 5 жыл бұрын
This is what you get when you hire people by writing code on whiteboard.. they are really good at cracking interview.. but they don't know how to get MVC right :D
@boot-strapper
@boot-strapper 5 жыл бұрын
and yet flux is used everywhere now
Hacker Way: Facebook's High Performance Server Infrastructure
50:06
Meta Developers
Рет қаралды 56 М.
Pete Hunt: React: Rethinking best practices -- JSConf EU
29:32
Triple kill😹
00:18
GG Animation
Рет қаралды 18 МЛН
Mia Boyka х Карен Акопян | ЧТО БЫЛО ДАЛЬШЕ?
1:21:14
Что было дальше?
Рет қаралды 9 МЛН
Facebook and memcached - Tech Talk
27:56
Meta Developers
Рет қаралды 234 М.
React.js Conf 2015 - Data fetching for React applications at Facebook
26:40
Mastering Chaos - A Netflix Guide to Microservices
53:14
InfoQ
Рет қаралды 2,3 МЛН
Microservices • Martin Fowler • GOTO 2014
26:26
GOTO Conferences
Рет қаралды 497 М.
How We've Scaled Dropbox
1:08:17
Stanford
Рет қаралды 340 М.
Lin Clark - A Cartoon Intro to Fiber - React Conf 2017
31:48
Meta Developers
Рет қаралды 202 М.
Triple kill😹
00:18
GG Animation
Рет қаралды 18 МЛН