Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Exception while sync event

I'm trying to write a simple program that performs a generic sync and I keep getting the following error.

The backend method I'm trying to call requires no parameters and returns and outbound container with a few DESCRIPTION registers.

Exception while sync event processing: null (java.lang.RuntimeException)

The code that fires up the sync is:

ClassLoader cl = getClass().getClassLoader();

OpportunitySourceDAL ip = new OpportunitySourceDAL(); InboundProcessorRegistry.getInstance().register(ip);

OutboundContainerFactory outfactory = OutboundContainerFactory.getInstance();

outfactory = OutboundContainerFactory.getInstance();

OutboundContainer out = outfactory.createOutboundContainer(VisibilityType.SEPARATED, "ZLISTA_SOURCES_ALIAS" , OutboundContainer.TYPE_REQUEST);

out.close();

SyncManager.getInstance().synchronizeWithBackend(VisibilityType.SEPARATED);

And the class OpportunitySourceDAL has a process method like this

public void process(InboundContainer inbound) {

try {

OpportunitySource op = OpportunitySource.getInstance();

InboundContainerElement[] sources= inbound.getElementsWithFieldName("DESCRIPTION");

for (int i = 0; i < sources.length; i++)

op.add( sources.getFieldValue() );

} catch (Exception e) {

}

I've already created the wrapper for the backend function using ME_WIZARD and checked that it works with ABAP debugger.

The backend function is in the same machine as was so I don't have to map an RFC destination.

Am I missing some steps?

Thanks in advance.

Former Member
Not what you were looking for? View more on this topic or Ask a question