Commit Graph
12134 Commits
Author SHA1 Message Date
chrislu c49abc0c2f security: upgrade Apache ZooKeeper to 3.9.4
- Upgrade from 3.9.3 to 3.9.4 (latest stable)
- Ensures all known security vulnerabilities are patched
- Fixes GHSA-g93m-8x6h-g5gv, GHSA-r978-9m6m-6gm6, GHSA-2hmj-97jw-28jh
2025-11-22 17:55:17 -08:00
chrislu a051452fe6 security: upgrade Apache ZooKeeper to 3.9.3
- Upgrade from 3.9.1 to 3.9.3
- Fixes GHSA-g93m-8x6h-g5gv: Authentication bypass in Admin Server
- Fixes GHSA-r978-9m6m-6gm6: Information disclosure in persistent watchers
- Fixes GHSA-2hmj-97jw-28jh: Insufficient permission check in snapshot/restore
- Addresses high and moderate severity vulnerabilities
2025-11-22 17:55:03 -08:00
chrislu 150deefdc0 fix: aggressively suppress Parquet DEBUG logging
- Set Parquet I/O loggers to OFF (completely disabled)
- Add log4j.configuration system property to ensure config is used
- Override Spark's default log4j configuration
- Prevents thousands of record-level DEBUG messages in CI logs
2025-11-22 17:52:02 -08:00
chrislu f71e3448b4 ci: skip central-publishing plugin during build
- Add -Dcentral.publishing.skip=true to all Maven builds
- Central publishing plugin is only needed for Maven Central releases
- Prevents plugin resolution errors during CI builds
- Complements existing -Dgpg.skip=true flag
2025-11-22 17:50:14 -08:00
chrislu b018588c14 security: upgrade Netty to 4.1.124.Final (patched version)
- Upgrade from 4.1.118.Final to 4.1.124.Final
- Fixes GHSA-prj3-ccx8-p6x4: MadeYouReset HTTP/2 DDoS vulnerability
- 4.1.124.Final is the confirmed patched version per GitHub advisory
- All versions <= 4.1.123.Final are vulnerable
2025-11-22 14:22:57 -08:00
chrislu 4dd55783da security: upgrade Netty to 4.1.118.Final
- Upgrade from 4.1.115.Final to 4.1.118.Final
- Fixes CVE-2025-24970: improper validation in SslHandler
- Fixes CVE-2024-47535: unsafe environment file reading on Windows
- Fixes CVE-2024-29025: HttpPostRequestDecoder resource exhaustion
- Addresses GHSA-prj3-ccx8-p6x4 and related vulnerabilities
2025-11-22 14:22:41 -08:00
chrislu fab383dc10 fix: use 127.0.0.1 for volume server IP registration
- Change volume -ip from seaweedfs-volume to 127.0.0.1
- Change -publicUrl from localhost:8080 to 127.0.0.1:8080
- Volume server now registers with master using 127.0.0.1
- Filer will return 127.0.0.1:8080 URL that's resolvable from host
- Fixes UnknownHostException for seaweedfs-volume hostname
2025-11-22 14:21:02 -08:00
chrislu 707e7732a7 fix: suppress verbose Parquet DEBUG logging
- Set org.apache.parquet to WARN level
- Set org.apache.parquet.io to ERROR level
- Suppress RecordConsumerLoggingWrapper and MessageColumnIO DEBUG logs
- Reduces CI log noise from thousands of record-level messages
- Keeps important error messages visible
2025-11-22 14:20:11 -08:00
chrislu 8c13794a49 security: upgrade Netty to 4.1.115.Final to fix CVE
- Upgrade netty.version from 4.1.100.Final to 4.1.115.Final
- Fixes GHSA-prj3-ccx8-p6x4: MadeYouReset HTTP/2 DDoS vulnerability
- Netty 4.1.115.Final includes patches for high severity DoS attack
- Addresses GitHub dependency review security alert
2025-11-22 14:09:54 -08:00
chrislu abaf933971 fix: add publicUrl to volume server for host network access
- Add -publicUrl=localhost:8080 to volume server command
- Ensures filer returns localhost URL instead of Docker service name
- Fixes UnknownHostException when tests run on host network
- Volume server is accessible via localhost from CI runner
2025-11-22 14:08:20 -08:00
chrislu 01e20a350c refactor: extract surefire JVM args to property
- Move multi-line argLine to surefire.jvm.args property
- Reference property in argLine for cleaner configuration
- Improves maintainability and readability
- Follows Maven best practices for JVM argument management
- Avoids potential whitespace parsing issues
2025-11-22 14:07:01 -08:00
chrislu 3074b1ee2f refactor: externalize seaweedfs-hadoop3-client version to property
- Add seaweedfs.hadoop3.client.version property set to 3.80
- Replace hardcoded version with ${seaweedfs.hadoop3.client.version}
- Enables easier version management from single location
- Follows Maven best practices for dependency versioning
2025-11-22 14:06:21 -08:00
chrislu 7b548be48e security: add dependencyManagement to fix vulnerable transitives
- Pin Jackson to 2.15.3 (fixes multiple CVEs in older versions)
- Pin Netty to 4.1.100.Final (fixes CVEs in transport/codec)
- Pin Apache Avro to 1.11.4 (fixes deserialization CVEs)
- Pin Apache ZooKeeper to 3.9.1 (fixes authentication bypass)
- Pin commons-compress to 1.26.0 (fixes zip slip vulnerabilities)
- Pin commons-io to 2.15.1 (fixes path traversal)
- Pin Guava to 32.1.3-jre (fixes temp directory vulnerabilities)
- Pin SnakeYAML to 2.2 (fixes arbitrary code execution)
- Pin Jetty to 9.4.53 (fixes multiple HTTP vulnerabilities)
- Overrides vulnerable versions from Spark/Hadoop transitives
2025-11-22 14:05:24 -08:00
chrislu 9e8b8276ea fix: build statically linked binary for Alpine Linux
- Add CGO_ENABLED=0 to go build command
- Creates statically linked binary compatible with Alpine (musl libc)
- Fixes 'not found' error caused by missing glibc dynamic linker
- Add file command to verify static linking in build output
2025-11-22 13:57:40 -08:00
chrislu a61af2989c ci: add comprehensive failure diagnostics
- Add container status (docker compose ps -a) on startup failure
- Add detailed logs for all three services (master, volume, filer)
- Add container inspection to verify binary exists
- Add debugging info for spark-example job
- Helps diagnose startup failures before containers are torn down
2025-11-22 13:52:27 -08:00
chrislu 0a7917704e ci: add debugging and force rebuild of Docker images
- Add ls -la to show build-artifacts/docker/ contents
- Add file command to verify binary type
- Add --no-cache to docker compose build to prevent stale cache issues
- Ensures fresh build with current binary
2025-11-22 13:51:42 -08:00
chrislu e29163dfa4 fix: remove invalid shell operators from Dockerfile COPY
- Remove '|| true' from COPY commands (not supported in Dockerfile)
- Remove optional weed_pub* and weed_sub* copies (not needed for tests)
- Simplify Dockerfile to only copy required files
- Keep chmod +x and ls -la verification for main binary
2025-11-22 13:46:32 -08:00
chrislu 459ff0bd38 fix: improve binary copy and chmod in Dockerfile
- Copy weed binary explicitly to /usr/bin/weed
- Run chmod +x immediately after COPY to ensure executable
- Add ls -la to verify binary exists and has correct permissions
- Make weed_pub* and weed_sub* copies optional with || true
- Simplify RUN commands for better layer caching
2025-11-22 13:40:46 -08:00
chrislu ec08fadf85 fix: align maven-compiler-plugin with compiler properties
- Change compiler plugin source/target from hardcoded 1.8 to use properties
- Ensures consistency with maven.compiler.source/target set to 11
- Prevents version mismatch between properties and plugin configuration
- Aligns with surefire Java 9+ module arguments
2025-11-22 13:39:22 -08:00
chrislu becb250ab8 refactor: eliminate code duplication in channel creation
- Extract common gRPC channel configuration to createChannelBuilder() method
- Reduce code duplication from 3 branches to single configuration
- Improve maintainability by centralizing channel settings
- Add Javadoc for the new helper method
2025-11-22 13:38:57 -08:00
chrislu c7e31c5ddb refactor: remove unused imports in FilerGrpcClient
- Remove unused io.grpc.Deadline import
- Remove unused io.netty.handler.codec.http2.Http2Settings import
- Clean up linter warnings
2025-11-22 13:38:11 -08:00
chrislu 45b45c4a8d fix: ensure weed binary is executable in Docker image
- Add chmod +x for weed binaries in Dockerfile.local
- Artifact upload/download doesn't preserve executable permissions
- Ensures binaries are executable regardless of source file permissions
2025-11-22 13:36:46 -08:00
chrislu e8e9df2680 test: improve docker-compose config for Spark tests
- Add -volumeSizeLimitMB=50 to master (consistent with other integration tests)
- Add -defaultReplication=000 to master for explicit single-copy storage
- Add explicit -port and -port.grpc flags to all services
- Add -preStopSeconds=1 to volume for faster shutdown
- Add healthchecks to master and volume services
- Use service_healthy conditions for proper startup ordering
- Improve healthcheck intervals and timeouts for faster startup
- Use -ip flag instead of -ip.bind for service identity
2025-11-22 13:35:52 -08:00
chrislu dd9c1c6190 fix: add -peers=none to master command for standalone mode
- Ensures master runs in standalone single-node mode
- Prevents master from trying to form a cluster
- Required for proper initialization in test environment
2025-11-22 13:34:01 -08:00
chrislu f3d9aa47ab ci: fix artifact download path to avoid checkout conflicts
- Download artifacts to 'build-artifacts' directory instead of '.'
- Prevents checkout from overwriting downloaded files
- Explicitly copy weed binary from build-artifacts to docker/ directory
- Update Maven artifact restoration to use new path
2025-11-22 13:29:08 -08:00
chrislu 29d3fc13dd ci: fix SeaweedFS binary permissions after artifact download
- Add step to chmod +x the weed binary after downloading artifacts
- Artifacts lose executable permissions during upload/download
- Prevents 'Permission denied' errors when Docker tries to run the binary
2025-11-22 13:22:58 -08:00
chrislu e63feb48fc ci: fix Maven artifact restoration in workflow
- Add step to restore Maven artifacts from download to ~/.m2/repository
- Restructure artifact upload to use consistent directory layout
- Remove obsolete 'version' field from docker-compose.yml to eliminate warnings
- Ensures SeaweedFS Java dependencies are available during test execution
2025-11-22 13:14:52 -08:00
chrislu 93f1d0fc14 ci: update actions/cache from v3 to v4
- Update deprecated actions/cache@v3 to actions/cache@v4
- Ensures continued support and bug fixes
- Cache key and path remain compatible with v4
2025-11-22 13:07:25 -08:00
chrislu 786f5de7bb ci: refactor Spark workflow for DRY and robustness
1. Add explicit permissions (least privilege):
   - contents: read
   - checks: write (for test reports)
   - pull-requests: write (for PR comments)

