The behavior for the toString() implementation for annotations changed in JDK 19, per my request to the JDK team (see link below). Specifically, since JDK 19, the toString() implementation for annotation proxies created by the JDK started using canonical names instead of binary names for types. See https://bugs.openjdk.org/browse/JDK-8281462