cancel
Showing results for 
Search instead for 
Did you mean: 

One Interface - Two different maps - How to define which mapping to execute

Former Member
0 Kudos

Hi all,

I have created a SalesOrderCreate soap interface to BAPI_SALESORDER_CREATE to create SalesOrders on ECC600 from a legacy application. Now I have another legacy app that needs to create SalesOrders, but with some different mapping rules, using the same bapi.

The first think I thought was to create another soap interface. But the principle of Enterprise Services is to use only one interface for each service (so, I was supposed to use the same soap interface). Then I have one soap interface and two different message mappings to the same BAPI.

The question is how can I define that when the message comes from legacy "A" the mapping "A" would be executed, and when the message comes from legacy "B", the mapping "B" would be executed.

Thanks!

roberti

Accepted Solutions (1)

Accepted Solutions (1)

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

>>>> But the principle of Enterprise Services is to use only one interface for each service (so, I was supposed to use the same soap interface).

the concept of Enterprise Services is as you say

but in your case it means that you need to use the same mapping... <-- as it's a part of your WS!

you need to use the same soap interface without any changed inside it

(in your case inside your mappings)

if you want to reuse your first interface you can do this:

- create another soap interface from second legacy to first soap interface

(there you can use another mapping)

this way you will reuse your previous work

this is Enterprise Services concept and not changing

web service logic (in this case mapping) for every new system

Regards,

michal

-


<a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

Former Member
0 Kudos

It seems you're rigth michal,

my problem started when the first inbound message interface does not have some fields needed to the second legacy. Then my first try was to change the message interface creating the fields to attend both legacy systems and find a way to keep the first mapping. I will spend a little more time modeling the messages and I will make the reuse as you said. Thanks a lot!

roberti.

MichalKrawczyk
Active Contributor
0 Kudos

no problem

these are two principles of ESA web services:

- don't change the interface

- reuse already existing

Regards,

michal

Former Member
0 Kudos

Yes, you're right

The problem is when the existing ones are not so well modeled... But we are learning, and it's a good start

Thanks again!

roberti

MichalKrawczyk
Active Contributor
0 Kudos

no problem

Regards,

michal

Answers (1)

Answers (1)

Former Member
0 Kudos

sorry,didnt read ur question properly

thanx

ahmad

Message was edited by:

Ahmad