Skip to content

Object Mapping #265

@ryantanner

Description

@ryantanner

Problem

Viaduct developers need to be able to map arbitrary types (e.g. a Thrift object) to a GraphQL type.

What are we planning to do about it?

We aim to build a generic object mapping system in Viaduct Modern that can transform data from one value domain into another, given a target type. Existing use cases include:

  • Output Type Mapping (would be supported in this project):
    • Thrift response → GRT
    • JSON response → GRT
  • Input Type Mapping (to be supported in the future):
    • GRT→ Thrift request

One specific case is JSON (unclear how JSON scalar type in GraphQL is represented in GRT, maybe Map?) → Thrift request.

The overarching goal is to provide a flexible interface that enables Viaduct architects to define default mappings between domains, while allowing tenants to specify custom field mappers for specialized field-level conversions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    roadmapTop-level roadmap initiatives

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions