grpc / grpc/grpc-java

Consider adding @Nullable / @Nonnull annotations to generated services

Offen
#4,724 17 Kommentare 9 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
Java
Sterne
12.1k
Forks
4k
Ø Merge
2 T. 17 Std.
Gemergte PRs (30 T.)
37

Beschreibung

Please answer these questions before submitting your issue.

### What version of gRPC are you using?

1.13.2

### What did you expect to see?

It would be very helpful for those of us implementing *ImplBase classes in Kotlin if the parameters of generated `rpc` methods were annotated with `@javax.annotation.Nonnull` as it gives tooling a hint that the signature of an `override` should use the non-nullable form of the parameter types.

Minor, but would make implementing services in Kotlin that bit more seamless.

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Start by locating the code-generation entry point for generated rpc methods and the ImplBase service classes; the issue does not name specific files or tests. Review the existing 1.13.2 generation and the discussion before deciding how @javax.annotation.Nonnull or @Nullable should be applied, then verify that generated Kotlin overrides receive the intended nullability information.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
java, kotlin
Bereich
api
Issue-Typ
Feature
Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Aktivitätsstatus
Aktiv
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
48/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.