@Hi @lwang
Can you confirm if you are using AEM 6.5 with JDK 8 or JDK 11.
If you are using with JDK 11 you will need to ensure to add the below lines in the sling.properties file on your instance for sling.bootdelegation.sun property.
File before update: sling.bootdelegation.sun=sun.*,com.sun.*
After update: sling.bootdelegation.sun=sun.*,com.sun.*,jdk.internal.reflect,jdk.internal.reflect.*
Also you can include the below snippet to your JVM parameters in the start.bat(Windows) or start.sh(Mac OS/Linux) file based on the OS.
-XX:+UseParallelGC --add-opens=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED --add-opens=java.base/sun.net.www.protocol.jrt=ALL-UNNAMED --add-opens=java.naming/javax.naming.spi=ALL-UNNAMED --add-opens=java.xml/com.sun.org.apache.xerces.internal.dom=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/jdk.internal.loader=ALL-UNNAMED --add-opens=java.base/java.net=ALL-UNNAMED -Dnashorn.args=--no-deprecation-warning
Also allow enough heap memory something like 2048 MB or 4096 MB.
It will become something like:
CQ_JVM_OPTS='-server -Xmx4096m -XX:MaxPermSize=256M -Djava.awt.headless=true -XX:+UseParallelGC --add-opens=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED --add-opens=java.base/sun.net.www.protocol.jrt=ALL-UNNAMED --add-opens=java.naming/javax.naming.spi=ALL-UNNAMED --add-opens=java.xml/com.sun.org.apache.xerces.internal.dom=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/jdk.internal.loader=ALL-UNNAMED --add-opens=java.base/java.net=ALL-UNNAMED -Dnashorn.args=--no-deprecation-warning'
Please refer the Java 11 consideration section in the below article:
https://experienceleague.adobe.com/docs/experience-manager-65/deploying/deploying/custom-standalone-...
Hope this will help you!
Thanks!