2. Extract duplicate build steps into shared 'build-deps' job:
   - Eliminates duplication between spark-tests and spark-example
   - Build artifacts are uploaded and reused by dependent jobs
   - Reduces CI time and ensures consistency

3. Fix spark-example service startup verification:
   - Match robust approach from spark-tests job
   - Add explicit timeout and failure handling
   - Verify all services (master, volume, filer)
   - Include diagnostic logging on failure
   - Prevents silent failures and obscure errors

These changes improve maintainability, security, and reliability
of the Spark integration test workflow.
2025-11-22 13:06:14 -08:00
chrislu b35463c8b4 spark: fix flaky test by sorting DataFrame before first()
- In testLargeDataset(), add orderBy("value") before calling first()
- Parquet files don't guarantee row order, so first() on unordered
  DataFrame can return any row, making assertions flaky
- Sorting by 'value' ensures the first row is always the one with
  value=0, making the test deterministic and reliable
2025-11-22 13:04:44 -08:00
chrislu 6f905acfd2 spark: update compiler source/target from Java 8 to Java 11
- Fix inconsistency between maven.compiler.source/target (1.8) and
  surefire JVM args (Java 9+ module flags like --add-opens)
- Update to Java 11 to match CI environment (GitHub Actions uses Java 11)
- Docker environment uses Java 17 which is also compatible
- Java 11+ is required for the --add-opens/--add-exports flags used
  in the surefire configuration
