adoroszlai opened a new pull request, #10655: URL: https://github.com/apache/ozone/pull/10655
## What changes were proposed in this pull request? Java 24/25 deprecation warnings are shown for several commands even after HDDS-15668. ```bash WARNING: A restricted method in java.lang.System has been called WARNING: java.lang.System::loadLibrary has been called by org.apache.hadoop.util.NativeCodeLoader in an unnamed module (file:/opt/hadoop/share/ozone/lib/hadoop-common-3.4.3.jar) WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for callers in this module WARNING: Restricted methods will be blocked in a future release unless native access is enabled WARNING: A terminally deprecated method in sun.misc.Unsafe has been called WARNING: sun.misc.Unsafe::arrayBaseOffset has been called by com.google.protobuf.UnsafeUtil$MemoryAccessor (file:/opt/hadoop/share/ozone/lib/protobuf-java-3.25.9.jar) WARNING: Please consider reporting this to the maintainers of class com.google.protobuf.UnsafeUtil$MemoryAccessor WARNING: sun.misc.Unsafe::arrayBaseOffset will be removed in a future release ``` Examples: ```bash ozone insight logs om.protocol.client ozone repair om compact --column-family fileTable ozone s3 getsecret ozone shell volume list ozone tenant list ``` Problems: - several commands completely ignore `OZONE_MODULE_ACCESS_ARGS` - `ozone repair` sets `OZONE_DEBUG_OPTS` instead of `OZONE_REPAIR_OPTS` - `ozone shell` is an alias for `ozone sh`, but only in the subcommand switch, so `ozone_subcommand_opts` looks for `OZONE_SHELL_OPTS` Fix: - Apply `RATIS_OPTS` and `OZONE_MODULE_ACCESS_ARGS` to `OZONE_OPTS` globally. Setting these for commands that do not need them is harmless. - Update `OZONE_SUBCMD` upon `shell -> sh` conversion. https://issues.apache.org/jira/browse/HDDS-15732 ## How was this patch tested? ```bash $ ozone repair om compact --column-family fileTable Compaction request issued for om.db of om node: null, column-family: fileTable with bottommost level compaction: kSkip. Please check role logs of null for completion status. $ export OZONE_SHELL_SCRIPT_DEBUG=true $ ozone repair --help 2>&1 | grep -o '[^ ]*enable-native-access[^ ]*' --enable-native-access=ALL-UNNAMED $ ozone s3 getsecret --help 2>&1 | grep -o '[^ ]*enable-native-access[^ ]*' --enable-native-access=ALL-UNNAMED $ ozone tenant list --help 2>&1 | grep -o '[^ ]*enable-native-access[^ ]*' --enable-native-access=ALL-UNNAMED $ ozone shell volume list --help 2>&1 | grep -o '[^ ]*enable-native-access[^ ]*' --enable-native-access=ALL-UNNAMED ``` CI: https://github.com/adoroszlai/ozone/actions/runs/28657320150 -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
