Skip to content

DataLoader 3.x will not be upgraded in graphql-java 17.0 #98

Closed
@bbakerman

Description

@bbakerman

The latest version of java DataLoader is 3.1

The 3.x version adds a new and long desired capability - a proper ValueCache

The previous CacheMap (which come from the original Vertx port) was not a value cache at all - it was a cache of promises to values

As such it cant be serialised into a network shared cache like REDIS or Memcached say.

The 3.x code base set out fix that and did.

However we missed and important problem. Introducing an async get to the ValueCache meant that previous garuantees
that once dataloader.get(...) was called then the request has been placed into the batch queue and hence can be optimally batched.

This led to #90 - aka the dreaded "when its the right time to batch" problem

There is a PR up to fix this and it will BUT it may also introduce other problems, like premature batcing.

As such we have decided to NOT upgrade graphql-java 17.0 to DataLoader 3.x and we need to reconsider how we improve this situation

The 3.x version right now is not optimal - it will work (especially if the new ScheduledDataLoaderRegistry is used) however this approach needs revision on reflection.

Stay tuned...

Metadata

Metadata

Assignees

No one assigned

    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