Commit Graph

306 Commits

Author SHA1 Message Date
panxuefeng f40231e147
buildscripts: Enhancement for LoongArch64 (#9778) 2023-01-04 09:11:23 -08:00
Larry Safran ccb5d945c0
Start 1.53.0 development cycle (#9757) 2022-12-14 18:07:57 -08:00
Sergii Tkachenko eb1e5a11c6 Start 1.52.0 development cycle 2022-11-07 11:56:25 -08:00
Eric Anderson 5b62d22802 Start 1.51.0 development cycle 2022-09-26 16:37:56 -07:00
Terry Wilson 01aff58178
Start 1.50.0 development cycle (#9433) 2022-08-10 08:17:59 -07:00
Eric Anderson 0ff9f37b9e Use Gradle's task configuration avoidance APIs
This can avoid creating an additional 736 tasks (previously 502 out of
1591 were not created). That's not all that important as the build time
is essentially the same, but this lets us see the poor behavior of the
protobuf plugin in our own project and increase our understanding of how
to avoid task creation when developing the plugin. Of the tasks still
being created, protobuf is the highest contributor with 165 tasks,
followed by maven-publish with 76 and appengine with 53. The remaining
59 are from our own build, but indirectly caused by maven-publish.
2022-07-08 12:16:40 -07:00
yifeizhuang 377e3ce557
Start 1.49.0 development cycle (#9322) 2022-06-29 11:00:27 -07:00
Wenlong Zhang 334fc32034 Adding loongarch suport for grpc-java 2022-06-24 07:11:47 -07:00
sumitd2 04f9bdc1fd
compiler: Cross-compile for ppc64le platform (#9284)
Fixes #9274
2022-06-23 09:18:19 -07:00
Eric Anderson b06942d63b Use Gradle's version catalog
This moves our depedencies into a plain file that can be read and
updated by tooling. While the current tooling is not particularly better
than just using gradle-versions-plugin, it should put us on better
footing. gradle-versions-plugin is actually pretty nice, but will be
incompatible with Gradle 8, so we need to wait a bit to see what the
future holds.

Left libraries as an alias for libs to reduce the commit size and make
it easier to revert if we don't end up liking this approach.

We're using Gradle 7.3.3 where it was an incubating fetaure. But in
Gradle 7.4 is became stable.
2022-06-14 14:04:10 -07:00
Jeremy Volkman 84edc33239
Update to handle rename of java_names.h to names.h in protobuf upstream (#9218) 2022-05-31 15:08:10 -07:00
Sergii Tkachenko 9cb3c6e688 Start 1.48.0 development cycle 2022-05-18 13:57:28 -07:00
Eric Anderson 4a137d6ef0 Start 1.47.0 development cycle 2022-04-11 10:41:33 -07:00
Terry Wilson ec3db2b454
Start 1.46.0 development cycle (#8939) 2022-02-23 08:23:41 -08:00
yifeizhuang 26f0d611db
Start 1.45.0 development cycle (#8825) 2022-01-12 12:08:22 -08:00
ZHANG Dapeng 65c00cf24e
Start 1.44.0 development cycle (#8729) 2021-11-30 11:53:56 -08:00
Sergii Tkachenko 6d41b4283a Start 1.43.0 development cycle 2021-10-20 13:47:03 -04:00
Eric Anderson 1f1396f3f0 Start 1.42.0 development cycle 2021-09-08 09:10:20 -07:00
yifeizhuang 343eed1c04
Start 1.41.0 development cycle (#8351) 2021-07-28 15:27:55 -07:00
Eric Anderson 0cabf5672a compiler: Add GrpcGenerated annotation to generated class
This can be used by annotation processors to avoid processing the
gRPC-generated code. The normal Generated annotation only has SOURCE
retention, so isn't available to annotation processors.

I don't include the service name within the annotation as that assumes
we'll never have need for any other type of generated class. If there's
a request for exposing service name via an annotation in the future, we
can make an RpcService annotation or the like.

Fixes #8158
2021-07-02 22:11:40 -07:00
ZHANG Dapeng e980ebd118
Start 1.40.0 development cycle (#8263) 2021-06-16 08:04:43 -07:00
Eric Anderson 29618a6bb6 Bump Protobuf to 3.17.2
Removed some references to the protobuf version from COMPILING.md and
compiler/README.md to make updates a tiny bit easier.
2021-06-07 11:20:48 -07:00
Amit Shirodkar a6d78c5e3e
fix build on ppc64le (#8141) 2021-06-07 00:10:29 -07:00
Eric Gribkoff c0eca6de25
Start 1.39.0 development cycle (#8147) 2021-05-05 16:30:38 -07:00
Sergii Tkachenko e4b292aa9b Start 1.38.0 development cycle 2021-03-25 18:49:03 -04:00
Eric Anderson 2140480736 Start 1.37.0 development cycle 2021-02-11 13:53:10 -08:00
Eric Gribkoff f2f3bbeb5d
Start 1.36.0 development cycle (#7770) 2020-12-30 17:14:04 -08:00
ZHANG Dapeng 7d77f64773
compiler: remove some of the static imports in codegen (#7751)
Resolves #7741 
Some of the static methods in generated code have the same method name but different package name, such `ClientCalls.asyncClientStreamingCall` and `ServerCalls.asyncClientStreamingCall`. It's less readable using static import than using full-qualified method name in-place.
2020-12-23 11:28:03 -08:00
Chengyuan Zhang f5bbe12c9f
Start 1.35.0 development cycle (#7641) 2020-11-18 13:59:40 -08:00
ZHANG Dapeng 9b73e2365d
Start 1.34.0 development cycle 2020-10-06 16:10:51 -07:00
ZHANG Dapeng 09367030ae
all: fix lint 2020-08-28 13:00:44 -07:00
Eric Anderson eca8bf8e62 Start 1.33.0 development cycle 2020-08-26 16:13:21 -07:00
Eric Anderson 19d690b435 compiler: Use namespace aliases to reduce internal diff
Due to historical reasons, protobuf is in the proto2:: namespace
internally instead of google::protobuf. We have been maintaining diffs
that replace each occurence of one with the other. Instead we can simply
create a namespace alias and use that alias instead of the canonical
name. That greatly reduces the size of the diff and its likelihood to
break.

If the names ever align in the future, we can swap back to the canonical
names.
2020-08-07 14:58:32 -05:00
Eric Anderson f59c9a9c6b compiler: Swap to ABSL_FALLTHROUGH_INTENDED
FALLTHROUGH_INTENDED was defined by Abseil, but is now getting an ABSL
prefix and the old name will be removed. Swapping to a new define name
to avoid redefining the existing-but-soon-to-be-deleted
FALLTHROUGH_INTENDED.
2020-08-06 11:24:12 -05:00
Eric Gribkoff 7d97443cd7
Start 1.32.0 development cycle (#7214) 2020-07-15 13:51:06 -07:00
Jihun Cho ba09218030
doc: update protoc version requirement (#7064) 2020-05-27 09:11:47 -07:00
ZHANG Dapeng 97112b223f
compiler: support proto3 field presence for codegen
Support proto3 field presence #7051.

This is the same change as https://github.com/grpc/grpc/pull/22998/files#diff-6c29ff8771ae54ddf2c14e2ef3eb554fR37-R44
2020-05-21 15:39:10 -07:00
Chengyuan Zhang d667a67d15
Start 1.31.0 development cycle (#7050) 2020-05-19 16:46:16 -07:00
ZHANG Dapeng 0044f8ce56
all: migrate gradle build to java-library plugin
- Use gradle configuration `api` for dependencies that are part of grpc public api signatures.
- Replace deprecated gradle configurations `compile`, `testCompile`, `runtime` and `testRuntime`.
- With minimal change in dependencies: If we need dep X and Y to compile our code, and if X transitively depends on Y, then our build would still pass even if we only include X as `compile`/`implementation` dependency for our project. Ideally we should include both X and Y explicitly as `implementation` dependency for our project, but in this PR we don't add the missing Y if it is previously missing.
2020-05-04 16:44:30 -07:00
Andrew Gasparovic 2119fac35b
compiler: Remove unused function (#6911) 2020-04-08 14:12:00 -07:00
ZHANG Dapeng c91e127f93
Start 1.30.0 development cycle 2020-04-07 14:12:53 -07:00
Jihun Cho 3e9f3964c4 Start 1.29.0 development cycle 2020-02-26 09:37:27 -08:00
Jihun Cho 47c0b0b792
complier: fix typo in comment (#6747) 2020-02-24 14:32:26 -08:00
Jihun Cho 3b1af27073
compiler: add std:: qualifications to all references to std::string 2020-02-24 11:34:19 -08:00
Eric Anderson ca56aa30d4 Start 1.28.0 development cycle 2020-01-14 15:10:05 -08:00
Liu sheng 470a4ab12d Add support for cross-compiling for aarch64 platform
This change modified the building scripts to support cross compile
grpc-java for aarch64 platform

For grpc/grpc-java#6364
2019-12-06 14:21:34 -08:00
Eric Gribkoff bfa085a1cf
Start 1.27.0 development cycle (#6480) 2019-12-03 17:27:55 -08:00
Jihun Cho 7db873f1f6
Roll-forward of stub,compiler: generated stub extends Abstract{Async,Future,Blocking}Stub #6196 (#6458)
This reverts commit 2eb3f8c34e (#6317).
2019-11-25 09:41:16 -08:00
Eric Anderson 48929c4d50
Upgrade to protobuf lite 3.10
This finally brings lite into version number sync with full proto.

Well-known protos for javalite are now pre-generated.
2019-11-14 10:26:20 -08:00
Nayana-ibm 198ca2904a Adding s390x suport ot grpc-java 2019-11-13 14:43:59 -08:00
Kun Zhang 47d798bbec
Start 1.26.0 development cycle (#6329) 2019-10-23 15:27:22 -07:00
Jihun Cho 2eb3f8c34e
stub,compiler: Rollback Abstract{Future,Blocking,Async}Stub (#6317)
rollback of #6304 & #6196
2019-10-22 13:27:30 -07:00
Carl Mastrangelo f2d0f87d2e compiler: set safe and idempotent bits on method descriptors 2019-10-22 10:59:11 -07:00
Jihun Cho 45d49a56cc
stub,compiler: generated stub extends Abstract{Async,Future,Blocking}Stub (#6196) 2019-10-17 14:49:24 -07:00
Eric Anderson 9f0f2a3c85 bazel: Add compatibility for --incompatible_load_cc_rules_from_bzl 2019-10-16 13:29:19 -07:00
Jihun Cho e3be6a6bfa
compiler: add license header for cpp codes (#6208) 2019-09-27 09:22:42 -07:00
Eric Anderson 4215b80b81 Apply java plugin explicitly when needed 2019-09-13 09:42:17 -07:00
Eric Anderson 5b838e5284 Apply maven-publish plugin explicitly when needed 2019-09-13 09:42:17 -07:00
Eric Anderson 3c3a823a81 Swap to Gradle's Plugin DSL for much of build
Examples and android projects were left unchanged. They can be changed
later.

No plugin versions were changed, to make this as non-functional of a
change as possible. Upgrading Gradle to 5.6 was necessary for
pluginManagement in settings.gradle.
2019-09-13 09:42:17 -07:00
Chengyuan Zhang fa8f89a1a6
Start 1.25.0 development cycle (#6141) 2019-09-10 17:41:37 -07:00
ZHANG Dapeng e14f8de4ab
Start 1.24.0 development cycle 2019-07-31 11:03:13 -07:00
Jean de Klerk 188b4d1e51 compiler: add note about where to download precompiled version of plugin (#6022) 2019-07-29 17:08:03 -07:00
liym 47b11ab7a1 compiler: Use 'SERVICE_NAME' instead of duplicated '$Package$$service… (#5943)
* compiler: Use 'SERVICE_NAME' instead of duplicated '$Package$$service_name$'

* compiler: Align indentation

* Fix typo

* Add modified golden files and all re-generated code to meet Travis CI and Windows build requirements

See PR #5943

* Polishing
2019-07-24 10:37:13 -07:00
Eric Anderson 46ef51576f bazel: Add comment for public protoc plugin
The 3rd-party rules_proto project is referencing our compiler directly
and not using our java_grpc_library. This target is fine for them to
use (although we'd prefer using our java_grpc_library), but most users
shouldn't be touching it.

Related to #5942 and #5947
2019-07-03 15:04:07 -07:00
Adam Liddell f67aa4e305 Make //compiler:grpc_java_plugin publicly visible again
Prior to 745aa0a2f5, this target was
visible publicly.
2019-07-03 13:58:23 -07:00
Jihun Cho e57d4c5a8e
Start 1.23.0 development cycle (#5899) 2019-06-18 15:54:16 -07:00
Eric Anderson 50b08eee3b
Delete protobuf-nano
Nano was dropped from upstream protobuf. See gRFC L51
2019-05-22 08:49:07 -07:00
Eric Anderson 3aa3218fb2 Start 1.22.0 development cycle 2019-05-09 13:53:12 -07:00
Eric Anderson 745aa0a2f5 java_grpc_library: Use toolchain to enable DexArchiveAspect
This removes the "java_import to work around error with android_binary"
hack; see the b/78647825 references to see the really important parts.
But in general using a toolchain cleans up the code considerably and
allows us to reduce the visibility of our protoc plugin. It also is
useful to enable using aspects in the future to avoid using
make_non_strict() which would improve compilation speed avoid avoid many
unnecessary rebuilds.

This is an export of cl/229763103 and brings external up-to-sync with
internal.
2019-04-23 09:13:20 -07:00
Kun Zhang 026e4c53bd
Start 1.21.0 development cycle (#5515) 2019-03-28 13:27:45 -07:00
Carl Mastrangelo 041cf2abd4
Start 1.20.0 development cycle 2019-02-12 14:46:28 -08:00
Eric Anderson eaca73473c
Upgrade to protobuf 3.6.1
For Bazel, we upgrade to protobuf 3.6.1.2 and javalite HEAD to fix
incompatibilities in newer Bazel releases.

compiler/Dockerfile is unused, so it was removed instead of being updated.

protoc no longer includes codegen for nano, so we remain on the older protoc
any time nano is used.

Protobuf now requires C++11 when compiling, so windows was swapped to
VC 14.
2019-02-07 13:40:53 -08:00
Jihun Cho 1c3432c3fb
all: migrate gradle publish from maven to use maven-publish plugin (#5289) 2019-01-31 17:38:43 -08:00
ZHANG Dapeng 4337da6d7d
Start 1.19.0 development cycle 2019-01-02 15:31:01 -08:00
Thomas Broyer 2ffc46d6fa Update net.ltgt.errorprone to 0.6 and enable Error Prone on JDK 10+ 2018-12-13 10:17:06 -08:00
Jihun Cho 1506135333 Start 1.18.0 development cycle 2018-11-19 14:49:35 -08:00
Eric Anderson 959323be97
Add build support for Java 11
It appears everything was already working on Java 11, except
build-specific and testing issues. Updating to Netty 4.1.30 (#4940)
probably fixed the last true Java 11 incompatibility.

Fixes #4933
2018-10-17 11:49:30 -07:00
Eric Anderson 967cc64770 Start 1.17.0 development cycle 2018-10-11 09:29:23 -07:00
Kun Zhang 28d44ae46d
Start 1.16.0 development cycle (#4803) 2018-08-27 17:21:46 -07:00
elandau 0d4051ca6e Include Java's @Deprecated annotation on RPC services or methods with `option deprecated = true;` 2018-08-15 12:24:01 -07:00
zpencer 4335445d98
Start 1.15.0 development cycle (#4650) 2018-07-18 10:48:04 -07:00
Carl Mastrangelo 146b6006b3
compiler,stub: update RpcMethod docs and usage 2018-07-12 17:01:47 -07:00
jbingham-google ffcb3b964b compiler, stub: Rename inputType and outputType in @RpcMethod 2018-07-10 13:24:50 -07:00
jbingham-google 9229e30287 compiler, stub: Add @RpcMethod annotation
This annotation will enable Java APT to generate code.

Addresses part of #3173.
2018-07-06 17:02:01 -07:00
Carl Mastrangelo 3934ad9f4b
compiler: add stubs for generating nano code as lite 2018-06-12 10:03:28 -07:00
ZHANG Dapeng 5ce10f0146
all: add gradle format checker
This PR adds an automatic gradle format checker and reformats all the *.gradle files. After this, new changes to *.gradle files will fail to build if not in good format, just like checkStyle failure.
2018-06-11 18:35:18 -07:00
Carl Mastrangelo 4c4fda3e5d
stub: remove static Method descriptors and stabilize method accessors 2018-06-05 11:19:28 -07:00
ZHANG Dapeng 8a3e623be7
Start 1.14.0 development cycle 2018-06-04 16:08:31 -07:00
Eric Anderson e085a0eca0 Bump to Gradle 4.7
The new jmh plugin fixes a warning for the newer version of Gradle.
The new AppEngine plugin still produces a warning, but updating it
anyway so people know that upgrading the plugin doesn't fix the problem.
The new android-maven plugin fixes a build problem with the newer
Gradle.

The Visual Studio fixes were necessary starting ~4.4.
https://github.com/gradle/gradle-native/issues/34#issuecomment-335222096
describes the change in behavior.

There's nothing immediately being used as part of this update. It's just
to keep us current and to get us over that Visual Studio change hump.
2018-05-17 15:46:21 -07:00
Carl Mastrangelo 60a0b0c471
all: normalize copyright header 2018-05-03 14:55:21 -07:00
Carl Mastrangelo 8be87de9b0
compiler: make testing service used by compiler not conflict with interop-testing proto
This change puts the compiler test.proto file in a directory that matches it's path.  The current proto package has a namespace collision with the grpc.testing proto in interop-testing.  Thus, this PR:

* change the package of test.proto to be grpc.testing.compiler
* moves the test.proto into the matching grpc/testing/compiler/test.proto path
* updates the generated code.
2018-05-01 10:13:18 -07:00
zpencer 62e6e2de78
Start 1.13.0 development cycle (#4383) 2018-04-23 15:24:24 -07:00
zpencer 8d3d26dda1
compiler: allow capitalized java keywords as rpc names (#4309)
previously `Import` fails because it gets turned into a method named
`import`. This PR makes the method be named `import_`, everything else
stays the same, such as the name in the method descriptor.

Note: `iMport` or `iMPORT` or any variation of capitalizations that is
not `Import` always worked. `Import` gets translated into `import`
because of our attempts to camel case the names.
2018-04-05 16:45:19 -07:00
Eric Anderson 11c8bcde1b Start 1.12.0 development cycle 2018-03-13 09:04:25 -07:00
Eric Anderson 1fb72ef6c1 Ignore proto-generated code for ErrorProne
Previously if protobuf-generated code triggered ErrorProne we'd have to disable
the failing check for all code in that task. With -XepExcludedPaths we can
disable the ErrorProne-checking just for protobuf. Note that we continue using
ErrorProne on our generated code. Also note this only applies to ErrorProne
checks; JDK checks still require task-level disabling.
2018-03-09 11:19:20 -08:00
zpencer 066ad3ceac
buildscripts,travis: fetch from mvn with retries (#4140)
A band aid for #3284, to make its symptoms less noticeable.
2018-03-01 19:11:24 -08:00
Eric Gribkoff 6f9b4e87e1
compiler: avoid invoking experimental method in generated code 2018-02-08 11:25:38 -08:00
Eric Gribkoff 2f05c23063
Start 1.11.0 development cycle 2018-01-30 15:13:55 -08:00
Kun Zhang 86d64122e5
Upgrade to Protobuf 3.5.1 and Protoc 3.5.1-1. (#3921)
protoc-3.5.0-linux-x86_64 introduced GLIBC_2.14 dependency and broke
gRPC release process (https://github.com/google/protobuf/issues/4138).
3.5.1-1 is the proper re-build.
2018-01-05 16:40:20 -08:00
Kun Zhang 04420dfdf7
Start 1.10.0 development cycle (#3877) 2017-12-18 10:28:02 -08:00