50 Matching Annotations
  1. Feb 2021
    1. Arguments

      what the fuck, why a field could have a argument? arguemt就是参数。。

      type Query { tracksForHome: [Track!]! } tracksForHome 是方法名 后面的类型是返回值的类型,arguemt就是参数。。。

    2. In the example above, we see that the business logic layer requires the caller to provide a user object. If you are using GraphQL.js, the User object should be populated on the context argument or rootValue in the fourth argument of the resolver.

      总感觉和还是和我想象中的有所不同。这样来看的话 graphql 果然还是更像一个数据层的filter。

    3. In the diagram above, all entry points (REST, GraphQL, and RPC) into the system will be processed with the same validation, authorization, and error handling rules.

      在这种模型下 rest/graphql/rpc 三者是共存的?在真实的代码中,我该怎么去实现呢?

    4. While there's nothing that prevents a GraphQL service from being versioned just like any other REST API, GraphQL takes a strong opinion on avoiding versioning by providing the tools for the continuous evolution of a GraphQL schema.

      那么怎在删除东西呢?

    5. So we can access the documentation about the type system using introspection, and create documentation browsers, or rich IDE experiences.

      holy fuck,where the description from? is there just a normal field or some special keyword?

    6. We designed the type system, so we know what types are available, but if we didn't, we can ask GraphQL, by querying the __schema field, always available on the root type of a Query. Let's do so now, and ask what types are available.

      2333,meta table

    7. GraphQL cannot execute a query without a type system, let's use an example type system to illustrate executing a query. This is a part of the same type system used throughout the examples in these articles:

      草,到这里你才跟我讲这个。

    8. A fragment cannot refer to itself or create a cycle, as this could result in an unbounded result! Here's the same query above but without the explicit three levels of nesting:

      这个报错是编译时还是开发时?

    9. Like many type systems, GraphQL supports interfaces. An Interface is an abstract type that includes a certain set of fields that a type must include to implement the interface.

      类型体操,类型体操

    10. For example, you could specify that the Date type should always be serialized into an integer timestamp, and your client should know to expect that format for any date fields.

      what the fuck of that mean?

    11. That means that the GraphQL service needs to have a Query type with hero and droid fields:

      这种类型 制约了 用户真正能够在客户端与之交互的能力?

    12. In this query, the hero field returns the type Character, which might be either a Human or a Droid depending on the episode argument. In the direct selection, you can only ask for fields that exist on the Character interface, such as name.To ask for a field on the concrete type, you need to use an inline fragment with a type condition. Because the first fragment is labeled as ... on Droid, the primaryFunction field will only be executed if the Character returned from hero is of the Droid type. Similarly for the height field for the Human type.

      没看懂

    13. While query fields are executed in parallel, mutation fields run in series, one after the other.

      CQRS

    14. createReview

      这个东西 本质上只是一个查询?

    15. 有vue/angular 那味了

    16. query, mutation, or subscription

      与restful类似的,graphql 提供的原语是 查/改/听 很明显更好了

    17. Using variables inside fragments#

      不喜欢这种类似闭包的东西。

  2. Jan 2021
  3. Dec 2020
    1. injects the Docker binary in the image

      third

    2. that /var/lib/docker should be a volume

      second

    3. it installs a few packages: lxc and iptables (because Docker needs them), and ca-certificates

      first

    1. 感觉还是不够in depth,打破所有的抽象直到机器码才叫in depth

    2. Proxies ♥ WeakMaps. In our readOnlyView example, we create a new proxy every time an object is accessed. It could save a lot of memory to cache every proxy we create in a WeakMap, so that however many times an object is passed to readOnlyView, only a single proxy is created for it. This is one of the motivating use cases for WeakMap.

      有些不是很明确

    3. An Object is a collection of properties

      我有些不知道我在想什么,但某种分布式的编程语言?TiDB的底层是KV,mongo的底层也是KV

    1. individuals believe the diagnosis is somehow mistaken, and cling to a false, preferable reality.

      and cling to a false, preferable reality. cling 坚持 false, preferable 虚假的更好的现实 逗号在这里是false和preferable的并列

    1. Bert Hubert, the founder of PowerDNS and author of RFC 5452, shares his views on forces influencing DNS protocol development.

      forces 不是我熟悉的武力获取 那种偏向动词的意思 而是代表"力"这个概念. forces influencing DNS protocol development 影响DNS协议开发的因素。

    1. That's all! We have the stack and BSS, so we can jump to the main() C function

      一头雾水 总的来讲.是为了初始化C语言运行环境设置的一坨东西

    2. it calls the 0x10 interrupt

      who?

    3. But it only has 16-bit registers, which have a maximum address of 2^16 - 1 or 0xffff (64 kilobytes). Memory segmentation is used to make use of all the address space available. All memory is divided into small, fixed-size segments of 65536 bytes (64 KB). Since we cannot address memory above 64 KB with 16-bit registers, an alternate method was devised. An address consists of two parts: a segment selector, which has a base address; and an offset from this base address. In real mode, the associated base address of a segment selector is Segment Selector * 16. Thus, to get a physical address in memory, we need to multiply the segment selector part by 16 and add the offset to it: PhysicalAddress = Segment Selector * 16 + Offset For example, if CS:IP is 0x2000:0x0010, then the corresponding physical address will be: >>> hex((0x2000 << 4) + 0x0010) '0x20010' But, if we take the largest segment selector and offset, 0xffff:0xffff, then the resulting address will be: >>> hex((0xffff << 4) + 0xffff) '0x10ffef' which is 65520 bytes past the first megabyte. Since only one megabyte is accessible in real mode, 0x10ffef becomes 0x00ffef with the A20 line disabled.

      虽然8086 CPU总线宽度是20bit(能够索引1MB空间)但是寄存器宽度只有16bit 因此发明出了一种解决方法就是 使用两个寄存器组合起来索引,计算的规则是 PhysicalAddress = Segment Selector * 16 + Offset

      x86处理器中的CS与IP寄存器

    1. Real mode is characterized by a 20-bit segmented memory address space (giving exactly 1 MiB of addressable memory) and unlimited direct software access to all addressable memory, I/O addresses and peripheral hardware