cancel
Showing results for 
Search instead for 
Did you mean: 

Error in adapter specific message attributes

former_member192892
Active Contributor
0 Kudos

Hi guys,

I'm trying to dynamically assign a destination directory name by using the code..

DynamicConfiguration conf = (DynamicConfiguration) container

.getTransformationParameters()

.get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);

DynamicConfigurationKey key = DynamicConfigurationKey.create(

“http:/"+"/sap.com/xi/XI/System/File”,

“Directory”);

String valueNew = "MyDirectory";

conf.put(key, valueNew);

I'm getting a null pointer exception when i test this. When i tried to debug i found that my DynamicConfiguration object conf is null...

Can anyone tell me why is this happening???

Accepted Solutions (0)

Answers (2)

Answers (2)

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

1. did you use the code from this blog:

/people/william.li/blog/2006/04/18/dynamic-configuration-of-some-communication-channel-parameters-using-message-mapping

2. you do have SP14 for XI 3.0 right ?

Regards,

michal

former_member192892
Active Contributor
0 Kudos

Hi Michal, I'm not sure about the service pack, but I have the check box for use Adapter Specific Message Attributes in my file communication channel. Also in my message mapping, the button "Edit Java Section" is also enabled. I think this functionality is kinda latest...

Thanks

Varun

prateek
Active Contributor
0 Kudos

Have u imported this

Imports: com.sap.aii.mapping.api.DynamicConfigurationKey;com.sap.aii.mapping.api.DynamicConfiguration;

Also just a try. Remove all spaces, if any, from ur code.

e.g. "(DynamicConfiguration) container"

Regards,

Prateek