Skip to content

Commit

Permalink
Single warning message if the same library loaded-AIX
Browse files Browse the repository at this point in the history
eclipse-openj9#1264

Fix added to restrict display of multiple warnings on loading the same agent on AIX

Closes eclipse-openj9#1264
Signed-off-by: Sreekala Gopakumar <sreekala.gopakumar@ibm.com>
  • Loading branch information
Sreekala-Gopakumar committed Mar 4, 2024
1 parent c154bcb commit dedd9e2
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
10 changes: 9 additions & 1 deletion docs/version0.44.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ The following new features and notable changes since version 0.43.0 are included

- [New binaries and changes to supported environments](#binaries-and-supported-environments)
- [Change in behavior of the `-Djava.security.manager` system property for OpenJDK version 8](#change-in-behavior-of-the-djavasecuritymanager-system-property-for-openjdk-version-8)

- [Display of multiple warnings on loading the same agent restricted on AIX systems](#display-of-multiple-warnings-on-loading-the-same-agent-restricted-on-aix-systems)
## Features and changes

### Binaries and supported environments
Expand All @@ -42,6 +42,14 @@ From OpenJDK version 18 onwards, if you enable the `SecurityManager` at runtime

To resolve this issue, OpenJDK version 17 ignores these options and from 0.41.0 release onwards, OpenJDK version 11 also ignores these options. With this release, OpenJDK version 8 too ignores the `allow` and `disallow` keywords, if specified.

### ![Start of content that applies to Java 21 (LTS) and later](cr/java21plus.png) Display of multiple warnings on loading the same agent restricted on AIX systems

Earlier, for Java 21 and later, on OpenJ9&trade; supported operating systems other than AIX&reg; warnings were issued once when the agents are loaded dynamically into a running VM after startup without specifying the `-XX:+EnableDynamicAgentLoading` option and the same agents were loaded before.

Now, from 0.44.0 release onwards, AIX systems also can detect whether an agent was previously loaded or not if the agent was loaded through a platform-independent name or an absolute path to the platform-dependent library. Therefore, like other platforms, on AIX systems also, the warnings are issued only once for the same agent when the `-XX:+EnableDynamicAgentLoading` option is not specified.

For more information, see [`-XX:[+|-]EnableDynamicAgentLoading`](xxenabledynamicagentloading.md). ![End of content that applies to Java 21 (LTS) and later](cr/java_close_lts.png)

## Known problems and full release information

To see known problems and a complete list of changes between Eclipse OpenJ9 v0.43.0 and v0.44.0 releases, see the [Release notes](https://github.com/eclipse-openj9/openj9/blob/master/doc/release-notes/0.44/0.44.md).
Expand Down
6 changes: 2 additions & 4 deletions docs/xxenabledynamicagentloading.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,9 @@ These warnings are issued only once for the same agent when the `-XX:+EnableDyna

If the `-XX:+EnableDynamicAgentLoading` option is set, all agents that are dynamically loaded are considered as approved by the application owner, and therefore, no warnings are issued.

Eclipse OpenJ9&trade; supported operating systems other than AIX&reg; have APIs to determine whether the same agent was loaded before or not, even if an agent is loaded with a platform-independent name or an absolute path to the platform-dependent library.
Eclipse OpenJ9&trade; supported operating systems have APIs to determine whether the same agent was loaded before or not, even if an agent is loaded with a platform-independent name or an absolute path to the platform-dependent library.

AIX systems cannot detect whether an agent was previously loaded or not if the agent was loaded through a platform-independent name or an absolute path to the platform-dependent library. Therefore, on AIX systems, warnings are issued each time an agent is loaded dynamically through the Attach API (`VirtualMachine.loadAgentLibrary(agent)`) even if the same agent was loaded before through the command-line option (`-agentpath:/Absolute/Path/to/agentLibrary`) at startup.

A fix to restrict this display of multiple warnings on loading the same agent will be available in a later version of OpenJ9. ![End of content that applies to Java 21 (LTS) and later](cr/java_close_lts.png)
From 0.44.0 release onwards, AIX systems also can detect whether an agent was previously loaded or not if the agent was loaded through a platform-independent name or an absolute path to the platform-dependent library. Therefore, like other platforms, on AIX systems also, the warnings are issued only once for the same agent when the `-XX:+EnableDynamicAgentLoading` option is not specified. ![End of content that applies to Java 21 (LTS) and later](cr/java_close_lts.png)

## See also

Expand Down

0 comments on commit dedd9e2

Please sign in to comment.