Commit Graph

684 Commits

Author SHA1 Message Date
David L. Jones
171a6b1155
[Bazel/C++] Move core C++ implementation to //src/google/protobuf package. (#9988)
This is somewhat of a rough cut, since it doesn't split apart the lite and full targets, or unit tests. However, it does split sources under src/google/protobuf into a separate package, which is a fairly impactful change.
2022-05-18 13:45:22 -07:00
Deanna Garcia
193da6c8a9 Merge release branch 21.x into main 2022-05-13 18:07:04 +00:00
David L. Jones
b64cd5ac64
Switch C++ test protos to use the normal cc_proto_library rules. (#9950) 2022-05-11 16:45:17 -07:00
Protobuf Team
d259bd3287 Updating version.json and repo version numbers to: 21.0-rc1 2022-05-10 11:34:07 -07:00
David L. Jones
637a699969
[Bazel] Move conformance test targets to //conformance. (#9922) 2022-05-06 13:30:48 -07:00
David L. Jones
52655b1f5e
[Bazel] Move C++ build-related logic into //build_defs (#9921)
These are all "toolchain-y" things, like copts, link_opts, and config_settings. These are very different from what is in //toolchain, though, so I chose the somewhat common name build_defs for the package. For now, I am only using this package for purely internal things. (Most public "defs"-type things should come from rules_proto/rules_cc, anyhow.)
2022-05-06 12:11:46 -07:00
David L. Jones
5ebde5bd20
[Bazel] Expand lists of protos in BUILD files (#9915)
This unrolls several lists based on WELL_KNOWN_PROTO maps, and move internal java codegen rules next to the corresponding java_library targets that expose them.
2022-05-05 13:29:47 -07:00
David L. Jones
67823fe8dc
[Bazel] Fix broken build rules or mark them manual (#9913)
* Fix filename for unittest_gen_import.proto.

* Add 'manual' tags to jvm_export rules so they aren't selected by wildcard

* Run buildifier
2022-05-04 17:30:23 -07:00
deannagarcia
f2a126e349
Merge pull request #9909 from deannagarcia/ktDuplicates
Remove duplicate java generated code
2022-05-03 14:16:31 -07:00
Deanna Garcia
7bd1da828b Remove duplicate java generated code 2022-05-03 20:13:11 +00:00
Adam Cozzette
5eafa23c98
Update CHANGES.txt (#9897) 2022-05-03 10:26:36 -07:00
zhangskz
b37b613436
Update protobuf_version.bzl to separate protoc and per-language java major version (#9900) 2022-05-03 11:58:31 -04:00
David L. Jones
95da0ba5b4
Rename all BUILD files to BUILD.bazel (#9892)
This avoids conflicting names in a couple of cases.

1. Within google, we want to sync files but not name them BUILD (since the structure doesn't match).
2. On case-insensitive filesystems, `build` may be used for a build directory. Naming `BUILD.bazel` avoids potentioal conflicts.
2022-04-29 17:57:55 -07:00
Joshua Haberman
dc4aad931e Sync from Piper @444600173
PROTOBUF_SYNC_PIPER
2022-04-26 17:38:22 +00:00
Joshua Haberman
87edf7b558 Sync from Piper @443477877
PROTOBUF_SYNC_PIPER
2022-04-21 21:22:55 +00:00
David L. Jones
9e09343a49 Sync from Piper @441896533
PROTOBUF_SYNC_PIPER
2022-04-14 17:36:14 -07:00
David L. Jones
119f7d7dab Merge tag 'refs/tags/sync-piper' into sync-stage 2022-04-14 17:36:14 -07:00
noahdietz
5abf802bc2 Replace master with main in URLs & docs 2022-04-12 10:25:08 -07:00
Elliotte Rusty Harold
a85bbad379
deps: update Guava to 31.1 (#9757)
@mrkruskal
2022-04-08 18:43:11 +00:00
mkruskal-google
85aa87cbc9
Merge 3.20.1-rc1 into main (#9760)
* Fix NPE during encoding and add regression test for issue 9507.

(cherry picked from commit 58e320a732)

* Implement `respond_to?` in RubyMessage (#9677)

All synthetic methods implemented by `method_missing` are now supported by `respond_to?`.

Fixes issue #9202.

* Fix null pointer exceptions exposed by new regression tests.
* Fix clear_ on oneofs so that it is safe to call repeatedly and so that respond_to? does not depend on whether the oneof is currently cleared.
* Code cleanup: reenable more tests on JRuby.
* Align JRuby behavior with CRuby by throwing a RuntimeError when attempting to assign to a oneof.

(cherry picked from commit 8e7f936696)

* Update protobuf version

* Merge pull request #9727 from mlocati/build-packaged-php-extension

Fix building packaged PHP extension

(cherry picked from commit 7f9901c5f6)

* Update protobuf version

* Update changelogs for 3.20.1-rc1

Co-authored-by: Jason Lunn <jason.lunn@gmail.com>
Co-authored-by: Jorg Brown <jorg.brown@gmail.com>
2022-04-07 18:33:58 -04:00
Mike Kruskal
a29e0e3f44 Sync from Piper @439400376
PROTOBUF_SYNC_PIPER
2022-04-04 13:42:37 -07:00
David L. Jones
40db3dabf0 Sync from Piper @436871048
PROTOBUF_SYNC_PIPER
2022-03-23 17:36:26 -07:00
Darly Paredes
a4c9effec1 Sync from Piper @436517178
PROTOBUF_SYNC_PIPER
2022-03-22 18:02:10 +00:00
Adam Cozzette
a336ba0346 Sync from Piper @435734090
PROTOBUF_SYNC_PIPER
2022-03-18 21:25:56 +00:00
Adam Cozzette
b20209f321 Sync from Piper @acozzette/proto_github_202203101748
PROTOBUF_SYNC_PIPER
2022-03-10 18:36:42 +00:00
Adam Cozzette
88a18db91e Update protobuf version 2022-03-04 09:52:19 -08:00
Adam Cozzette
839f0f8e06 Add missing GSON dependency 2022-03-03 22:03:15 +00:00
Adam Cozzette
b0f9799a7c Sync from Piper @432209397
PROTOBUF_SYNC_PIPER
2022-03-03 17:18:16 +00:00
Adam Cozzette
f7232f2aa3 Replace EasyMock dependency with Mockito and re-pin Bazel deps 2022-03-02 19:27:59 +00:00
Adam Cozzette
76398dab31 Sync from Piper @431959314
PROTOBUF_SYNC_PIPER
2022-03-02 17:37:55 +00:00
David L. Jones
3ab97ce830 Sync from Piper @429642851
PROTOBUF_SYNC_PIPER
2022-02-18 14:02:12 -08:00
David L. Jones
1ba1d73e0d Sync from Piper @429333699
PROTOBUF_SYNC_PIPER
2022-02-17 09:53:51 -08:00
Joshua Haberman
06196e9b4c Merge tag 'refs/tags/sync-piper' into sync-stage 2022-02-08 20:53:32 -08:00
Joshua Haberman
dce403a8b3 Sync from Piper @427369078
PROTOBUF_SYNC_PIPER
2022-02-08 20:53:31 -08:00
Joshua Haberman
5aacba062b Resolved remaining conflict markers. 2022-02-08 18:38:48 -08:00
Joshua Haberman
42e806fbf2 Merge branch 'master' into sync-stage-2 2022-02-08 18:36:24 -08:00
Deanna Garcia
c8b388a6cb Fixing java test 2022-02-04 00:23:34 +00:00
Deanna Garcia
5e0fc2f1df Fix java tests 2022-02-03 18:02:13 +00:00
Phil Clay
3be46483ba
Resolve more java field accessor name conflicts (#8198)
* Remove javanano from .gitignore.
Ignore java/lite/target

* Resolve more java field accessor name conflicts.

Previously, some proto field names would cause the java code generator to generate accessor names that conflict with method names from the message super classes/interfaces.
A list of field names that cause such conflicts previously existed, but the list did not contain every field name that would cause a conflict.
Additionally, only snake_case field names would be detected. If the field name was in camelCase, the conflict would not be detected.

This change adds the complete set of field names that will cause assessor name conflicts, and detects conflicts in both snake_case and camelCase field names.

Fixes #8142

* Prevent java accessor name conflicts for fields with leading underscores.
Previously, some protobuf field names beginning with leading underscores (e.g. _class) would cause uncompilable java code to be generated due to assessor name conflicts.
Now, non-conflicting java accessor method names are created for those fields

* Improve comments/documentation for conversion from snake case to camel case
Rename snakeCaseToCamelCase to snakeCaseToLowerCamelCase
Add snakeCaseToUpperCamelCase
Add clarifying in-line comments for field name generation
Remove explicit version numbers from references.

* Fix indents and typo

* Unnest <pre> tag

* improve grammar in comments
are colliding -> collide

* Remove ternary operator and improve comments

* Fix typo in comment
2022-02-03 12:49:57 -05:00
Deanna Garcia
b2ff4f82c2 Fixing tests 2022-02-03 01:05:20 +00:00
Deanna Garcia
7dff52929f Fixing tests 2022-02-02 21:08:44 +00:00
Deanna Garcia
349738dde5 Fixing java and protoc builds 2022-02-01 23:22:23 +00:00
Deanna Garcia
b7fe12e367 Syncing from internal 2022-02-01 21:30:49 +00:00
Deanna Garcia
ab4585a695 Sync from Piper @425656941
PROTOBUF_SYNC_PIPER
2022-02-01 18:24:53 +00:00
Adam Cozzette
18521f6055 Merge branch '3.19.x' into merge-3.19.x 2022-01-28 17:42:21 +00:00
Adam Cozzette
22d0e265de
Update protobuf version for 3.19.4 (#9449)
I also updated the PHP release notes in
php/ext/google/protobuf/package.xml.
2022-01-27 19:35:56 -08:00
Maximilian
82372d8fe6
Use proper SPDX license identifier (#9441)
The previously used term "3-Clause BSD License" is not properly
standarized. A common standard is SPDX, therefore "3-Clause BSD License"
is substituted with "BSD-3-Clause" which is a SPDX identifier.

`grep -rl "3-Clause BSD License" | xargs -n1 sed -i "s/3-Clause BSD
License/BSD-3-Clause/g"`
2022-01-27 00:23:14 +00:00
Deanna Garcia
6e8b0dfcbf Switch to java_test 2022-01-20 22:24:59 +00:00
Deanna Garcia
a784e515e1 fix pom errors 2022-01-13 22:50:11 +00:00
Deanna Garcia
01f09b3425 Fixing bazel build failure 2022-01-13 00:29:28 +00:00