Topic
  • 4 replies
  • Latest Post - ‏2013-10-09T06:15:20Z by David07
YothA.
YothA.
2 Posts

Pinned topic Route http requests to different domains in DPA based on URI

‏2013-10-08T03:20:14Z |

Hi!

I am new in DPA development and need help with the following.

Scenario:

1. I have three application domains in DP and each domain hosts a different service:

       a. domain #1: router.bucs.com

       b. domain #2: dom.bucs.com

       c. domain #3: sem.bucs.com

I am using domain #1 (router,bucs.com) as the routing domain to route HTTP requests to the other two domains (dom.bucs.com and sem.bucs.com). Fir example: if the client types http://dphost:80/dom.bucs.com in browser, the request should be routed to a WSP (domservice)  in dom.bucs.com domain. If the client types http://dphost:80/sem.bucs.com in browser, the request should be routed to a WSP (semservice)  in sem.bucs.com domain. Basically, the routing is based on the first word (dom or sem) in the URL.

What is the simplest way of doing this?

 

Thanks

YA

  • David07
    David07
    73 Posts

    Re: Route http requests to different domains in DPA based on URI

    ‏2013-10-08T05:07:44Z  

    Hi Yotha,

    Your scenario can be acheived using Route action and a stylesheet. Set your back end type as dynamic and based on the incoming uri code your logic in the stylesheet.

    Refer the link,

    https://www.ibm.com/developerworks/community/forums/html/topic?id=1db74fae-6716-4f8e-94ad-b4b9ad227b5a&ps=25

    Change the manifest xml file depends upon your needs.

     

    Regards,

    David.

  • HermannSW
    HermannSW
    4874 Posts

    Re: Route http requests to different domains in DPA based on URI

    ‏2013-10-08T06:45:53Z  
    • David07
    • ‏2013-10-08T05:07:44Z

    Hi Yotha,

    Your scenario can be acheived using Route action and a stylesheet. Set your back end type as dynamic and based on the incoming uri code your logic in the stylesheet.

    Refer the link,

    https://www.ibm.com/developerworks/community/forums/html/topic?id=1db74fae-6716-4f8e-94ad-b4b9ad227b5a&ps=25

    Change the manifest xml file depends upon your needs.

     

    Regards,

    David.

    Just for completeness, If the routing decision is based on the input document (and not the URI), a XPath Routing map may be used:
    http://pic.dhe.ibm.com/infocenter/wsdatap/v5r0m0/index.jsp?topic=%2Fcom.ibm.dp.xi.doc%2Fcommandreference.xi502021.htm

  • YothA.
    YothA.
    2 Posts

    Re: Route http requests to different domains in DPA based on URI

    ‏2013-10-09T03:30:06Z  
    • David07
    • ‏2013-10-08T05:07:44Z

    Hi Yotha,

    Your scenario can be acheived using Route action and a stylesheet. Set your back end type as dynamic and based on the incoming uri code your logic in the stylesheet.

    Refer the link,

    https://www.ibm.com/developerworks/community/forums/html/topic?id=1db74fae-6716-4f8e-94ad-b4b9ad227b5a&ps=25

    Change the manifest xml file depends upon your needs.

     

    Regards,

    David.

    David,

    Thank you for your help, but I am very poor in DPA development, I am more into the infrastructure side, can you please modify the stylesheet and the route.xml file attached based on my requirement and attached to your reply. It will help me at lot. Attached are the route.xml and the stylesheet.

    Best,

    Attachments

  • David07
    David07
    73 Posts

    Re: Route http requests to different domains in DPA based on URI

    ‏2013-10-09T06:15:20Z  
    • YothA.
    • ‏2013-10-09T03:30:06Z

    David,

    Thank you for your help, but I am very poor in DPA development, I am more into the infrastructure side, can you please modify the stylesheet and the route.xml file attached based on my requirement and attached to your reply. It will help me at lot. Attached are the route.xml and the stylesheet.

    Best,

    Hi Yotha,

    I have attached the manifest file and routing xsl file. As per your scenario I edited the stuffs. Let me know in case of any issues.

     

    Regards,

    David.

    Attachments