2025-11-22 13:03:55 -08:00
chrislu fba36f8d1c java: fix NPE in SeaweedWrite and Makefile env var scope
- Add null check for HttpEntity in SeaweedWrite.multipartUpload()
  to prevent NPE when response.getEntity() returns null
- Fix Makefile test target to properly export SEAWEEDFS_TEST_ENABLED
  by setting it on the same command line as mvn test
- Update docker-compose commands to use V2 syntax (docker compose)
  for consistency with GitHub Actions workflow
2025-11-22 13:00:41 -08:00
chrislu 9da70aa3dc mod 2025-11-22 12:58:28 -08:00
chrislu e15e2e23c4 fix building 2025-11-22 12:56:43 -08:00
chrislu 3841fac4fe go mod tidy 2025-11-22 12:38:45 -08:00
chrislu c84a050e64 build clients 2025-11-22 12:32:27 -08:00
chrislu d94cacaf91 docker compose 2025-11-22 12:29:15 -08:00
chrislu c86177e063 add comments 2025-11-22 12:28:09 -08:00
chrislu 803f65742c Update dependency-reduced-pom.xml 2025-11-22 12:25:58 -08:00
chrislu f52d57ff4e CI/CD workflow 2025-11-22 12:23:56 -08:00
chrislu 89a6d42cee Complete Spark integration test suite 2025-11-22 12:23:48 -08:00
chrislu a428aeb5d7 Connection pooling, HTTP/2 tuning, keepalive 2025-11-22 12:23:01 -08:00
chrislu ed21e2d806 Retry logic 2025-11-22 12:22:50 -08:00
chrislu dafca41615 grpc-go 1.75.1 → 1.77.0 2025-11-22 12:22:41 -08:00
chrislu 409a9e4e23 grpc-java 1.75.0 → 1.77.0 2025-11-22 12:22:31 -08:00
chrislu a7f786ac92 NPE 2025-11-22 12:22:19 -08:00
chrislu 4c1c6f622d Fix keepalive mismatch 2025-11-22 12:22:08 -08:00
chrislu 5cc1b42643 remove hdfs-over-ftp 2025-11-21 21:06:29 -08:00
chrislu c96448f3a5 more flexible replication configuration 2025-11-21 21:06:14 -08:00
c89f394aba Parallelize ec.rebuild operations per affected volume. (#7466)
* Parallelize `ec.rebuild` operations per affected volume.

* node.freeEcSlot >= slotsNeeded

* variable names, help messages,

* Protected the read operation with the same mutex

* accurate error message

* fix broken test

---------

Co-authored-by: chrislu <chris.lu@gmail.com>
Co-authored-by: Chris Lu <chrislusf@users.noreply.github.com>
2025-11-21 17:58:37 -08:00