Layer7 API Management

Expand all | Collapse all

Hello All,

  • 1.  Hello All,

    Posted Jun 25, 2015 04:09 PM

    Earlier we have forum systems which we have many hosts like (abc.com,bcd.com) like that and we were assigning each host to different webservices.

     

    https://abc.com/service?wsdl

    https://bcd.com/home?wsdl

     

    But now after i did the webservice configuration in Layer7 i am able to access all webservices with any host. There is no restriction. But i need hostname restrction to particular services.

     

    Kindly suggest on this.

     

    Thanks&Regards

    Rajasekahar



  • 2.  Re: Hello All,

    Broadcom Employee
    Posted Jun 26, 2015 01:03 AM
      |   view attached

    Rajasekahar,

     

    The objective you have outlined should be able to be addressed by creating a global policy - message received and using the resolve service assertion. I've attached a document that should help with this as it outlines the ground work for matching inbound conditions to services and then if nothing matches then decide on the customer experience (Drop, Throw error, 404, etc)

     

    Sincerely,

     

    Stephen Hughes

      CA Technologies
    Director, CA Support



  • 3.  Re: Hello All,

    Posted Jun 26, 2015 07:07 AM

    Hi Stephen Hughes,

     

         Thank you so much for your reply.

     

         I have created one global policy - message received which is restricting internal host and external host like within company employees will access internal.com URLs and outside of the users will access external.com URLs. Layer7 is not allowing more than one global policy - message received.There are many hosts like 10 hostnames. each one is having diffrent names.

     

    Strange thing I have configured context variable for one of the webservice alone to restrict particular host it works for me when we validate in soapui tool but i am able to access all hosts with same service in browser.

     

    Unable to find your attachment.

     

    Please help on this.

     

    Thanks &Regards

    Rajasekhar



  • 4.  Re: Hello All,

    Broadcom Employee
    Posted Jun 26, 2015 02:56 PM
      |   view attached

    Rajasekhar,

     

    You don't need to use more than one global policy just need to have branches that test for the various hostnames. The attachment should show as paperclip and note on the comment I added. For when nothing else matches resolve to a service that is a catch all that can respond with what you are looking for. I've attached a sample policy that outlines what I was outlining.

     

    Sincerely,

     

    Stephen Hughes

      CA Technologies
    Director, CA Support

    Attachment(s)

    zip
    resolve_service.xml.zip   649 B 1 version


  • 5.  Re: Hello All,

    Posted Jun 26, 2015 03:39 PM

    I am really sorry Stephen,

     

    I might checking wrong way or something else but i am unable to find out the attachment. Its not showing any paperclip.



  • 6.  Re: Hello All,

    Posted Jun 26, 2015 03:56 PM

    Hi Stephen,

     

         I got the attachments now. Will try and let you know soon

     

    Thank&Regards

    Rajasekhar



  • 7.  Re: Hello All,

    Posted Jun 26, 2015 04:16 PM

    Hi Stephen,

     

         Again its not working. Let me brief you what exactly i am doing.

     

    1. One of the backend service i did the onboarding which is like https://abc.alpha.com:543/ws/Collaboration_MS008983Port?wsdl

    2. I am having 10 host entries like abc.n.com, bcd.h.com,xyz.b.com.....etc

    3. Service working in browser with all above hostnames which was not the same when the webservices were there in Forum Sentry.

    4. Onemore thing i am doing some naming convention for each webservice after i did the onboarding in Layer7  like https://abc.n.com/Collaboration-Test?wsdl if it is test URL.

    5. I need only one host has to repond other all should fail.

     

    I hope this will clear you.

     

    Thanks& Regards

    Rajasekhar



  • 8.  Re: Hello All,

    Broadcom Employee
    Posted Jun 26, 2015 04:38 PM

    Rajasekhar,

     

    Okay I think the confusion is around what is inbound to the Gateway and what is outbound from the Gateway to the back-end service. Please log a case with api-support@ca.com as I believe a WebEx is required to determine the best solution.

     

     

    Sincerely,

     

    Stephen Hughes

      CA Technologies
    Director, CA Support



  • 9.  Re: Hello All,

    Posted Jun 26, 2015 04:57 PM

    Hi Stephen,

     

        If i am not wrong for configuring the service with specific to the host i am not thinking about the inbound or outbound. Everything we did with Port based configuration and final step we did 10 hostnames pointed to Layer7 gateway IP.

     

    I will try to log a case

     

    Thanks&Regards

    Rajasekhar



  • 10.  Re: Hello All,

    Posted Jun 26, 2015 04:41 PM

    Hi Rajasekhar,

     

    Are all the 10 hostnames pointing to the same Layer7 Gateway? I think the Internal Virtualization instructions provided by Stephen should work. In the Global policy, you will compare the host name and then do a resolve URI to the specific policy corresponding to that host name.

     

    Pseudo code would be like this -

    Compare ${request.url.host} is equal to abc.n.com

    Resolve Service with URI /abcapi (Service specific to abc.n.com)

     

    Compare ${request.url.host} is equal to bcd.h.com

    Resolve Service with URI /abcapi (Service specific to bcd.h.com)

     

    Let me know if this meets your requirement.

     

    Thanks,

    Atul



  • 11.  Re: Hello All,

    Posted Jun 26, 2015 04:53 PM

    Thanks Atul,

     

    Are all the 10 hostnames pointing to the same Layer7 Gateway?

     

    Yes,All hostnames pointed to same Layer7 Gateway.

    Onething i can confirm you, I am not able to invoke the webservice with all hostnames in SOAPUi tool but when i try in browser i am able to access with all hostnames.

     

    Resolve Service with URI /abcapi (Service specific to abc.n.com)

     

    Please let me know what is URI /abcapi here, is this Service name which i will be going to use in SOAPUi or Browser? If yes, again one more problem i am having 100 services with different namings i cant use like this and also Each host having 10 to 15 services.

     

    Thanks&Regards

    Rajasekhar



  • 12.  Re: Hello All,

    Posted Jun 26, 2015 05:20 PM

    Hi Rajasekhar,

     

    This is the global policy that I was talking about -

    MessageReceived.JPG

    I guess its better to go with what Stephen mentioned - open a case with apisupport and do a screen sharing.

     

    Thanks,

    Atul



  • 13.  Re: Hello All,

    Posted Jul 07, 2015 10:55 AM

    Thanks Atul,

     

    Sorry for the delay reply. I was busy with other configurations. As per you both suggestions i will open case and will work with them