Jump to content
We've recently updated our Privacy Statement, available here ×
  • VisualizeJS troubleshooting


    Badr Draifi
    • Features: JasperReports Server Version: v8, v7 Product: JasperReports® Server

    VisualizeJS CORS issues can be overwhelming and difficult to debug. This article provides some ordered steps that you can follow to help debug the issue : 

     

    1. The first thing to start with is to ensure that the domain calling your JRS from VisJS is on the domainWhiteList profile attribute in Server settings. If it’s not, add it as : domainWhiteList1, domainWhiteList2…. the value must be equal to the origin value in the cors browser error. 
    2. Make sure there's no other CorsFilter in Tomcat/JRS web.xml
    3. Make sure that the headers is sending are on the allowed headers and OPTIONS method is allowed in AppContext-security-pro-web.xml
    4. If using a Proxy, make sure the proxy is allowing the HTTP OPTIONS method. 
    5. Enable logging for the Spring’s default CORS filter :
    • Open <path-to-tomcat>/webapps/jasperserver-pro/WEB-INF

     /log4j2.properties file and Add next lines (somewhere below root logger definition rootLogger.level=ERROR or in the end of the file):

    • logger.defaultCorsProcessor.name=org.springframework.web.cors.DefaultCorsProcessor
    • logger.defaultCorsProcessor.level=TRACE
    • logger.defaultCorsProcessor.appenderRef.stdout.ref=stdout
    • logger.defaultCorsProcessor.appenderRef.rolling.ref=fileout

     

    Also, try testing your calls from outside via Jsfiddle or a standalone HTML page to check if the issue is coming from the client app or the Server/Proxy area. 


    User Feedback

    Recommended Comments

    There are no comments to display.



    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now

×
×
  • Create New...