Commit Graph

6141 Commits

Author SHA1 Message Date
Eric Anderson 0f2c43a8fd Download Maven from Maven Central
Maven deleted older binaries from their CDN, so the download was
failing. Maven Central seems it'll be more stable.
2023-06-09 10:32:12 -07:00
Daniel Liu 1daf0ff720
services, xds, orca: use application_utilization and fallback to cpu_utilization if unset in WRR (#10256)
Implements updates to [A51][] and [A58][].

Imported cncf/xds using import.sh script.

A51: https://github.com/grpc/proposal/pull/374
A58: https://github.com/grpc/proposal/pull/373
2023-06-08 16:03:50 -07:00
Eric Anderson 33a402d924 Avoid NettyServerBuilder when unnecessary
These code locations just needed a generic gRPC server, without any
transport-specific configuration. Use vanilla ManagedServerBuilder
instead of hard-coding to Netty, as we would suggest to our users.
2023-06-05 17:11:16 -07:00
Larry Safran 217103cd5e
Flip default for RLS on XDS being enabled to true. (#10248) 2023-06-05 15:49:30 -07:00
sanjaypujare 6949b8790a
api: stabilize ManagedChannelBuilder.useTransportSecurity (#10244)
* api: stabilize ManagedChannelBuilder.useTransportSecurity and add a note in Java doc
2023-06-02 15:08:25 -07:00
sanjaypujare 639fd8edf2
xds: remove env var for security enable/disable (#10243) 2023-06-02 09:24:51 -07:00
Xuan Wang 02ac6f4393
buildscripts, psm interop: Don't fail target if sub-target already failed
We configured TestGrid to file bug separately for each 
failed sub-target, if we still fail the main target, 
TestGrid will fail duplicate bugs.

The same change in core: 
https://github.com/grpc/grpc/pull/33222.
2023-05-31 17:37:46 -07:00
Sergii Tkachenko 17b2df78ec
Start 1.57.0 development cycle (#10229) 2023-05-30 18:02:40 -07:00
kotlaja e6d9b41895
bazel: Add java toolchain type to all rules which are using java_common (#10225) 2023-05-30 11:48:43 -07:00
Stanley Cheung 4277867a7d
gcp observability: Update Docker images to eclipse-temurin (#10218)
Perform software update so that we install patches for latest
vulnerabilities. Similar to the fix in #10191
2023-05-30 08:03:36 -07:00
Larry Safran df85a45742
Add a java specific description of manual flow control to the example. (#10223)
* Add a java specific description of manual flow control to the example.
2023-05-26 18:36:40 -07:00
Daniel Liu 5a27e3ead2
services, xds, orca: support EPS in client-side WRR (#10177) 2023-05-26 12:52:42 -07:00
Michael Vorburger ⛑️ 6aa72b786d
docs: Document use with Bazel, like Maven & Gradle (fixes #10215) (#10217)
* docs: Document use with Bazel, like Maven & Gradle (fixes #10215)
2023-05-26 12:42:50 -07:00
apolcyn b77f0a022f
interop-testing: introduce --additional_metadata flag to let client optionally send extra metadata (#10201)
The flag was documented in https://github.com/grpc/grpc/pull/33180 .
This flag will be useful for some RLS integration tests where we need
to have the client set certain headers for routing purposes.
2023-05-26 06:45:50 -07:00
Eric Anderson f75c7c72f2 repositories.bzl: In doc, use | to combine dicts
The previous syntax for just adding your own keys doesn't seem to work,
but was similar to the approach of using `dict(d, foo=bar)`. You can't
have '.' and ':' in a key that way though. The doc was written before
Bazel 1.0 and in newer Bazel versions you can just use | to concatenate.

Fixes #10203
2023-05-25 15:26:43 -07:00
Eric Anderson 7217baa777 Remove old Java 7/8 TLS testing workarounds
Ciphers have been "fast enough" for testing since early Java 8 updates;
we haven't needed to override ciphers since we dropped Java 7 support.
Java 8u252 had ALPN, so Conscrypt or Jetty ALPN hasn't been necessary
for basic testing for a while. We still want specialized testing for
Conscrypt, but only tests testing Conscrypt need to care.
2023-05-25 14:04:01 -07:00
Eric Anderson cb42405217 testing: Move some internal classes to testFixtures
These two classes are precisely the purpose of test fixtures. Move them
close to the classes they make easier to use in tests.
2023-05-25 14:03:42 -07:00
sanjaypujare 3b2cba09c1
api: remove experimentalApi setting from proxyDetector and related classes (#10216) 2023-05-25 13:46:24 -07:00
sanjaypujare e875d1b01c
xds: remove remaining occurences of SDS in the security code (#10219) 2023-05-25 10:28:37 -07:00
Terry Wilson e172ea7efc
api: Experimental CallCredentials.thisUsesUnstableApi() (#10211)
The thisUsesUnstableApi() method was earlier deprecated and the
@ExperimentalApi annotation removed. Adding @ExperimentalApi back
to make it clear that this method can (and will) later be removed.
2023-05-23 08:32:33 -07:00
Terry Wilson dd2dc21de2
api: Stabilize io.grpc.CallCredentials (#10208) 2023-05-22 09:59:53 -07:00
Liam Miller-Cushon 478f30e645 testing-proto: Define supported SourceVersion in annotation test
This fixes the warning during the test run:
```
warning: No SupportedSourceVersion annotation found on io.grpc.testing.protobuf.SimpleServiceTest$AnnotationProcessor, returning RELEASE_6.
warning: Supported source version 'RELEASE_6' from annotation processor 'io.grpc.testing.protobuf.SimpleServiceTest$AnnotationProcessor' less than -source '1.8'
```
2023-05-18 11:01:39 -07:00
Kun Zhang 6fd93486cc
test: stop mocking Executor. (#10199)
It is forbidden internally. Error message:

Mocking types which have complex contracts or are easy to construct by
other means is forbidden:

'executor' is mocking 'interface java.util.concurrent.Executor'. Use a
real executor. Mocks of Executor don't execute submitted tasks at all,
which leads to suppressed errors, deadlocks, and brittle tests..
2023-05-17 16:40:32 -07:00
Terry Wilson 5d40396aa2
A note to include backports in release notes (#10198) 2023-05-17 11:36:01 -07:00
Terry Wilson 810d8cab09
xds: pick_first LB configuration (#10181)
Configure pick_first load balancing if the xDS PickFirst LB config
message is used in the Cluster load balancing config.
2023-05-17 10:19:29 -07:00
Eric Anderson e0ac97c4fd
Upgrade dependencies (#10178)
Required bumping android compile/targetSdkVersion to 33
2023-05-17 08:32:49 -07:00
Eric Anderson e38d928f75 examples: Fix hostname binary name in README
The command has been wrong since it was introduced. The hostname-server
comes from the applicationName, which hasn't changed.
2023-05-16 15:44:09 -07:00
Sergii Tkachenko 16b84924a1
xds interop: Update Docker images to `eclipse-temurin:11-jre` (#10172)
- Update to xDS Test Client and xDS test server Docker images to `eclipse-temurin:11-jre`. 
- Perform software update so that we install patches for latest vulnerabilities.
2023-05-16 15:20:55 -07:00
Eric Anderson 29b8483fd6
Use test fixtures instead of sourceSets.test.output
This avoids the (often missing) evaluationDependsOn and fixes using
results from other projects without propagating those through
Configuration. It also reduces the number of useless classes pulled in
by down-stream tests, reducing the probability of rebuilds.

The expectation of fixtures is they help testing down-stream code that
use the classes in main. That applies to all the classes here except for
FakeClock and StaticTestingClassLoader. It would also apply to many
internal classes in grpc-testing, but let's consider cleaning that up
future work.
2023-05-16 12:10:13 -07:00
Eric Anderson cd7b81c6d2 gradle: Assocate an artifact to every version
This allows the checkForUpdates task to look for newer versions.
2023-05-15 14:01:41 -07:00
Eric Anderson 2cc24a9bda gradle: Remove version pinning from POMs
The pinning is unreliable in Maven and ignored by Gradle. I'm not at all
convinced that we are pinning/not pinning in appropriate projects. The
pinning also serves less of a purpose since we started encouraging the
BOM and grpc-netty-shaded. Netty's HTTP/2 API has also become somewhat
stable compared to its earlier history. If we notice an up-tick in
version skew, we can reinstate it.

The pinning is annoying in the build.gradle code and causes Maven/Gradle
to download the version list once a day, which can be troublesome to
users unaware of how to tell the tools to work offline.

It also opens our users to platform issues like seen in #10043
and #10086 where Maven Central's version list was incorrectly generated.
Or like #9664 where Gradle Plugin's repository caches packages from
JCenter but the version list is not as cachable so exposed us to JCenter
instability.

This fixes #8357, by way of "we think we won't worry any more." See
90db93b9 when it was originally introduced. And issues
like #8337, #3634.
2023-05-15 13:08:40 -07:00
Terry Wilson 793fde840a
xds: Import latest Envoy protos (#10167) 2023-05-11 09:44:43 -07:00
Eric Anderson c16972c54a build.gradle: Add checkForUpdates task 2023-05-10 12:44:35 -07:00
Eric Anderson 3f0e90d54e build.gradle: Use proto task output instead of hard-coding path
This removes the need to specify dependsOn explicitly, because the task
input carries the dependency.
2023-05-10 12:44:10 -07:00
Daniel Liu 6e486cba48
import cncf/xds using import.sh script (#10160) 2023-05-10 12:42:26 -07:00
Eric Anderson 02a4cb5c69 Fix throwing LBProvider.parseLoadBalancingConfig() impls
LoadBalancers in general should never throw, but
parseLoadBalancingConfig() in particular has a return value to
communicate the error. Throwing can be a bit unpredictable, but at its
most trivial form causes a channel panic. There's no reason to throw
explicitly and calls to JsonUtil have to be protected by a try-catch
because it can throw.
2023-05-10 12:42:05 -07:00
yifeizhuang 6f804331f7
xds: remove _experimental in wrr policy name (#10162) 2023-05-10 11:02:13 -07:00
Eric Anderson 74b515ecf7 Migrate many usages of TestUtils.loadCert() to the public TlsTesting
TlsTesting.loadCert() is a public API and so should be preferred over
our internal utility. It avoids creating a temp file that has to be
deleted by a shutdown hook. Usages that needed a file were not migrated.
2023-05-09 17:01:31 -07:00
Eric Anderson f229aed538 core: Hide RR's ReadyPicker and EmptyPicker
ReadyPicker hasn't been necessary since 111ff60e, when we stopped
calling super.pickSubchannel(). EmptyPicker was only used in tests, and
we can just compare the class name instead of doing an instanceof check.

Unfortunately, calling getClass() caused Java to start casting the
return value of pickerCaptor.getValue() based on its generics. Captors
don't verify the type they capture, so using any type other than
SubchannelPicker for the pickerCaptor is misleading and hides a cast.
2023-05-09 13:25:19 -07:00
Terry Wilson 86f7bca5f9
api: Fix boundary check in Status.fromCodeValue() (#10155) 2023-05-09 09:02:56 -07:00
Eric Anderson b4f4142e8d RELEASING.md: Include version number in release branch name
This makes it easier to manage multiple patch releases in-flight
simultaneously and improves the default PR description.
2023-05-09 08:12:27 -07:00
Eric Anderson 847ea7cfc9 Upgrade Mockito to 3.12.4
MockitoAnnotations.initMocks() is deprecated.
2023-05-08 16:39:42 -07:00
Eric Anderson 8dbc88f3a3
gradle: Improve compatibility with Gradle 8 2023-05-08 10:46:10 -07:00
Eric Anderson f458f229c6
gradle: Update plugins 2023-05-08 10:45:13 -07:00
Eric Anderson 29c2de0d42 okhttp: Fix signed-byte comparison 2023-05-08 10:43:49 -07:00
Eric Anderson 424ddcee8d compiler: configureEach instead of each+configure
each+configure serves no purpose, because the task has already been
realized with the each. This was just a faulty conversion in 0ff9f37b9e,
although it was because I thought the each was specialized API from the
protobuf plugin, not the normal container each.
2023-05-08 10:37:57 -07:00
Eric Anderson 180b3e9092 xds: Avoid default locale and reset()
Found via linter
2023-05-05 15:23:18 -07:00
Eric Anderson 22366891de
binder: Use Channel-based blockingUnaryCall()
The Channel-based overload can change the CallOptions to use
ThreadlessExecutor, so avoids using extra threads.
2023-05-05 15:22:54 -07:00
Terry Wilson 0005029328
android,binder,cronet: .aar file when publishing (#10138) 2023-05-05 15:21:26 -07:00
Eric Anderson 94dec7c020 xds: Avoid WRR config synchronization 2023-05-05 14:43:26 -07:00