To code or not to code …
… that is the question.
😕
After having read several posts in this area where people were struggling with using our generators I realized that we have plenty of How-To-Guides out that show how to generate OData services for SAP NetWeaver Gateway based on BW Easy Queries, RFC Function Modules, SPI objects but that there is no How-To-Guide out that simply shows how to actually develop a Gateway service.
While the generators are great for a lot of scenarios there will be scenarios that can be better tackled with plain ABAP code.
Knowing what is going on behind the scenes is also beneficial if it comes to troubleshoot generated code as well.
The first document of this series you can find here:
How to Develop a Gateway Service using Code based Implementation
The second document that explains how to handle $filter, $skip and $top can be found here:
How to develop query options for a Gateway Service using code based implementation
When developing it is always useful to test your services. Learn about the sample test cases delivered by SAP as of SP6
Best Regards,
André
Updates:
- 20.06.2013 added link to second document
- 21.06.2013 added link to document describing the sample test cases delivered by SAP as of SP6
Thanks for sharing Andre, this is helpful!
Well, well, well! Well written, well illustrated, and well done! This is real easy to follow and very easy to expand with other themes.
Thanks for your effort!
Great to see this sort of content appearing now, exactly what we've been asking for 🙂
Thanks.......Andre
Thanks for taking out the time and putting up a very helpful post Andre 🙂
Thanks a lot for sharing this Andre
Regards,
Vivek
Thanks Andre, nice stuff.
Warm Regards
Hemendra
Thanks a lot for sharing. 🙂
Hi Andre, thanks for the putting all stuffs at one place... 🙂
Hi, are there any references for implementing models in code (MPS)? Not only the service implementation (DPC).
Hi Daniel,
models you would rather create using the Service Builder or the OData Modeler in Web IDE.
Or are you looking for a special use case that cannot be modelled in SEGW?.
BR
Andre
Hi Andre,
Asume you have a proprietary "modeler tool" with a number of complex models. The model definitions and data retrieval is accessible by ABAP code.
The goal is to OData-enable these services. So you have many models in a (proprietary) format that could not be imported by Service Builder itself. And due to the complexity it is not an option to re-implement these models in Service Builder and maintaining them in both tools.
So I thought you could create an empty Service Builder project, let it create the classes and redefine methods in MPC_EXT and DPC_EXT classes. My problem is how the MPC-API works to create a kind of reader for my proprietary modeler tool.
How to retrieve data in DPC_EXT classes is documented. But how to add e.g. entities in MPC_EXT is not documented.
Could you help?
Thanks,
Daniel