Files
rongtong 6a9e84f113 [ISSUE #10651] bump DLedger to 0.3.3.4 (maintenance line) (#10958)
* chore: bump DLedger to 0.3.3.4 (maintenance line)

Update the DLedger dependency from 0.3.2 to 0.3.3.4, the latest
release on the 0.3.x maintenance line published on Maven Central.
The 0.3.3.4 release is API-compatible with 0.3.2 and only carries
dependency hygiene fixes (aligning fastjson2 and excluding fastjson1
from its rocketmq-remoting transitive path).

Also update the Bazel WORKSPACE artifact coordinate to keep the two
build systems in sync.

* chore: fully remove fastjson1 from the build

DLedger 0.3.3.4 already excludes com.alibaba:fastjson from its
rocketmq-remoting dependency and its bytecode only references
fastjson2, but rocketmq still declared fastjson1 itself, so it kept
leaking onto every module compile classpath through rocketmq-common.

- drop the com.alibaba:fastjson property and dependencyManagement
  entry from the root pom
- drop the unused com.alibaba:fastjson dependency from rocketmq-common
  (no main source imports com.alibaba.fastjson.*)
- drop the fastjson1 pin from WORKSPACE and the fastjson1 dep from the
  remoting test target in remoting/BUILD.bazel
- migrate RemotingSerializableCompatTest to fastjson2: use the
  fastjson2 JSONField annotation (which is what the protocol classes
  actually carry) and round trip through RemotingSerializable instead
  of com.alibaba.fastjson.JSON

fastjson1 wire-format coverage is retained by the frozen fastjson1
payload already asserted in testCompatibilityCheckWithBitSet.

* fix(bazel): exclude rocketmq-remoting from coursier resolution

dledger 0.3.3.4 depends on rocketmq-remoting:5.5.0, which Coursier
fetches from Maven Central. That artifact transitively brings
grpc-netty-shaded:1.53.0 with a strict [1.53.0] range on grpc-core,
conflicting with the WORKSPACE-declared grpc 1.47.0 artifacts.

Since rocketmq-remoting is built from source in this repo (//remoting),
exclude it from external resolution — matching what PR #10947 already
does for the DLedger 0.4.x line.

---------

Co-authored-by: 通融 <rongtong.jrt@alibaba-inc.com>
2026-08-19 14:58:30 +08:00

83 lines
3.3 KiB
Python

#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
load("//bazel:GenTestRules.bzl", "GenTestRules")
java_library(
name = "remoting",
srcs = glob(["src/main/java/**/*.java"]),
visibility = ["//visibility:public"],
deps = [
"//common",
"@maven//:com_alibaba_fastjson2_fastjson2",
"@maven//:com_google_guava_guava",
"@maven//:com_google_code_findbugs_jsr305",
"@maven//:com_squareup_okio_okio_jvm",
"@maven//:io_netty_netty_all",
"@maven//:io_opentelemetry_opentelemetry_api",
"@maven//:io_opentelemetry_opentelemetry_context",
"@maven//:io_opentelemetry_opentelemetry_exporter_otlp",
"@maven//:io_opentelemetry_opentelemetry_exporter_prometheus",
"@maven//:io_opentelemetry_opentelemetry_sdk",
"@maven//:io_opentelemetry_opentelemetry_sdk_common",
"@maven//:io_opentelemetry_opentelemetry_sdk_metrics",
"@maven//:org_apache_tomcat_annotations_api",
"@maven//:org_apache_commons_commons_lang3",
"@maven//:io_github_aliyunmq_rocketmq_slf4j_api",
"@maven//:io_github_aliyunmq_rocketmq_logback_classic",
"@maven//:commons_collections_commons_collections",
"@maven//:org_reflections_reflections",
],
)
java_library(
name = "tests",
srcs = glob(["src/test/java/**/*.java"]),
visibility = ["//visibility:public"],
deps = [
":remoting",
"//common",
"//:test_deps",
"@maven//:org_objenesis_objenesis",
"@maven//:com_alibaba_fastjson2_fastjson2",
"@maven//:com_google_code_gson_gson",
"@maven//:com_google_guava_guava",
"@maven//:com_google_code_findbugs_jsr305",
"@maven//:com_squareup_okio_okio_jvm",
"@maven//:io_netty_netty_all",
"@maven//:io_opentelemetry_opentelemetry_api",
"@maven//:io_opentelemetry_opentelemetry_context",
"@maven//:io_opentelemetry_opentelemetry_exporter_otlp",
"@maven//:io_opentelemetry_opentelemetry_exporter_prometheus",
"@maven//:io_opentelemetry_opentelemetry_sdk",
"@maven//:io_opentelemetry_opentelemetry_sdk_common",
"@maven//:io_opentelemetry_opentelemetry_sdk_metrics",
"@maven//:org_apache_tomcat_annotations_api",
"@maven//:org_apache_commons_commons_lang3",
"@maven//:org_jetbrains_annotations",
"@maven//:org_reflections_reflections",
],
resources = glob(["src/test/resources/certs/*.pem"]) + glob(["src/test/resources/certs/*.key"])
)
GenTestRules(
name = "GeneratedTestRules",
test_files = glob(["src/test/java/**/*Test.java"]),
deps = [
":tests",
],
)