cancel
Showing results for 
Search instead for 
Did you mean: 

Error Occuring during DynamicConfiguration Mapping in UDF

Former Member
0 Kudos

Hello ,

I am trying to set the TO field of mail using dynamic configuration ,but when i test the mapping i am getting error as Java.lang.nullpointer exception.

When i checked the queues of mapping the result of UDF mapping is getting suppressed and as a result its not mapping to target field.(i am passing the value and returned the same value )

I am not able to pinpoint the error .

( i have set the ASMA properties in the mail adapter )

Replies will be appreciated

Rajesh

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

I know that and i ran end to end ,but after looking at trace found that the problem was with another mapping field and iam able to rectify it.

Former Member
0 Kudos

Hi Rajesh,

i am getting error as Java.lang.nullpointer exception.

for this error to solve in UDF i think this link will help u to solve that problem

http://docjar.org/docs/api/java/lang/NullPointerException.html

let me know what exact codeing have u done so that we can help u .......!

Regards

Aziz

Former Member
0 Kudos

String cons = "10001";

DynamicConfiguration conf = (DynamicConfiguration)container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);

DynamicConfigurationKey key = DynamicConfigurationKey.create("http:" + "/" + "/" + "sap.com/xi/XI/System/Mail", "THeaderTO");

conf.put(key, "XX.XX");

return cons;

I have used the above code and it is returning the error as mentioned above .

Rajesh

Former Member
0 Kudos

Hi Rajesh,

When we use dynamic configurations in Mapping, we can't test the mapping using TEST tab in Message mapping.

If you u try to do so, you will get the same Null pointer error.

If you want to test the message mapping using TEST tab, u have to remove the dynamic config mapping.

If you want to test the dynamic config, then run the end to end scenario.

Regards,

Monika