cancel
Showing results for 
Search instead for 
Did you mean: 

encode to base 64 in file adapter

Former Member
0 Kudos

HI all,

we are getting zip file in receiver file adapter,how can i encode it to base 64 format.plz see the screen shot of module

thanks in advance

regards

Siva

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Siva,

   From the screen shot shared its clear that you are using a File Adapter along with the PayloadZip Bean, in this the TextCodepageConversion Module might come into use to convert it into base 64.

Please go through the below two links:

1. Page 5 of http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/502991a2-45d9-2910-d99f-8aba5d79f...

2. http://help.sap.com/saphelp_nw04/helpdata/en/45/da2deb47812e98e10000000a155369/content.htm

Former Member
0 Kudos

I like this idea Tilak, does it work? (Have you tried it with Base64?)

Siva, please let us know how you get on, and what solution you chose. This requirement is getting more common.

baskar_gopalakrishnan2
Active Contributor
0 Kudos

You can do java  mapping  or UDF to encode the base 64. That's one simple approach. You might want to check SCN for the base 64 encoding or refer the link below

http://www.wikihow.com/Encode-a-String-to-Base64-With-Java

Former Member
0 Kudos

HI krishna,

we are not using any mapping we are picking 3 files zip and encode.this is our requirement

regards

Siva

udo_martens
Active Contributor
0 Kudos

Hi Siva,

if you dont want to encode in mapping time you have to develope an own adapter module doing that.

Regards,

Udo

Former Member
0 Kudos

You could also do this with a command line in the file adapter. There are many small base64 encode / decode programs to use depending on your operating system.

Or, a simple Java program could do. I added this as an enhancement idea at ideaspace. Please vote for it if you would like this as standard functionality in PI Adapter Modules...

https://ideaplace.brightidea.com/ct/ct_a_view_idea.bix?idea_id=41C7794F-AF89-4913-A7CD-A7513A097055

former_member207622
Contributor
0 Kudos

Hi Siva ,

You can also try with the adapter module as per below blog

http://scn.sap.com/people/farooq.farooqui3/blog/2008/09/24/sap-xipi-encode-outgoing-payload-using-ad...

Thanks

Ninad Sane

Former Member
0 Kudos

Ninad, this seems to be the best overall approach today, but many people don't want to deal with creating the Java packages and deploying them into the PI server for adapter modules. This is why I think SAP should add to their standard adapter module offerings as mentioned in my post above. Please vote for it there if you agree.