cancel
Showing results for 
Search instead for 
Did you mean: 

Memory Error in RFC adapter

Former Member
0 Kudos

Hello experts;

We are developing a connection between sap PI and SAP ERP,

Whan we call the webservice in ERP from PI, a very large message is trasferred from ERP to PI (about 180 MB) thus, PI gives the following error:

-----------

358166K->358166K(524288K)], 6.2066662 secs] [Times: user=6.23 sys=0.00, real=6.21 secs]

   :    [4532]  11:17:49    ***ERROR (:0): OutOfMemoryError: Could not allocate 268435458 bytes (array length 2147483647)

java.lang.OutOfMemoryError: Requested array size exceeds VM limit

Dumping heap to OOM.hprof ...

Heap dump file created [5587903782 bytes in 389.418 secs]

Memory allocation error [OutOfMemoryError] occurred java.lang.OutOfMemoryError: Requested array size exceeds VM limit (failed to allocate 2147483664 bytes) (array length 2147483647)

-----------

Apparently  the root cause is the mathematical limit of a 32-bit signed integer (as pernote 1453829 wich talks a bout a similar issue in BO)

Questions:

1) ¿What is causing this error? The amount of lines in the mesage is about 1,2 million, very far from 2 billions.

2) ¿How can it be solved?  According to the developer he did not indicated the type of data in the array, ¿how can we change it to long integer?, that will most likely solve the probem.

Any ideas are greatly appreciated.

Best regards.

Ovidio

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

i think the problem is, that you may have 1,2 million entries/lines which require a lot of memory - each column in a table will require memory

Did you try to increase the available heap size for as java?

br

franz

Former Member
0 Kudos

Hi Franz, thank you for answering

Yes, initially the heap was at 2GB, which indeed did throw a different OOM.

After changing maxheap to 4 GB, we are experiencing  the error in the original post, later to discard a lack of heap we changed to 8 GB and later even to 14 GB, all with the same result.

Thank you for your help

Regards

Ovidio

Former Member
0 Kudos

Hi,

have you tried to increase Xms and permGen as well?

br

franz

Former Member
0 Kudos

Hi;

Yes, that was also tryed without sucess.

Regards.

Ovidio