softwaremill / softwaremill/tapir

Rewrite Schema derivation to use custom macros

Open
#2,110 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Scala
Stars
1.5k
Forks
468
Avg merge
5h 37m
Merged PRs (30d)
34

Description

Currently we are using Magnolia to perform schema derivation. However, this makes it impossible to verify that the validator added using an annotation matches the type of the field (see #2092).

Another area where a custom macro might be better than using Magnolia, is performance. The performance of the Scala3 version of core compilation is very poor. Maybe a custom, non-Mirror-based macro, perform better?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the existing Magnolia-based schema derivation and issue #2092, which describes the validator/type-matching problem. Then investigate Scala 3 core compilation performance and whether a custom non-Mirror-based macro is viable. Done would mean a custom derivation approach that addresses annotation validation and has evidence of improved compilation performance.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala
Domain
compilers
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.