Kenneth Knowles created BEAM-1786:
-------------------------------------

             Summary: AutoService registration of coders, like we do with 
PipelineRunners
                 Key: BEAM-1786
                 URL: https://issues.apache.org/jira/browse/BEAM-1786
             Project: Beam
          Issue Type: Improvement
          Components: sdk-java-core
            Reporter: Kenneth Knowles


Today, registering coders for auxiliary data types for a library transform is 
not very convenient. It the appears in an output/covariant position then it 
might be possible to use {{getDefaultOutputCoder}} to solve things. But for 
writes/contravariant positions this is not applicable and the library transform 
must contort itself to avoid requiring the user to come up with a coder for a 
type they don't own.

Probably the best case today is an explicit call to 
{{LibraryTransform.registerCoders(Pipeline)}} which is far too manual.

This could likely be solved quite easily with {{@AutoService}} and a static 
global coder registry, as we do with pipeline runners.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to