You need to sign in to do that
Don't have an account?
chiruganta
How to replace reserve keywords from JSON Response string?
Hi,
I need help on replacing reserved keywords with other values in my JSON response string. I have tried with replace and replaceAll methods, but I am getting error (System.LimitException: Regex too complicated) because of large JSON response.
Can someone help me on this issue?
I need help on replacing reserved keywords with other values in my JSON response string. I have tried with replace and replaceAll methods, but I am getting error (System.LimitException: Regex too complicated) because of large JSON response.
Can someone help me on this issue?
claper
can you place a sample JSON reponse? and how are you building the response? Thanks!
Austin G
The "regex too complicated" error is essentially a heap exceeded error, and is telling you that whatever regex you're using is causing the heap that supports the regex to exceed governer limits. In most cases i've experienced, and colleagues have experienced, the solution is to use a different integration approach. The other option is to break up the input and process each piece separately so you can use less heap memory, but depending on your specific case you may still hit the limits.