Layer7 API Management

 View Only
Expand all | Collapse all

AngularJS application through layer 7 url

  • 1.  AngularJS application through layer 7 url

    Posted Oct 15, 2019 01:27 PM
    Hi,
    is it possible to set up a policy for AngularJS web application.

    i have a web application url for angularjs https://visualizer-dev.apps.com

    when i hit the this url i am getting response but when i hit through later 7 url in chrome then i  see blank page. can you please provide any suggestions to implement this scenario.

    Thanks,
    Sri


  • 2.  RE: AngularJS application through layer 7 url

    Posted Oct 15, 2019 03:01 PM
    Hi.

    if I understood correctly, you want to access a published web application thru gateway. It can be accomplished with a Reverse Web Proxy . 

    If you are having problems consuming APIs, probably you need to implement CORS


    Best regards

    ------------------------------
    Sr. Consultant Services
    HCL Enterprise Studio
    ------------------------------



  • 3.  RE: AngularJS application through layer 7 url

    Posted Oct 16, 2019 12:15 AM
    Thank you Leandro.

    i created a policy using Reverse Web Proxy. when i hit layer 7 url from chrome, it is not displaying the web page.it showing blank page. Can you please suggest what went wrong here. 

    Reverse Web proxy

    Thanks,
    Sri



  • 4.  RE: AngularJS application through layer 7 url

    Posted Oct 17, 2019 11:40 PM
    Hi Leandro,
    do you have any example for this requirement?

    Thanks,
    Sri


  • 5.  RE: AngularJS application through layer 7 url

    Posted Oct 16, 2019 01:33 AM
    Hi,

    Have you ensured that you have added the certificate for https://visualizer-dev.apps.com in your trust store? (Manage Certificates).
    An empty response from a Route Via HTTP  is a classic symptom of a missing Certificate trust.

    Regards

    Vince

    ------------------------------
    Senior Architect
    Apiida AG
    Https://www.apiida.com
    ------------------------------



  • 6.  RE: AngularJS application through layer 7 url

    Posted Oct 16, 2019 09:05 AM
    HI Vince,
    thanks for your response.
    yes cert is already imported but still failing and showing blank response. when i opened developer tools in in chrome then it shows 500 errors like below.



    Thanks,
    Sri


  • 7.  RE: AngularJS application through layer 7 url

    Posted Oct 17, 2019 02:59 AM

    OK, then it's "Service Debugger" time then.

    This way you can see the request and response.



    ------------------------------
    Senior Architect
    Apiida AG
    Https://www.apiida.com
    ------------------------------



  • 8.  RE: AngularJS application through layer 7 url

    Broadcom Employee
    Posted Oct 17, 2019 07:16 PM
    Hello Sri,
    Since you open the web debug console of the browser, can you show the (error) messages on the Console tab? It should provide some clues of the problem.
    I suspect it should be due to CORS, as mentioned by Leandro.

    Regards,
    Mark


  • 9.  RE: AngularJS application through layer 7 url

    Posted Oct 17, 2019 02:13 PM
    Hi Vince,
    when debug using service debugger it says policy is successful. when i hit layer 7 url, it is throwing blank page. i have attached screen shot in earlier comments.

    Thanks,
    Sri


  • 10.  RE: AngularJS application through layer 7 url
    Best Answer

    Posted Oct 17, 2019 02:44 PM

    You need to set a break point before the Route via HTTP assertion and step into it. Then when assertion had completed and returned a response..  take a look at that response in the pane below. If there's a response then keep stepping into it to see where it's being stripped.

    If no response from the first reply from the backend then the problem must be with the backend I believe.



    ------------------------------
    Senior Architect
    Apiida AG
    Https://www.apiida.com
    ------------------------------



  • 11.  RE: AngularJS application through layer 7 url

    Posted Oct 17, 2019 10:30 PM
    Thank you Vince and Zhijun.

    when hit back end alone, i am getting response and attaching the page for your reference and attaching console output also from chrome.