Commit Graph

10 Commits

Author SHA1 Message Date
Eric Anderson 935f8f0afc servlet: Move deps to version catalog
This allows the checkForUpdates task to notice the dependencies and
suggest updates.

I plan to upgrade some of the servers after this change in hopes it
reduces test flakiness.
2024-02-27 21:48:19 -08:00
Eric Anderson 0299788807 util: Make grpc-core an implementation dependency
This prevents grpc-core from being exposed on the classpath when
compiling code using grpc-util.
2023-11-13 16:52:42 -08:00
Eric Anderson 3eb5d20f6c servlet: Avoid lincheck for normal testing
It is slow, and just tries a bunch of possibilities. Leave it around for
developers to run locally, but it isn't precise enough to run on every
build. This change reduces the build of servlet in isolation by
1 minute. I suspect the gains are larger in a full grpc build because it
is very CPU-intensive; it uses 600% CPU on my 8-thread CPU when running
by itself.
2023-09-13 10:49:37 -07:00
Eric Anderson b13a656f46
servlet: Support configuration avoidance in build
Instead of adding explicit dependsOn to compileJava and sourcesJar,
adding the sync task to the sourceSet automatically propagates the
dependency to all consumers of the code.
2023-08-17 10:19:20 -07:00
Eric Anderson f3f4ed4ef3 Upgrade to Gradle 8.2.1 and upgrade plugins
Most changes are migrating from conventions to the equivalent
extensions. JMH, AppEngine, and Jib plugins trigger future compatibility
warnings with `--warning-mode all`.

The movement of configurations was to allow sourceSets to create the
configurations and then we just configure them. When configurations were
before sourceSets, we'd implicitly create the configuration.

The examples were _not_ updated to the newer Gradle, although the
non-Android examples work with the newer Gradle. The Android examples
use an older Android Gradle Plugin which will need to be upgraded first.
https://github.com/grpc/grpc-java/issues/10445
2023-08-02 13:29:44 -07:00
Eric Anderson 1dee7efca4 Avoid accidental Java 9+ dependency with --release
In d654707 we swapped compiling the uploaded artifacts to Java 11. This
caused ABI issues with ByteBuffer, like clear() returning ByteBuffer
instead of Buffer.

There are source-level approaches to avoid the accidental ABI dependency
on Java 11, but we have no tool able to detect such breakages.
We use Animalsniffer for similar cases, but it fails to detect these[1].
Since we have no tool, source-level approaches can't gain the necessary
confidence that all incompatibility fixes have been resolved.

Java has had javac-level ways to address this, but they used to require
setting bootclasspath. Since Java 9, though, they made it easier and we
can use --release, which does exactly what we need.

Fixes #10432

1. https://github.com/mojohaus/animal-sniffer/issues/77
2023-07-31 17:51:49 -07:00
sanjaypujare 41552bfd9a
all: generate automatic module name in the manifest (#10413) 2023-07-25 09:00:11 -07:00
Eric Anderson 3f60746a98
servlet: Remove unused dependency on grpc-util in tests
Also convert to testFixtures, like we did elsewhere.

grpc-testing had previously been listed, but because of the missing
comma, it was not an actual dependency.
2023-07-20 07:57:11 -07:00
sanjaypujare 0f5f07f876
core, inprocess, util: move inprocess and util code into their own new artifacts grpc-inprocess and grpc-util (#10362)
* core, inprocess, util: move inprocess and util code into their own new artifacts grpc-inprocess and grpc-util
2023-07-17 11:45:31 -07:00
Colin Alworth 706646f8bb
servlet: Implement gRPC server as a Servlet (#8596)
Full end to end implementation of gRPC server as a Servlet including tests and examples

Co-authored-by: Penn (Dapeng) Zhang <zdapeng@google.com>
Co-authored-by: Chengyuan Zhang <chengyuanzhang@google.com>
2023-01-20 13:17:58 -08:00