cancel
Showing results for 
Search instead for 
Did you mean: 

RFC call ended with "Communication Failure" exception in Gateway Service testing?

Former Member
0 Kudos

Hi,

Our current Landscape of Gateway is "Central HUB Deployment" where all the Gateway Add-on's installed on Gateway Server. i.e. IW_FND, GW_CORE, IW_PGW and IW_BEP is also installed on Gateway System.

As IW_BEP is installed on Gateway System, we are doing gateway development in Gateway system itself by creating Remote-Enabled Function Modules in Backend ECC system if no standard BAPI or RFC function module is not available and if available using the standard itself.

In Gateway Development, we are using Remote option to access the Function Module and on top of those function modules/structures we are creating all the gateway services in SEGW T-code and registering the service by Selecting the Gateway System (GW_HUB system alias) and providing the Backend System alias in the followed pop-up where it asks for System Alias.

System Alias for Gateway system is : GW_HUB

System Alias for Backend system is : ECC


Now we are trying to test the service, getting the below error.


Can anyone please suggest me how to solve the above issue.


Thanks in advance.


Regards,

Ramana.


Accepted Solutions (1)

Accepted Solutions (1)

EkanshCapgemini
Active Contributor
0 Kudos

Hi Ramana,

The error is due to configuration of system alias. You need to check the Local App flag for the system alias that you are using to connect to backend.

I think following links will help you:

Regards,

Ekansh

Former Member
0 Kudos

Hi Ekansh,

Thanks for your reply. I have mentioned configured steps below. please suggest me where to change my configuration settings.

SAP Netweaver Gateway Connection Settings done in Central HUB system.

In our scenario, we are developing Gateway services in Central HUB where IW_BEP is also installed by calling Remote Function Calls from ECC Backend System.

Configuration on SAP NetWeaver Gateway System (IW_FND)

1. Manage RFC Destination

In the above path, we have created 2 RFC destinations with no Trust relationship.

  1. RFC Destination for Central Gateway HUB system – NGWCLNT110
  2. RFC Destination to Backend ECC System – ECCCLNT333

2. Manage SAP System Aliases

In the above path, we have created System Aliases for both Local Central Gateway HUB system and ECC Backend System.

SAP System Alias

Description

Local GW

For Local App

RFC Destination

Software Version

System ID

Client

WS Provider System

ECC

Alias for ECC

X

ECCCLNT333

ERP

ECC

333

LOCAL

Local System Alias

X

NONE

DEFAULT

       

Configurations on Business Enablement Provisioning (BEP)

In our landscape, both IW_FND and IW_BEP are installed on Central Gateway HUB system.

  1. 3. Manage RFC Destination

In the above path, we have created an RFC destination to Central Gateway HUB System i.e. NGWCLNT110

4. Manage SAP System Aliases

In the above path, we have created two Destinations. One is for ECC Backend system with RFC Destination and the other is for Central Gateway HUB system with RFC Destination.

Destination System

Client

System Alias

RFC Destination

ECC

333

ECC

ECCCLNT333

NGW

110

GW_HUB

NGW

I have done the above configuration settings and I have developed a gateway service using SEGW in Central HUB system. Now when I’m registering the service in SEGW, I’m choosing the Central Gateway HUB system (NGW) and registering the service by entering the Backend System Alias (ECC). But when I’m trying to Execute the Service I’m getting the below error.

I have seen the error in /IWFND/ERROR_LOG , there it’s showing that the destination is NONE because in SPRO we have checked “For LOCAL APP” checkbox for Backend system alias (ECC) because of which the above error is coming.

Please suggest me to solve the above error.

Regards,

Ramana.

EkanshCapgemini
Active Contributor
0 Kudos

Hi Ramana,

I do not see any problem in the config you stated above. This error of 'function call failed' is because of the system alias associated with the service.


I have seen the error in /IWFND/ERROR_LOG , there it’s showing that the destination is NONE because in SPRO we have checked “For LOCAL APP” checkbox for Backend system alias (ECC) because of which the above error is coming.

'For Local App' signifies that the IWBEP classes are at the local system(i.e. the Gateway system itself) for this system alias. This means that the gateway will look for the classes in the gateway system itself and while executing the method, it will call the RFC with the given destination. And this is the case in your scenario also because you have developed the service at the gateway system itself. Thus 'For Local App' checkbox needs to be checked for system alias ECC .

As you state that in the error log, it is showing that the destination is NONE. I think that you have used system alias LOCAL instead of ECC while associating the service with backend system. Please check the associated system alias. It should be ECC.

Former Member
0 Kudos

Hi Ekansh,

Thanks again.

I have maintained Backend ECC RFC Destination against Backend ECC System alias. but when we are testing the service, system automatically taking NONE as RFC destination because of "For Local App" flag was checked. Based this flag, In standard code itself it's taking NONE as RFC destination even though ECC RFC destination maintained against system alias.

Please see the standard code in class " /IWFND/CL_DESTIN_FINDER" method "GET_SYSTEM_ALIAS_INFO".

here SAP hard coded if "For Local App" is checked then RFC destination as NONE.

Please check this code and suggest me if further config needs to do.

Regards,

Ramana.

EkanshCapgemini
Active Contributor
0 Kudos

Hi Ramana,


I have maintained Backend ECC RFC Destination against Backend ECC System alias. but when we are testing the service, system automatically taking NONE as RFC destination because of "For Local App" flag was checked. Based this flag, In standard code itself it's taking NONE as RFC destination even though ECC RFC destination maintained against system alias.

Please see the standard code in class " /IWFND/CL_DESTIN_FINDER" method "GET_SYSTEM_ALIAS_INFO".

here SAP hard coded if "For Local App" is checked then RFC destination as NONE.

The method and the class you are referring is related to IWFND component. I checked this code, this code is used while finding the destination for the IWBEP classes. They have hard coded this destination to NONE because when you have checked the 'For Local App' flag which states that the IWBEP classes are at the same system. Thus RFC destination is not required.

Please don't get confused with the above RFC destination. This RFC destination is pointing to the system which has IWBEP classes and not to the system where your FM is.

To check the RFC destination which is pointing towards the ECC system for calling the FM, please put an external breakpoint in the GET_ENTITYSET method like below:

go to LO_DP_FACADE :

Go to MO_DEST.........

Here your system alias should be ECC in your case. I still doubt that you have mapped this to LOCAL. Please paste your screenshots. I still need the screenshot of the previous post which shows alias.

Regards,

Ekansh

Former Member
0 Kudos

Hi Ekansh,

Thanks once again for reply.

I got the solution by implementing the Enhancement-Spot "/IWBEP/ES_DESTIN_FINDER".

In this Spot, we have a method "/IWBEP/IF_DESTIN_FINDER_BADI~GET_RFC_DESTINATION" which contains Importing parameter IS_DEFAULT_SYSTEM_ALIAS_INFO where we can get the System Alias with RFC Destination and an Exporting parameter EV_RFC_DESTINATION which is default blank.

Here i have passed the RFC Destination and now it's working fine.

Thanks for your support.

Regards,

Ramana.

EkanshCapgemini
Active Contributor
0 Kudos

Hi Ramana,

Its good to hear that you made it work.

But still I would say that if the gateway configuration is correct and you have provided the correct system alias(Hub to Backend) at the time of registering the service, there is really no need of enhancing the standard code at all.

It would have been much better if you could have checked the associated system alias instead of passing the RFC destination directly in the enhancement implementation.

P.S.: you can check the system alias when you click the maintain button under service maintenance node in SEGW.

Regards,

Ekansh

Former Member
0 Kudos

Hi Ekansh,

Thanks for your support.

In SEGW, i have selected Gateway SYSTEM (NGW) for registering the Gateway Service and in the pop-up i have selected Backend ECC System Alias (ECC).

Actually, the Enhancement was already implemented without implementing the method because of which the method is not getting executed which causing blank in Destination field.

I think, i can try by deactivating the Enhancement so that that Enhancement-Spot will not be called and may be it takes through config of system alias.

Regards,

Ramana.

EkanshCapgemini
Active Contributor
0 Kudos

Yes this may be the cause. Please check and do inform us about result.

Former Member
0 Kudos

Hi Ekansh,

I have deactivated the implemented Enhancement-Spot i.e. BADI. Now it's working fine with the config whatever done in SPRO.

Thank you very much for your support.

Also please share some ideas regarding Workflow integration and config required and also regarding some useful tips or topics which will be used in Gateway Scenarios which will be used in Fiori or UI5.

Regards,

Ramana.

EkanshCapgemini
Active Contributor
0 Kudos

Hi,

Yes it should have worked as charm.

Since you got your problem resolved, Please close the discussion.

I have provided you links on this link

Regards,

Ekansh

Former Member
0 Kudos

Hi,



I CREATED ONE RFC FOR FETCHING DATA FROM   MULTIPLE TABLES.

RFC WORKING FINE, BUT I AM ACCESS RFC IN GATEWAY SERVICE IT SHOWING ERROR.

PLEASE RESOLVE MY  ISSUE AND GUIDE ME OTHER WAY TO  FETCH THE DATA FROM
MULTIPLE TABLES IN GATWAY SERVICE




Answers (0)