47 Matching Annotations
  1. Sep 2021
    1. This is what I call a leaky abstraction. TCP attempts to provide a complete abstraction of an underlying unreliable network, but sometimes, the network leaks through the abstraction and you feel the things that the abstraction can’t quite protect you from. This is but one example of what I’ve dubbed the Law of Leaky Abstractions:
  2. Jul 2021
  3. datatracker.ietf.org datatracker.ietf.org
    1. The WebSocket Protocol is designed on the principle that there should be minimal framing (the only framing that exists is to make the protocol frame-based instead of stream-based and to support a distinction between Unicode text and binary frames). It is expected that metadata would be layered on top of WebSocket by the application Fette & Melnikov Standards Track [Page 9] RFC 6455 The WebSocket Protocol December 2011 layer, in the same way that metadata is layered on top of TCP by the application layer (e.g., HTTP). Conceptually, WebSocket is really just a layer on top of TCP that does the following: o adds a web origin-based security model for browsers o adds an addressing and protocol naming mechanism to support multiple services on one port and multiple host names on one IP address o layers a framing mechanism on top of TCP to get back to the IP packet mechanism that TCP is built on, but without length limits o includes an additional closing handshake in-band that is designed to work in the presence of proxies and other intermediaries Other than that, WebSocket adds nothing. Basically it is intended to be as close to just exposing raw TCP to script as possible given the constraints of the Web. It's also designed in such a way that its servers can share a port with HTTP servers, by having its handshake be a valid HTTP Upgrade request. One could conceptually use other protocols to establish client-server messaging, but the intent of WebSockets is to provide a relatively simple protocol that can coexist with HTTP and deployed HTTP infrastructure (such as proxies) and that is as close to TCP as is safe for use with such infrastructure given security considerations, with targeted additions to simplify usage and keep simple things simple (such as the addition of message semantics).
  4. Jun 2021
    1. When we use a GraphQL API there are two kinds of errors we may encounter: Network Errors and GraphQL Errors from the API. Since it's common to encounter either of them, there's a CombinedError class that can hold and abstract either.
    1. The Internet, an immeasurably powerful computing system, is subsuming most of our other intellectual technologies. It’s becoming our map and our clock, our printing press and our typewriter, our calculator and our telephone, and our radio and TV.

      An example of technological progress subsuming broader things and abstracting them into something larger.

      Most good mathematical and physical theories exhibit this sort of behaviour. Cross reference Simon Singh's The Big Bang.

  5. May 2021
    1. Components are the core of MJML. A component is an abstraction of a more complex email-responsive HTML layout. It exposes attributes, enabling you to interact with the final component visual aspect.
    2. MJML has been designed with responsiveness in mind. The abstraction it offers guarantee you to always be up-to-date with the industry practices and responsive. Email clients update their specs and requirements regularly, but we geek about that stuff - we’ll stay on top of it so you can spend less time reading up on latest email client updates and more time designing beautiful email.
  6. Mar 2021
    1. I’m proposing that writing those tests from the perspective of specifying the behaviors that we want to create is a highly valuable way of writing tests because it drives us to think at the right level of abstraction for creating behavioral tests and that allow us the freedom to refactor our code without breaking it
    2. I am a big advocate of having a complete test base and even erring on the side of caution when it comes to quality engineering and software validation but that is not what we’re talking about here. What we’re talking about here are the tests that we write when we’re doing test-first development and I’m proposing that writing those tests from the perspective of specifying the behaviors that we want to create is a highly valuable way of writing tests because it drives us to think at the right level of abstraction for creating behavioral tests and that allow us the freedom to refactor our code without breaking it.
    1. Having an understanding of higher level abstractions, such as tasks, activities and the historical code path taken, its debugging trace is much closer to how you, as an engineer, think about your code.
  7. Feb 2021
    1. Please note that this is a higher-level debugging tool that does not confront you with a 200-lines stack trace the way Ruby does it, but pinpoints the exceptional code and locates the problem on a task level. This is possible due to you structuring code into higher abstractions, tasks and activities.
    1. While you could nest an activity into another manually, the Subprocess macro will come in handy.
    2. The Track() function will snap the output to the next task that is “magnetic to” the track’s semantic.
    1. While you could program this little piece of logic and flow yourself using a bunch of Ruby methods along with a considerable amount of ifs and elses, and maybe elsif, if you’re feeling fancy, a Trailblazer activity provides you a simple API for creating such flow without having to write and maintain any control code. It is an abstraction.
    1. The adapter is where authentication, policy checks, and eventually your domain logic happen. All termini of the protocol’s activity are standardized end events - that’s how protocol and adapter communicate.
    2. An endpoint links your routing with your business code. The idea is that your controllers are pure HTTP routers, calling the respective endpoint for each action. From there, the endpoint takes over, handles authentication, policies, executing the domain code, interpreting the result, and providing hooks to render a response.
    1. Trailblazer extends the conventional MVC stack in Rails. Keep in mind that adding layers doesn't necessarily mean adding more code and complexity. The opposite is the case: Controller, view and model become lean endpoints for HTTP, rendering and persistence. Redundant code gets eliminated by putting very little application code into the right layer.
    2. Trailblazer is no "complex web of objects and indirection". It solves many problems that have been around for years with a cleanly layered architecture.
  8. Dec 2020
    1. Svelte components are a thin layer over the DOM and naturally expose the web platform. Coding in Svelte feels like I’m moving with the grain of the web.
  9. Nov 2020
    1. Do we need such a big abstraction for this? Many would just use fetch directly. Why not just use fetch directly? In Svelte, for example, you would probably never see something like this ... right?

  10. Oct 2020
    1. Declarative programming is an enabler of abstraction. Imperative programming is an inhibitor of abstraction. Declarative programming allows you to say “I want this and I don’t care how I get it” while imperative programming requires you to define each and every step.

      Declarative programming, i.e. "build me a house, I don't care how", is an enabler of abstraction.

      Imperative programming, i.e. "build walls, windows, a roof.", is an inhibitor of abstraction.

    1. virtual-dom exposes a set of objects designed for representing DOM nodes. A "Document Object Model Model" might seem like a strange term, but it is exactly that. It's a native JavaScript tree structure that represents a native DOM node tree.
    1. Alfred Korzybski remarked that "the map is not the territory" and that "the word is not the thing", encapsulating his view that an abstraction derived from something, or a reaction to it, is not the thing itself.
    2. The map–territory relation describes the relationship between an object and a representation of that object, as in the relation between a geographical territory and a map of it.
  11. Sep 2020
    1. Now of course we know how React handles this conflict: it takes the new nodes in your virtual DOM tree — the waters in your flowing river — and maps them onto existing nodes in the DOM. In other words React is a functional abstraction over a decidedly non-functional substrate.

      To me this is a warning sign, because in my experience, the bigger the gap between an abstraction and the thing it abstracts, the more likely you are to suffer what programmers like to call ‘impedance mismatches’, and I think we do experience that in React.

  12. Nov 2019
  13. Oct 2019
  14. Aug 2019
    1. As Sebastian Markbage pointed out, no abstraction is superior to wrong abstractions. We are providing low-level components to maximize composition capabilities.
  15. Jan 2019
  16. Jan 2017
    1. It is far better to grasp the universe as it really is than to persist in delusion, however satisfying and reassuring.

      I would amend this to say that we never grasp the universe as it really is, but that some of our delusions are startlingly accurate (by design).

  17. Jun 2016
    1. Civilization advances by extending the number of important operations we can perform without thinking about them.

      This sounds really similar to the concept of "abstraction".

    Tags

    Annotators

  18. Feb 2015
    1. Week 3 (Jan 27) - Tasks - Ch 3 Discuss the strengths and limitations of vis tools that are for a specific purpose and those that are general. Distinguish among the three levels of actions in the task abstraction framework. Given a visualization, identify the actions the vis allows and the targets of those actions. Transform domain-specific tasks into the task abstraction framework.

      Important chapter for why a vis tool is being used.

  19. Feb 2014
    1. The hard part is teaching the consequences of each choice.

      Once you get the syntax and basic language idioms out of the way this is the real problem that faces us no matter what language we pick.

  20. Nov 2013