SpineEventEngine / mc-java

Model Compiler for Java
Apache License 2.0
0 stars 2 forks source link

Use custom annotation types #128

Closed alexander-yevsyukov closed 9 months ago

alexander-yevsyukov commented 9 months ago

This PR extends ProtoData-based annotator with the ability to use custom annotation types.

McJavaOptions type was reworked to expose settings related to annotation as a property of the newly introducedAnnotationSettings type. Correspondingly, spine.mc.annotation.java.Settings Protobuf type was introduced for passing the settings to ApiAnnotationsPlugin.

Integration tests were updated to expose custom annotation types as a submodule so that they can be passed to ProtoData classpath.

Restriction on API levels used for Protobuf services

The only service option we have is SPI_service. We do not have other API level options for services. So far the usage experience have not shown that we need other options for services:

Previously we could have a service annotated with @Beta, @Internal, or @Experimental when it was declared in a file with <Level>_all file option (e.g. internal_all). Now we do not support such behaviour, and integration tests were adjusted accordingly.