Skip to content
This repository was archived by the owner on Dec 27, 2021. It is now read-only.
This repository was archived by the owner on Dec 27, 2021. It is now read-only.

Make ProtosRegistry a class instead of singleton #165

Open
@zenyui

Description

@zenyui

Is your feature request related to a problem? Please describe.
ProtoRegistry is a little hard to test/deal with as a singleton. We tried making it a class, but the ApiSerializer fails with the error:

Can't generate a Lagom client for io.superflat.lagompb.data.TestService since the following abstract methods don't return service calls or topics: protosRegistry

Describe the solution you'd like
somehow convert ProtoRegistry to a class with a companion to instantiate with reflection (easier to test, mock, pass around), but in a way that does not require doing a new reflection of proto classes for each serialized response.

Describe alternatives you've considered
leaving it as it is...

Additional context
n/a

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions