Skip to Content

This weblog presents one of the ways to push data from XI to controller part of MVC architectured J2EE application where servlet acts as a controller. We use XI’s HTTP receiver adapter to achieve this. In a complex scenario the servlet plays quite a significant role naming few are Action Mapper, Dispatcher, request binder etc. Hence with the proposed scenario we can remove View part of the application for few of the instances and inturn reduce navigation. Another way to invoke a J2EE application is by using Java Proxies.


Scenario:


Actors in this scenario are Legacy system (LS) and MVC architectured J2EE application. LS uses XI Http receiver adapter to push request to the controller of the J2EE application (Servlet in this case). The request is carried all the way to the controller by passing view and then some server side process manipulates the data and sends it back (In this case, the servlet adds Salutation to the name).


image

Fig 1.0 Legacy Applicaiton Invoking J2EE Applciaiton using HTTP Adapter


Sequence of Steps:


Design Time


  • Create the required Design time objects like Data Types, Message Types, Message Interfaces
  • Create the required Message Mappings


image

Fig 2.0 Request Message Mapping


image

Fig 3.0 Response Message Mapping

    1. Create the required Interface Mappings


image


image

Fig 4.0 Interface Mapping


Develop and deploy servlet


Configuration time:


image

Fig 5.0 Configuration of HTTP Receiver adapter to invoke J2EE Applicaiton

    1. Create the required Configuration time Objects like Receiver Determinaiton, Inaterface determinaiton and mapping, Receiver agreement.


image

Fig 6.0 Configuration Objects in Integration Directory


Testing:


You can use a Client http adapter to test the scenario.


Result:


You should now be able to push data using XI’s receiver HTTP adapter to the controller  MVC architectured J2EE application.


To report this post you need to login first.

3 Comments

You must be Logged on to comment or reply to a post.

  1. Former Member
    Hi
    I have tried with your blog. Really nice one, very helpful. But i have some queries:
    1. How to generate vendor specific XML file. I am
       using Tomcat5.0 and Myeclipse for developing
       application.
    2. Xi picks up file from my source but how to
       retrieves the info from request object. I 
       just need to display the XML in browser. How to
       that.
    Please help
    Hoping aquick response
    (0) 
    1. Former Member
      Hi Siva,
      I have this scenario from Legacy to XI to external app server.I have a test jsp to execute that functionality .Its a jsp which has 1 textarea named “text” and when I click on the submit buton I get a response back.This way I am able to test this independently.Now from XI when I am executing my scenario I am getting status code ‘1250’ and message as ‘ http request(test) is null’.Now in the scenario in http adapter I just provide the target host : ip of server ,
                  service number : port no ,
                  path: the container or the request handler. But this scenario fails and gives me the above erroneous response.Now Basically I am not able to get how to send the value to the textarea “test”? please provide help as soon as possible.Do we have to put the name of the jsp in the “path” in http adapter and use prolog as test=.I tried this but it doesnt work.So please provide help on this as soon as possible.
      (0) 
  2. Former Member
    Hi Siva,
    I have deployed my EAR file on Weblogic App server.
    I am getting “Fatal error:Premeture end of file” in Weblogic server’s console.
    What went wrong
    Help me
    Thanks
    (0) 

Leave a Reply