Skip to content

Add a way to record isolated operations #48

Description

@wschurman

While debugging, it would be useful to be able to get information about entity loads/mutations/etc to see things like:

  • If it hit the DB, what was the query run
  • If it hit or wrote to the cache, what were the cache keys used
  • If it only went to the dataloader, indicate as such
  • etc...

An API for this could look something like:

const [queryContextAuditResult, entityResultFromInnerBlock] = await withIsolatedQueryContext(async (queryContext) => {
  return await BlahEntity.loader(viewerContext, queryContext).load(...);
});
console.log(queryContextAuditResult);

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions