cancel
Showing results for 
Search instead for 
Did you mean: 

No instances can be created from abstract classes

Former Member
0 Kudos


Dear SAPGurus,

I have developed a oData Service in my backend system & able to register the service in the gateway hub system. When i try to execute the metadata of the service from gateway system i am able to see the metadata with list of entity types availble in the data model.

But when i try to execute with entity set i am getting the following error.

"The class 'ZCL_ZGRC_DATA_MODEL_DPC' is abstract. No instances can be created from abstract classes."

Where my data model provider class name is  'ZCL_ZGRC_DATA_MODEL_DPC'

Kindly help me.

Thanks & Regards,

Rumeshbabu S

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Dear Ashwin,

I have used GW Service Builder Tool.

Thanks,

Rumeshbaabu S

AshwinDutt
Active Contributor
0 Kudos

Hello Rumesh,

When GW builder itself is creating objects ideally such error should not come as per my knowledge.

Kindly try regenerating run time objects once again and check.

Regards,

Ashwin

Former Member
0 Kudos

Dear Ashwin,

I tried, but getting the same error.

This external service is registered in gateway system which connects to backend system through RFC.

Is there any seperate settings required ?

Thanks & Regards,

Rumeshbabu S

AshwinDutt
Active Contributor
0 Kudos

Hello Rumesh,

I don't see any other settings to be done here.

Could you please share the system alias setting maintained in SPRO ?

Regards,

Ashwin

AshwinDutt
Active Contributor
0 Kudos

Hello Rumesh,

U have created service using service builder in gateway system and registered there only correct ?

OR

U have created service in ECC system and then registration is done in GW system ?

Regards,

Ashwin

AshwinDutt
Active Contributor
0 Kudos

Hello Rumesh,

I do not think the error which u are getting is because of System Alias setting in SPRO.

Its something else which is really strange.

However the below is the setting to be maintained in GW SPRO system alias when u have a environment setup like u have now.

I mean the way u have created service and registered -

In ECC system u have created service using builder.

In GW system u have registered it and trying to access now via an RFC destination.

We have the same setup like u have now and we do not have any issues. We have also maintained the System Alias like i have shared in screen shot.

Check your System Alias config once in SPRO. But i dont think this is causing problem in your case. Still check once.

As per my understanding, from GW its trying to hit the DPC class and hence i feel system alias setting is correct in your case.

Problem is something else which is really strange.

Check error logs and see if it can. Share the error log please.

Regards,

Ashwin

Former Member
0 Kudos

Many thanks Ashwin for your response.

The problem is solved.

I have assigned the data provider class for the data model **CLASS_NAME**_DPC in SPRO settings (Maintain Services) instead the extended version ***CLASS_NAME**_DPC_EXT and which is wrong. The correct one should be the extended version of the data provider class.

AshwinDutt
Active Contributor
0 Kudos

Hello Rumesh,

Glad to hear that issue got resolved.

But one thing here , Maintaining Technical Model & Technical Service in SPRO is a part of Runtime Object Generation itself when you use GW Service Builder.

GW Builer itself will assign Tech Model Name to you Model Class & Tech Service Name to your Data Provider Class.

Finally these Tech Model & Tech Service are linked.So we need not to do any changes here.

Looks like You had done some changes there, but we need not to change anything there  as GW will take care of that

Regards,

Ashwin

Former Member
0 Kudos

Dear Ashwin,

Yes your correct, i was searching for some way to register the service from backend to gateway system.I made some changes manually in assigning DPC to a service then i forget to revoke back to standard.

But vey likely i am able to fiound this strange issue.

Thanks for your prompt response.

Thanks & Regards,

Rumeshbabu S

Answers (1)

Answers (1)

AshwinDutt
Active Contributor
0 Kudos

Hello Rumesh,

U have created Model Class and Data Provider Class using code based implementation is it?

OR u have used GW Service Builder tool ?

If its a manual code technique,

What classes u have inherited ??

We inherit the below classes when we create services via code based implementation.

For DPC - /IWBEP/CL_MGW_PUSH_ABS_DATA

For MPC - /IWBEP/CL_MGW_PUSH_ABS_MODEL

Please check the above points.

Regards,

Ashwin