- mix deps.get
- iex -S mix phx.server
- Open GraphiQL Workspace at http://localhost:4000/graphiql
- Run query:
query customersQuery { customers { ... on CustomerAccount { id name } ... on CustomerContact { id firstName lastName phoneNumbers { id label number } } } }
- The response size here is 19770 bytes. And in the console I have: [info] Memory At Resolver Start: 68064 [info] Memory Before Absinthe Send: 973408
- So it seems like to generate this response it uses 45x the memory required for the formatted data.
- Open http://localhost:4000.
- The response size here is 9800 bytes. And in the console I have: [info] Memory At Action Start: 21624 [info] Memory Before Plug Send: 142784
- So it seems here to generate the response it uses 12x the memory required for the formatted data.