Hi AEM Folks,
We are migrating the code into cloud compatible . While running the BPA in the existing instance, it is throwing the email@example.com issue in our code. we have implemented the sling scripting USE interface. Much appreciated if you share the replacement for javax.script
The javax.script the package provides a scripting framework in Java, and it is not recommended to use it in AEM because it can lead to security issues. Instead, Adobe recommends using the Sling Scripting APIs in AEM.
If you have implemented the Sling Scripting 'USE' interface in your code, you do not need to use the javax.script package. You can remove any references to it in your code.
@ManviSharma1999 -Thank you for the reply.
But the concern here is Sling scripting using javax.script while we implement into our class we need to import javax.script.Binding for init method. Pasted the screen
Hi @senthilkumarselvam ,
This seems to be a false positive and related to a bug with BPA in the past. This should have been fixed in this version Best Practices Analyzer 2.1.40
Can you check if you are using this version?
If the issue still exists, kindly open a support ticket.
Hope this helps!