voonhous opened a new pull request, #18664:
URL: https://github.com/apache/hudi/pull/18664

   ### Describe the issue this Pull Request addresses
   
   BuildKit emits three classes of lint warnings across the Hudi `docker/` 
tree. Two of them are real bugs (silent empty env vars, signal-handling), the 
third is style:
   
   - `LegacyKeyValueFormat`: `ENV KEY VALUE` form is deprecated.
   - `UndefinedVar`: pre-FROM `ARG`s do not carry into the build stage, so `ENV 
HADOOP_DN_PORT ${HADOOP_DN_PORT}` etc. expanded to empty strings.
   - `JSONArgsRecommended`: `CMD startup.sh` runs through `/bin/sh -c`, which 
swallows SIGTERM and breaks graceful shutdown of the metastore/hiveserver.
   
   ### Summary and Changelog
   
   - Rewrite `ENV KEY VALUE` to `ENV KEY=VALUE` across 13 Dockerfiles. Quoted 
values and `${VAR}` expansion are preserved.
   - Re-declare `HADOOP_DN_PORT`, `HADOOP_WEBHDFS_PORT`, and 
`HADOOP_HISTORY_PORT` as `ARG` after the `FROM` line in `datanode`, `namenode`, 
and `historyserver`, so the corresponding `ENV` expansions actually receive the 
build-arg values.
   - `hive_base`: switch `CMD startup.sh` to JSON-array form `CMD 
["startup.sh"]` so SIGTERM is delivered directly to the script.
   - Drop a couple of trailing whitespaces in `ARG HADOOP_VERSION` lines.
   
   Files touched: `base`, `base_java11`, `base_java17`, `datanode`, 
`historyserver`, `hive_base`, `namenode`, `prestobase`, `spark_base`, 
`sparkadhoc`, `sparkmaster`, `sparkworker`, `trinobase`.
   
   ### Impact
   
   - Build: BuildKit lint warnings cleared.
   - Runtime: previously empty `HADOOP_DN_PORT` / `HADOOP_WEBHDFS_PORT` / 
`HADOOP_HISTORY_PORT` env vars are now populated from the corresponding ARGs 
(default values unchanged: 50075 / 50070 / 8188).
   - Runtime: hive metastore/hiveserver containers now receive SIGTERM directly 
instead of through `/bin/sh -c`, so `docker stop` shuts them down cleanly.
   
   ### Risk Level
   
   low. Docker build only. The behavior changes (env var population, signal 
delivery) are corrections, not new features, and defaults match prior intent.
   
   ### Documentation Update
   
   none.
   
   ### Contributor's checklist
   
   - [x] Read through [contributor's 
guide](https://hudi.apache.org/contribute/how-to-contribute)
   - [x] Enough context is provided in the sections above
   - [x] Adequate tests were added if applicable


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to