Home > SAP FAQs > SearchSAP.com expert FAQ > SearchSAP.com FAQs > SAP Java FAQ > SAP Java FAQ > Why build a custom JCo repository?
FAQs: SearchSAP.com expert FAQ:
EMAIL THIS
 START   SEARCHSAP.COM FAQS   
SearchSAP.com FAQs


SAP Java FAQ
<< PREVIOUS | NEXT >>: Can JCo create an ABAP report in SAP?
 TIPS & NEWSLETTERS TOPICS 


Why build a custom JCo repository?


Austin Sincock
10.24.2003
Rating: -2.60- (out of 5)


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


Recently, I gave a Web seminar at SearchSAP.com detailing how to use the JCO API to build an outbound RFC server for SAP. Using a JCO server, you connect to external Java-based applications from inside any ABAP application. This technology provides a powerful and flexible means of extending your existing SAP implementation without a lot of costly adapters or long development cycles.

One of the most common questions I received after the seminar was "What the heck is a custom repository and why do I care about it?" This is a fair question and is one of the more confusing aspects of JCO server development.

Anyone familiar with building inbound connections to SAP with JCO knows that you must first retrieve a repository from SAP to get the metadata definition of the BAPI/RFC you wish to call. This repository contains all the structure/parameter definitions for RFC-enabled function modules in SAP. Obviously, for inbound calls, you need to use a repository to get back the function definition, otherwise you would be stuck using the JCO API to define these structures up-front, before even making the initial RFC/BAPI call.

However, building a JCO server is the reverse proposition. Rather than using a function module defined in SAP, you effectively define your own Java-based function module. Although not exactly parallel with SAP function modules, a JCO function relies on the same paradigm used by SAP, e.g. import/export parameters, structures, and tables. As such, you can define your JCO module as a shell RFC in SAP (defining parameters, etc. without any logic in the function), then use the SAP repository to retrieve the function definition on JCO server startup.

This process has two major drawbacks:
1) Repository overhead - Although slight, an SAP repository does occupy a certain amount of memory space when it is retrieved from SAP. When building a J...


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


<< PREVIOUS | NEXT >>: Can JCo create an ABAP report in SAP?
VIEW ALL IN THIS CATEGORY


RELATED CONTENT
Java/SAP development
How to provide an SAP R/3 4.5B application server with a Web service interface
Consuming a Web service from an SAP 4.6c R/3 application server
With Java development experience, should I go into SAP XI?
Answering basic BAPI questions
Viewing a list of SAP interfaces
Which SAP implementation phase is Java necessary for?
Interface a locally developed application with SAP
Should an ABAP professional know Java?
Storing SAP information from a JCo connector
Integrating SAP with C++, Java, and Powerbuilder on Sybase and Oracle DBs

SAP Java and J2EE
SAP CTO Sikka: SAP's innovation gets overlooked
SAP CTO expects today's SAP applications to be running in 2020
Tips on SAP ABAP
How to provide an SAP R/3 4.5B application server with a Web service interface
Consuming a Web service from an SAP 4.6c R/3 application server
SAP NetWeaver Configuration and Customization
Is C, C++ and Java knowledge required when learning SAP?
How to be a self-taught NetWeaver and ABAP expert
Getting started with a NetWeaver career
An ABAP user wants to learn XI

SAP interface technologies
SAP CTO expects today's SAP applications to be running in 2020
SAP TechEd 09 keynoters: Managing change today like trying to board a speeding train
SAP's Web 2.0 strategy makes way for social networking in business apps
Error when clicking the SAP GUI logon button
SAP applications demo: BP's key mapping
Viewing a list of SAP interfaces
Interface a locally developed application with SAP
Will there always be an implicit commit in an RFC?
Is there a way to search within IDocs using a purchase order number?
Configuring the JDBC Connector Service to perform database lookups

RELATED GLOSSARY TERMS
Terms from Whatis.com − the technology online dictionary
Application Link Enabling  (SearchSAP.com)
IDoc  (SearchSAP.com)
Remote Function Call  (SearchSAP.com)

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary


CO server, it is somewhat overkill to pull out the entire set of metadata definitions, when all you really need is a shell RFC interface that you defined in the first place.
2) Division of labor - As a Java developer, you may require more finite control over your JCO defined interfaces. Defining shell RFC interfaces forces you to update SAP anytime your Java function changes, including the appropriate transports, etc. to support these changes.

A custom JCO repository gives you better control over the interface definitions and reduces overhead on your JVM/Java application server. A custom repository contains only those interface(s) that are required by your JCO server. Instead of further explanation, here is an example of a custom repository:

This repository defines a very basic interface with import/export parameters and a structure definition for a table interface.

A custom JCO repository definitely gives you, as a Java developer, more control in the development effort. It can be included within your Javadoc generation in order to better document the development effort and can be updated to reflect the dynamic nature of Java development. Of course, the major disadvantage is that your ABAP developers would need to read the generated Javadocs when calling your JCO server from within SAP. However, I have always found it easier to deploy a development Web server with the appropriate Javadocs available to all developers than force my Java developers to log into SAP every time they needed to check/update and RFC interface definition.

Author Austin Sincock is a freelance Java/SAP consultant who contributes regularly to Web and print journals. He can be reached at austin@opensourceguru.com. Check out his book Enterprise Java for SAP


Rate this Tip
To rate tips, you must be a member of SearchSAP.com.
Register now to start rating these tips. Log in if you are already a member.




DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



NetWeaver SAP White Papers
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




All Rights Reserved, Copyright 2000 - 2009, TechTarget | Read our Privacy Policy
SearchSAP.com is a search service provided by TechTarget and is completely
independent of and not affiliated with SAP AG.
  TechTarget - The IT Media ROI Experts