This module handles all
transforms from api objects into singer objects.
Arch
By design this module is:
- Independent of the api module.
- Agnostic of the etl state objects.
Exports
SingerStreams: The names of the singer streams that are generated by this module.ObjEncoder: The main interface from which the transform is defined.ObjsEncoders: Namespace where all supported ObjEncoder are found.
- Extend
SingerStreams for the new obj encoder. - Create a private module within this module.
- In the private module: implement an
ObjEncoder[_T] for the new specific object (_T) using the new SingerStreams item. - Expose the new encoder in
ObjsEncoders.
When to extend this module streams/encoders?
There is only one SingerStreams item per object schema, if two streams share the same schema they are equivalent and so are their encoders. This also implies that objects _T and _R would be equivalent, but if this is not the case its better to reuse the equivalent encoder and then override the stream by another SingerStreams item.
Learn more
- Observes
- Tap Json
Tip
Have an idea to simplify our architecture or noticed docs that could use some love? Don't hesitate to
open an issue or submit improvements.