https://raw.githubusercontent.com/ajmaradiaga/feeds/main/scmt/members/sap-mentors/MortenWittrock.xml SAP Community - Morten Wittrock 2024-10-06T00:10:04.662509+00:00 python-feedgen Morten Wittrock in SAP Community https://community.sap.com/t5/technology-q-a/re-understanding-term-message-payload-and-the-modification-of-it/qaq-p/12784188/comment-id/4799780#M4799780 Re: Understanding term message payload and the modification of it? 2023-12-18T15:25:26+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi Johannes</P><P>Message payload and message body are the same thing.</P><P>Static and dynamic payload is not a distinction I'm familiar with. When you use a Content Modifier step to update the message body, you can configure whether or not Simple expressions should be evaluated in your payload or not. I guess you might think of that as static and dynamic payloads, but only in the particular context of the Content Modifier updating the message body.</P><P>Regards,</P><P>Morten </P> 2023-12-18T15:25:26+01:00 https://community.sap.com/t5/technology-q-a/re-understanding-term-message-payload-and-the-modification-of-it/qaq-p/12784190/comment-id/4799782#M4799782 Re: Understanding term message payload and the modification of it? 2023-12-18T20:51:46+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi <SPAN class="mention-scrubbed">shogun777</SPAN> </P><P>Yes, you can set the payload with a Groovy script, if that makes more sense in your particular situation. Use the Message.setBody method in the script to update the payload. See the example <A href="https://help.sap.com/docs/cloud-integration/sap-cloud-integration/read-and-modify-message-header-message-body-and-exchange-properties?q=setbody" target="_blank" rel="noopener noreferrer">here</A>.</P><P>Regards,</P><P>Morten</P> 2023-12-18T20:51:46+01:00 https://community.sap.com/t5/technology-q-a/re-difference-between-sap-cloud-platform-integration-cpi-and-sap-cloud/qaq-p/12815313/comment-id/4812363#M4812363 Re: Difference between SAP Cloud Platform Integration(CPI) and SAP Cloud Integration(CI) 2023-12-25T14:08:00+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi Yuya</P><P>Yes, SAP Cloud Platform Integration (often abbreviated to CPI) is the same product as SAP Cloud Integration; only the name has changed. In 2021, SAP Cloud Platform was rebranded as SAP Business Technology Platform and therefore the SAP Cloud Platform Integration name no longer made sense.</P><P>Regards,</P><P>Morten </P> 2023-12-25T14:08:00+01:00 https://community.sap.com/t5/technology-q-a/re-difference-between-sap-cloud-platform-integration-cpi-and-sap-cloud/qaq-p/12815315/comment-id/4812365#M4812365 Re: Difference between SAP Cloud Platform Integration(CPI) and SAP Cloud Integration(CI) 2023-12-26T16:11:14+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi <SPAN class="mention-scrubbed">koide_yuya</SPAN> </P><P>Best of luck with the certification.</P><P>Regards,</P><P>Morten</P> 2023-12-26T16:11:14+01:00 https://community.sap.com/t5/technology-q-a/re-cpi-sap-integration-suite-file-transfer-from-folder-to-sftp-server/qaq-p/12687376/comment-id/4760472#M4760472 Re: CPI ? SAP Integration Suite file transfer from folder to SFTP server 2023-12-26T16:14:06+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi <SPAN class="mention-scrubbed">stefsnijders</SPAN> </P><P>The Edge Integration Cell file adapter is still on the roadmap. It's scheduled for Q2 2024 at the moment. You can find the roadmap entry <A href="https://roadmaps.sap.com/board?PRODUCT=000D3A47875C1EDB98A8A910864AC24B&amp;q=file&amp;range=CURRENT-LAST#;INNO=31F8B05650641EDDA39CFEFD2E2DB671" target="_blank" rel="noopener noreferrer">here</A>.</P><P>Regards,</P><P>Morten</P> 2023-12-26T16:14:06+01:00 https://community.sap.com/t5/technology-blogs-by-members/generative-ai-and-sap-cloud-integration/ba-p/13572030 Generative AI and SAP Cloud Integration 2023-12-27T16:14:31+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P style="overflow: hidden;margin-bottom: 0px"><IMG class="migrated-image" src="https://community.sap.com/legacyfs/online/storage/blog_attachments/2023/12/robot.jpg" /></P><BR /> 2023 has been the year of AI and of generative AI in particular. AI is not a new topic, of course. In fact it’s quite old. But since OpenAI launched ChatGPT in November of 2022, the pace of innovation in AI has gone through the roof with no sign of slowing down any time soon.<BR /> <BR /> So it probably didn’t come as a huge surprise, when Jürgen Müller announced in his SAP TechEd 2023 keynote, that SAP is embedding generative AI into SAP Integration Suite.<BR /> <BR /> (I’m going to refer to generative AI as GenAI in the rest of this blog post.)<BR /> <BR /> One of the areas where GenAI is making a huge impact is coding assistants. That is, an AI copilot that assists developers by generating code, documentation etc. We don’t yet know the details of how SAP intends to embed GenAI into SAP Integration Suite, but an AI copilot for creating integration flows seems a pretty safe bet.<BR /> <BR /> GenAI excels at creating text, so generating scripts in SAP Cloud Integration is another area where an AI copilot would make a lot of sense. And script generation is something we can experiment with already now, without having to wait for SAP’s AI copilot to launch.<BR /> <BR /> Creating Groovy scripts with GenAI is an area I’d been wanting to look into for a while, so when OpenAI launched their custom GPT feature, I decided to give it a go.<BR /> <H1 id="toc-hId-834809824">What are custom GPTs?</H1><BR /> Custom GPTs were announced at OpenAI’s DevDay conference in San Francisco in November, 2023. You can check out the announcement <A href="https://openai.com/blog/introducing-gpts" target="_blank" rel="nofollow noopener noreferrer">here</A>. Custom GPTs are a way to specialise ChatGPT in a particular field or topic. They are built on the GPT-4 foundation model, OpenAI’s most powerful model so far. The model is specialised via prompting and so-called knowledge files; there is no coding or complex (and costly) fine-tuning involved in the process. This made a custom GPT a perfect fit for my project.<BR /> <BR /> Custom GPTs can be shared, but at the moment, they are only available to ChatGPT Plus members (a paid subscription) and OpenAI enterprise customers. OpenAI plans to launch a store for custom GPTs at a later date.<BR /> <H1 id="toc-hId-638296319">Training GroovyScriptinator</H1><BR /> An AI assistant needs a proper name, of course, and I named mine GroovyScriptinator. My approach to training was iterative: Try a prompt, identify anything that needs tweaking in the response, update the instructions accordingly and repeat.<BR /> <BR /> Out of the box, GPT-4 is already very capable of generating Groovy code. For that reason, I focused my training efforts on the following three more specific areas:<BR /> <UL><BR /> <LI>The SAP Cloud Integration environment</LI><BR /> <LI>Best practices</LI><BR /> <LI>Creating idiomatic Groovy code</LI><BR /> </UL><BR /> Here are some examples of instructions from the first category:<BR /> <UL><BR /> <LI>All generated code must be compatible with Groovy version 2.4</LI><BR /> <LI>Don’t use Java libraries that require a Java version newer than Java 8</LI><BR /> <LI>The generated script function must either be called <CODE>processData</CODE> or the Script step must be configured with the non-default function name</LI><BR /> </UL><BR /> Here are some examples of instructions from the second category:<BR /> <UL><BR /> <LI>Always pass the payload as a <CODE>Reader</CODE> object to <CODE>XmlSlurper</CODE> and <CODE>JsonSlurper</CODE></LI><BR /> <LI>Don’t pretty-print XML and JSON unless there is a reason to</LI><BR /> <LI>Use the log level at runtime or an externalized parameter to control logging</LI><BR /> </UL><BR /> Here are some examples of instructions from the third category:<BR /> <UL><BR /> <LI>Don’t add a semicolon at the end of a statement</LI><BR /> <LI>Don’t use both <CODE>def</CODE> and a type when declaring a variable</LI><BR /> <LI>Don’t import classes that are already imported automatically in Groovy</LI><BR /> </UL><BR /> At the moment, my instructions for GroovyScriptinator come in at around 1800 words, but that number will likely keep growing. 1800 words is roughly the length of this blog post without the code listings.<BR /> <H1 id="toc-hId-441782814">Taking GroovyScriptinator for a spin</H1><BR /> While working on my custom GPT, I’ve been using a number of prompts for testing its performance. I’ve chosen four examples for this blog post to demonstrate what’s possible. For each example I’ve linked to the conversation, so you can see the full response for yourself.<BR /> <H2 id="toc-hId-374352028">Example 1: JSON processing</H2><BR /> The first example is based on <A href="https://answers.sap.com/questions/14012944/format-json-body-by-removing-an-object.html" target="_blank" rel="noopener noreferrer">this question</A> from the SAP Community. I edited out the part about an existing script, because I wanted GroovyScriptinator to come up with a full solution to the problem. This is the script it generated in response:<BR /> <PRE class="language-java"><CODE>import com.sap.gateway.ip.core.customdev.util.Message<BR /> import groovy.json.JsonSlurper<BR /> import groovy.json.JsonOutput<BR /> <BR /> def Message processData(Message message) {<BR /> // Parse the JSON payload<BR /> def jsonPayload = new JsonSlurper().parseText(message.getBody(String))<BR /> <BR /> // Remove the 'shippingPackages' object<BR /> jsonPayload.remove('shippingPackages')<BR /> <BR /> // Set the modified JSON back to the message body<BR /> message.setBody(JsonOutput.toJson(jsonPayload))<BR /> <BR /> return message<BR /> }</CODE></PRE><BR /> This script works and generates the requested output. It’s nicely formatted and even has decent comments. It’s actually pretty similar to <A href="https://answers.sap.com/answers/14016195/view.html" target="_blank" rel="noopener noreferrer">my own answer</A> to the same question.<BR /> <BR /> The two scripts differ in one respect, though: The payload should really be passed to <CODE>JsonSlurper</CODE> as a <CODE>Reader</CODE> object instead of a <CODE>String</CODE> object (that way a large payload is not read needlessly into memory). This best practice is actually part of my GroovyScriptinator instructions, but it seems to have temporarily forgotten that (more on that below).<BR /> <BR /> I asked it to correct this and received the following script in response:<BR /> <PRE class="language-java"><CODE>import com.sap.gateway.ip.core.customdev.util.Message<BR /> import groovy.json.JsonSlurper<BR /> import groovy.json.JsonOutput<BR /> <BR /> def Message processData(Message message) {<BR /> // Access the JSON payload as a Reader<BR /> def payloadReader = message.getBody(Reader)<BR /> <BR /> // Parse the JSON payload<BR /> def jsonPayload = new JsonSlurper().parse(payloadReader)<BR /> <BR /> // Remove the 'shippingPackages' object<BR /> jsonPayload.remove('shippingPackages')<BR /> <BR /> // Set the modified JSON back to the message body<BR /> message.setBody(JsonOutput.toJson(jsonPayload))<BR /> <BR /> return message<BR /> }</CODE></PRE><BR /> This script also generates the requested output and correctly accesses the payload via the more efficient <CODE>Reader</CODE>. You can view the full conversation <A href="https://chat.openai.com/share/0e735400-ed50-4ea8-a061-b21e550ead9c" target="_blank" rel="nofollow noopener noreferrer">here</A>.<BR /> <H2 id="toc-hId-177838523">Example 2: More JSON</H2><BR /> My second example is based on <A href="https://answers.sap.com/questions/14021759/unable-to-add-root-nodes-in-json-payload-using-gro.html" target="_blank" rel="noopener noreferrer">this</A> SAP Community question (JSON is a popular Groovy scripting topic). I once again edited out the part about an existing script to see GroovyScriptinator’s own solution to the problem. This is the script it generated for me:<BR /> <PRE class="language-java"><CODE>import com.sap.gateway.ip.core.customdev.util.Message<BR /> import groovy.json.JsonSlurper<BR /> import groovy.json.JsonOutput<BR /> <BR /> def Message processData(Message message) {<BR /> // Parse the JSON payload<BR /> def jsonParser = new JsonSlurper()<BR /> def jsonPayload = message.getBody(Reader)<BR /> def parsedJson = jsonParser.parse(jsonPayload)<BR /> <BR /> // Add the new root node<BR /> def modifiedJson = [data: parsedJson]<BR /> <BR /> // Convert the modified JSON back to String<BR /> String jsonString = JsonOutput.toJson(modifiedJson)<BR /> <BR /> // Set the modified JSON as the new payload<BR /> message.setBody(jsonString)<BR /> <BR /> return message<BR /> }</CODE></PRE><BR /> The script works correctly and this time around, GroovyScriptinator correctly used a <CODE>Reader</CODE> to access the payload. It even pointed out that the provided input JSON is, in fact, not valid and that the script only works, when the input is valid.<BR /> <BR /> The only thing I’d point out is that it’s a little odd to declare all variables with <CODE>def</CODE> except <CODE>jsonString</CODE>, which is declared with its type (<CODE>String</CODE>). It's a tiny detail, though. You can view the full conversation <A href="https://chat.openai.com/share/6f47a0d9-71bb-468d-b154-150b79f6c4ee" target="_blank" rel="nofollow noopener noreferrer">here</A>.<BR /> <H2 id="toc-hId--18674982">Example 3: Environment variables</H2><BR /> My third example is a script that I needed for myself. This is the prompt I used:<BR /> <BR /> “I need a script that creates a plain text payload containing the names of all environment variables and their values. I would like the output formatted as "NAME = VALUE", one name/value pair on each line.”<BR /> <BR /> This is the script I received in response:<BR /> <PRE class="language-java"><CODE>import com.sap.gateway.ip.core.customdev.util.Message<BR /> <BR /> def Message processData(Message message) {<BR /> // StringBuilder for constructing the output<BR /> def output = new StringBuilder()<BR /> <BR /> // Iterate over all environment variables and append them to the output<BR /> System.env.each { key, value -&gt;<BR /> output &lt;&lt; key &lt;&lt; " = " &lt;&lt; value &lt;&lt; '\n'<BR /> }<BR /> <BR /> // Set the generated string as the message payload<BR /> message.setBody(output.toString())<BR /> <BR /> return message<BR /> }</CODE></PRE><BR /> This script works and it’s a very decent solution to my problem. Short, sweet and to the point. It uses a <CODE>StringBuilder</CODE> to compose the payload efficiently and even uses the Groovy way of appending to the <CODE>StringBuilder</CODE> with the <CODE>&lt;&lt;</CODE> operator. The only thing I’d point out is that the appended string with the equals sign really should be in single quotes, but that’s a very minor gripe. You can view the full conversation <A href="https://chat.openai.com/share/87215775-b606-4cf0-88cc-62f8b46e865b" target="_blank" rel="nofollow noopener noreferrer">here</A>.<BR /> <H2 id="toc-hId--215188487">Example 4: Fixed-length format to CSV</H2><BR /> The last example is a requirement I made up specifically for testing GroovyScriptinator. I used the following prompt:<BR /> <BR /> “I need a script that turns a fixed-length format text payload into a comma-separated text payload.<BR /> <BR /> The payload contains a number of lines. The columns in the file has the following lengths: 3, 6, 3, 5, 2<BR /> <BR /> Trailing spaces should be removed from the fourth column (but only from the fourth column).<BR /> <BR /> Here is an example input line:<BR /> <BR /> xyz123456abcdef 99<BR /> <BR /> Here is the corresponding output line:<BR /> <BR /> xyz,123456,abc,def,99<BR /> <BR /> You can assume that each line has the same length, and this length is the sum of the column lengths.”<BR /> <BR /> Here’s the script that GroovyScriptinator responded with:<BR /> <PRE class="language-java"><CODE>import com.sap.gateway.ip.core.customdev.util.Message<BR /> <BR /> def Message processData(Message message) {<BR /> // Define column lengths<BR /> def columnLengths = [3, 6, 3, 5, 2]<BR /> <BR /> // Get the payload as a string<BR /> def payload = message.getBody(String)<BR /> def lines = payload.split('\n')<BR /> def newLines = []<BR /> <BR /> lines.each { line -&gt;<BR /> def start = 0<BR /> def columns = columnLengths.collect { length -&gt;<BR /> def column = line.substring(start, start + length)<BR /> start += length<BR /> column<BR /> }<BR /> <BR /> // Trim trailing spaces from the fourth column<BR /> columns[3] = columns[3].trim()<BR /> <BR /> // Join columns with commas<BR /> newLines &lt;&lt; columns.join(',')<BR /> }<BR /> <BR /> // Set the modified payload back into the message<BR /> message.setBody(newLines.join('\n'))<BR /> <BR /> return message<BR /> }</CODE></PRE><BR /> This script solves the problem as stated and is really quite nice. I basically don’t have any notes. It kept the column lengths in an appropriate data structure, rather than hardcoding them into the script. It even got it right that the fourth column has index 3. You can view the full conversation <A href="https://chat.openai.com/share/ae03fc2f-b33a-49fa-87de-ca5ed60aa821" target="_blank" rel="nofollow noopener noreferrer">here</A>.<BR /> <H1 id="toc-hId--540784711">So what’s the verdict?</H1><BR /> The above examples are not staged and have not been doctored in any way. They are representative of the standard of the code created by the custom GPT. It does make mistakes (see the below FAQ), but in general the quality of the responses is very high. Many of the generated scripts are so good that they can be added to your integration flow as is or with minimal modifications. I’d like you to pause for a moment and think about how powerful that is!<BR /> <BR /> So my conclusion is rather obvious: An AI copilot is a perfect fit for Groovy scripting in SAP Cloud Integration and there is no question whatsoever about feasibility. I have no doubt that GenAI will be part of your daily work as an SAP Cloud Integration developer. And it will likely happen sooner rather than later.<BR /> <H1 id="toc-hId--737298216">FAQ</H1><BR /> You probably have a lot of questions! I’ve tried to answer some of them in the following FAQ, but please feel free to ask questions in the comments as well. If I missed any obvious ones I’ll add them to the FAQ.<BR /> <H2 id="toc-hId--804729002">Does this mean I don’t have to learn Groovy?</H2><BR /> No. You can do SAP Cloud Integration development without knowing Groovy, but if you want to add Groovy scripting to your toolbox (and I definitely think you should!), then you need to learn the language.<BR /> <H2 id="toc-hId--653988150">But whyyyy? Can’t I just use GenAI to write all the code?</H2><BR /> You <EM>could</EM>, of course. But what happens after the script has been generated? First off, you won’t know if it actually works. And even if it seems to work, you won’t know why or under which circumstances. If you then throw caution to the wind, deploy the script in production and it breaks, it will be your responsibility to fix it, but you’ll have no idea <EM>how</EM> to fix it.<BR /> <BR /> This is the reason why it’s generally a really, really bad idea to add code that you do not understand to your integration solution. It will come back to <DEL datetime="2023-12-26T19:56:43+00:00">bite you in the</DEL> haunt you later on.<BR /> <H2 id="toc-hId--850501655">Does GenAI make mistakes?</H2><BR /> Yes. If you have used ChatGPT or similar GenAI chatbots before, you have very likely experienced this yourself as well.<BR /> <BR /> I’m really impressed with the quality of the code generated by my custom GPT. That doesn’t mean it’s foolproof, though! It will still sometimes gladly and confidently present you with code that has syntax errors or code that is syntactically correct but just doesn’t work. It also sometimes forgets parts of its instructions.<BR /> <H2 id="toc-hId--1047015160">So if GenAI makes mistakes, does that mean it sucks and I can safely ignore it?</H2><BR /> Absolutely not. It really just emphasizes the copilot role of GenAI coding assistants. A human in the pilot’s seat is still needed and with GenAI that person has a powerful productivity tool available to them.<BR /> <BR /> If you ignore GenAI right now, you do so at your peril. This is not another technology fad that can be waited out with a bit of patience. Love it or hate it, you need to understand what GenAI is, what it can and cannot do and how it can be applied in your context.<BR /> <H2 id="toc-hId--1243528665">Will you be releasing GroovyScriptinator?</H2><BR /> If there’s interest, I might at some point. I'd like to tinker with it some more first, though. 2023-12-27T16:14:31+01:00 https://community.sap.com/t5/technology-blogs-by-members/generative-ai-and-sap-cloud-integration/bc-p/13572034#M163781 Re: Generative AI and SAP Cloud Integration 2023-12-29T13:29:18+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 Interesting idea, Eurico. Let me think about it.<BR /> <BR /> Regards,<BR /> <BR /> Morten 2023-12-29T13:29:18+01:00 https://community.sap.com/t5/technology-blogs-by-members/generative-ai-and-sap-cloud-integration/bc-p/13572036#M163783 Re: Generative AI and SAP Cloud Integration 2023-12-30T14:13:16+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 That's a use case as well, sure. As with the code, you should definitely still have a human in the loop, to determine if what you are getting is actually comprehensive. But GenAI can absolutely create test cases too.<BR /> <BR /> Regards,<BR /> <BR /> Morten 2023-12-30T14:13:16+01:00 https://community.sap.com/t5/technology-q-a/re-success-factor-replication-xslt-mappping-standard-mapping/qaq-p/12816482/comment-id/4812860#M4812860 Re: Success Factor Replication(Xslt Mappping /Standard Mapping) 2024-01-02T14:03:32+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi Fathi</P><P>Something happened to your screenshots. Also, please include sample XML as text, not graphics. That way it can be easily copypasted. Use the CODE button to insert the XML to preserve formatting and special characters.</P><P>Regards,</P><P>Morten</P> 2024-01-02T14:03:32+01:00 https://community.sap.com/t5/technology-q-a/re-success-factor-replication-xslt-mappping-standard-mapping/qaq-p/12816484/comment-id/4812862#M4812862 Re: Success Factor Replication(Xslt Mappping /Standard Mapping) 2024-01-02T16:14:31+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi Fathi</P><P>This is very similar to your other question about mapping a SuccessFactors API response. This XSLT stylesheet will remove all employment_information elements with an end_date child element:</P><PRE><CODE>&lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;xsl:stylesheet version="3.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema"&gt; &lt;xsl:output method="xml" /&gt; &lt;xsl:mode on-no-match="shallow-copy" /&gt; &lt;xsl:template match="employment_information[end_date]"/&gt; &lt;/xsl:stylesheet&gt;<BR /></CODE></PRE><P>Regards,</P><P>Morten</P> 2024-01-02T16:14:31+01:00 https://community.sap.com/t5/technology-q-a/re-is-it-possible-to-read-parquet-file-in-cpi/qaq-p/12816530/comment-id/4812901#M4812901 Re: Is it possible to read Parquet file in CPI? 2024-01-03T11:12:53+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi Yuting</P><P>There are Java libraries available for parsing Parquet files, which means you can read Parquet content in a Groovy script. When evaluating libraries, keep in mind that the Java version in SAP Cloud Integration is still Java 8, so you can only use libraries that are compatible with Java 8.</P><P>Regards,</P><P>Morten</P> 2024-01-03T11:12:53+01:00 https://community.sap.com/t5/technology-q-a/re-success-factor-replication-xslt-mappping-standard-mapping/qaq-p/12816486/comment-id/4812864#M4812864 Re: Success Factor Replication(Xslt Mappping /Standard Mapping) 2024-01-03T16:36:11+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi <SPAN class="mention-scrubbed">fethi_men</SPAN> </P><P>The stylesheet works with the sample data you included. I tested it before posting, of couse. If some other part of your iflow fails, that really has nothing to do with this question.</P><P>Regards,</P><P>Morten</P> 2024-01-03T16:36:11+01:00 https://community.sap.com/t5/technology-q-a/re-message-mapping-to-xslt/qaq-p/12817441/comment-id/4813312#M4813312 Re: Message Mapping to XSLT 2024-01-04T10:48:13+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi Federico</P><P>Interesting project. I don't think there is any documentation of the inner workings of message mappings, so it's probably reverse engineering all the way down.</P><P>Regards,</P><P>Morten</P> 2024-01-04T10:48:13+01:00 https://community.sap.com/t5/technology-blogs-by-members/my-favourite-sap-cloud-integration-feature-trading-partner-management/ba-p/13591619 My favourite SAP Cloud Integration feature: Trading Partner Management 2024-02-01T17:16:50.865000+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="TPM.png" style="width: 999px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/58766iBC7C8FE9817965C8/image-size/large?v=v2&amp;px=999" role="button" title="TPM.png" alt="TPM.png" /></span></P><P>Welcome, fellow integrators, to the seventh installment of this blog post series, where I talk to SAP Cloud Integration practitioners, developers, architects and enthusiasts about their favourite feature of our favourite platform. This time around, I get to interview a true SAP integration veteran who has been a part of this community since the very beginning: Bhavesh Kantilal.</P><P><EM>Welcome to the series, Bhavesh! Could you introduce yourself briefly, please?</EM></P><P>My name is Bhavesh Kantilal. I am an independent freelance consultant based in Stockholm, Sweden, and I have been working with SAP integration technologies since SAP XI 3.0 and with SAP Cloud Integration from when it was called HCI <span class="lia-unicode-emoji" title=":slightly_smiling_face:">🙂</span></P><P><EM>Thank you very much! And now the central question of this blog post series: What’s your favourite SAP Cloud Integration feature?</EM></P><P>There are many features of SAP Cloud Integration I admire, but my current favourite is Trading Partner Management coupled with B2B monitoring. This feature has captivated me so much that I have dedicated a whole blog post series (comprising 18 posts so far) to it on <A href="https://www.sprintegrate.com/category/cpi/edi/" target="_blank" rel="noopener nofollow noreferrer">my personal blog</A>.</P><P><EM>Why that feature in particular?</EM></P><P>In the evolving landscape of cloud integration, where SaaS applications are becoming more prevalent, classic EDI and B2B transactions continue to coexist and flourish within major customer enterprises.</P><P>Consider a customer landscape involving integration with thousands of suppliers. This is typical in sectors like manufacturing, retail, and automotive, where integration occurs with numerous suppliers across various EDI standards like EDIFACT and ANSIX12. These integrations might be point-to-point via protocols like AS2 or through other EDI gateways and VAN mailboxes. In these B2B transactions, each trading partner maintains its own unique set of parameters, identifiers, and transformations. Often, the mapping and transformation are consistent, but what varies is the trading partner connectivity and control records or identifiers.</P><P>Trading Partner Management (TPM) in SAP Cloud Integration offers a comprehensive solution from SAP, where most parameters varying across partners are configurable in TPM. Your main focus then shifts to building mappings via MAGs or classical message mappings, while TPM handles the complexities of EDI transformations, partner connectivity, and adapter configurations.</P><P>TPM extensively utilizes the Partner Directory in SAP Cloud Integration yet simplifies this with a user-friendly UI. Along with the standard iflows provided by SAP, TPM facilitates a plug-and-play B2B architecture that, despite initial complexity, becomes straightforward with experience.</P><P>Moreover, TPM enables out-of-the-box B2B monitoring. If you're familiar with SAP PO, the B2B monitoring in TPM resembles SAP PO monitoring, allowing you to view your B2B payloads and navigate from B2B monitoring to your SAP message logs. You get 90 days of payload logging with TPM (unlike the usual 30 days on MPLs).</P><P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="B2B-monitor.png" style="width: 999px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/58761iFA860487AA1CE24F/image-size/large?v=v2&amp;px=999" role="button" title="B2B-monitor.png" alt="B2B-monitor.png" /></span></P><P><EM>How do you see the future of Trading Partner Management?</EM></P><P>One area for growth in TPM is out-of-the-box monitoring and alerting for failed B2B transactions, which is currently missing but is on the road map. If I were to predict the future, I'd expect SAP to soon release this as a pre-delivered feature, integrated either with Cloud ALM or the Alert Notification Service in BTP.</P><P>There are currently limitations in EDI and IDoc bundling, but I am confident that these will be addressed in upcoming releases. Similarly, EDI Functional Acknowledgments are presently supported only for AS2 adapters, and while workarounds exist (like using the ProcessDirect adapter), this feature is likely to be further enhanced by SAP.</P><P>Another missing feature is archival of your B2B messages to external services like the Document Management Service in BTP. This is a road map item from SAP and this is something that multiple customers need, considering that B2B transactions are legal documents and having a technical log and archive of these messages is mandatory for compliance reasons.</P><P>As customers transition their B2B migrations from SAP PO to SAP Cloud Integration, I foresee a scenario where SAP PO message mappings will be utilized in SAP Cloud Integration and integrated via TPM. This is a feature that will increasingly be adopted, particularly by customers who have been using SAP PO as their B2B gateway.</P><P>I explore alternative solutions to these challenges in my TPM blog series <A href="https://www.sprintegrate.com/cpi/b2b-on-sap-integration-suite-cloud-integration-cpi-using-trading-partner-management-part-1-idoc-to-edi-flows/" target="_blank" rel="noopener nofollow noreferrer">here</A>.</P><P><EM>Thanks a lot for sharing your insights, Bhavesh! It was great to catch up.</EM></P> 2024-02-01T17:16:50.865000+01:00 https://community.sap.com/t5/technology-q-a/re-i-ve-got-problems-with-cpilint-i-need-help/qaq-p/13630970/comment-id/4821080#M4821080 Re: I've got problems with CPILint , I need HELP !! 2024-03-07T10:24:03.905000+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 Happy to help! I'm adding an FAQ to GitHub and this is one of the questions. Basically, after the unified Integration Suite UI, you can no longer copy the hostname from the browser on Cloud Foundry. Instead. you have to copy it from a service key. The approach is described here: <A href="https://help.sap.com/docs/cloud-integration/sap-cloud-integration/http-calls-and-uri-components" target="_blank" rel="noopener noreferrer">https://help.sap.com/docs/cloud-integration/sap-cloud-integration/http-calls-and-uri-components</A> 2024-03-07T10:24:03.905000+01:00 https://community.sap.com/t5/coffee-corner-discussions/celebrating-international-pi-day/m-p/13638753#M2876 Re: Celebrating International Pi Day 2024-03-14T18:59:34.159000+01:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mmm-pie.gif" style="width: 640px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/80954i6798A9C105561725/image-size/large?v=v2&amp;px=999" role="button" title="mmm-pie.gif" alt="mmm-pie.gif" /></span></P> 2024-03-14T18:59:34.159000+01:00 https://community.sap.com/t5/technology-blogs-by-members/cpilint-version-1-0-5-is-here/ba-p/13810431 CPILint version 1.0.5 is here 2024-08-29T01:40:40.485000+02:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="CPILint-1.0.5.png" style="width: 796px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/159107i1095FE3FB0EE3D02/image-size/large?v=v2&amp;px=999" role="button" title="CPILint-1.0.5.png" alt="CPILint-1.0.5.png" /></span></P><P>The very first version of CPILint was released on August 31st, 2019. With the 5th anniversary just around the corner, I am excited to announce that version 1.0.5 is complete and ready for you to install.</P><P>If you already run version 1.0.4, you will automatically be notified that there is a new version available. You can also go <A href="https://github.com/mwittrock/cpilint/releases/latest" target="_blank" rel="noopener nofollow noreferrer">directly to GitHub</A> to download it.</P><P>In this blog post, I will give you an overview of what’s in version 1.0.5. If you are new to CPILint, let me start by giving you the elevator pitch:</P><P>CPILint is an open-source tool that automates your SAP Cloud Integration governance. It ships with a range of built-in rules covering topics like developer guidelines, naming conventions and security. You choose the rules you want to put in place, and CPILint does the heavy lifting of checking your integration flows for compliance.</P><P>Now, let’s take a look at all the good stuff in the new release!</P><H2 id="toc-hId-1044183133">OAuth 2.0 support</H2><P>CPILint communicates with your SAP Cloud Integration tenant via the official OData API. This requires authorization, of course, and so far we’ve done this by providing a username and password.</P><P>In version 1.0.5, however, you can authorize simply by creating a service key for CPILint in the SAP BTP Cockpit and downloading it to your local machine. You use the new <FONT face="courier new,courier">-key</FONT> command line option to point to that key. CPILint then uses your key to authorize its API calls using the OAuth 2.0 client credentials flow.</P><P>This has several benefits for you. First off, you no longer need to provide a username and password. Second, since the tenant hostname is already in the key, you no longer need to provide that either. Third, running CPILint with minimal permissions is now very easy to get right. Finally, the OAuth 2.0 client credentials flow is more secure than basic authentication.</P><P>With the new OAuth 2.0 support, checking your entire tenant for compliance is now as simple as:</P><P><FONT face="courier new,courier">cpilint -key my-key.json -rules my-rules.xml</FONT></P><P>Short and sweet!</P><H2 id="toc-hId-847669628">Rules file import</H2><P>Up until now, every single rule you wanted to check had to be stored in a single rules file. With CPILint version 1.0.5, we get a lot more flexibility. The new version introduces the ability to import a rules file into another rules file. You do this using the new <FONT face="courier new,courier">&lt;import&gt;</FONT> element.</P><P>If you have, for instance, a separate rules file for a specific project package but also want to reuse naming conventions that apply to the entire tenant, you can now simply import those naming conventions into the project’s rules file like this:</P><P>&nbsp;</P><pre class="lia-code-sample language-markup"><code>&lt;cpilint&gt; &lt;imports&gt; &lt;import src="/path/to/naming-conventions.xml"/&gt; &lt;/imports&gt; &lt;rules&gt; &lt;!-- Your project-specific rules would go here. --&gt; &lt;/rules&gt; &lt;/cpilint&gt;</code></pre><P>&nbsp;</P><P>This feature opens up entirely new ways to shape and mold your rules files and I’m excited to see how the community will put it to use! To learn more about rules file imports, visit <A href="https://github.com/mwittrock/cpilint/wiki/Rules-and-the-rules-file" target="_blank" rel="noopener nofollow noreferrer">this wiki page</A>.</P><H2 id="toc-hId-651156123">New rule: UserRoles</H2><P>UserRoles is a new rule in CPILint 1.0.5 that lets you specify which user roles should and should not be used in sender channels that support user role authorization (meaning AS2, AS4, HTTPS, IDoc, SOAP, XI, and OData). If you, for instance, do not allow the use of the default user role (ESBMessaging.send), you would add this rule:</P><P>&nbsp;</P><pre class="lia-code-sample language-markup"><code>&lt;disallowed-user-roles&gt; &lt;disallow&gt;ESBMessaging.send&lt;/disallow&gt; &lt;/disallowed-user-roles&gt;</code></pre><P>&nbsp;</P><P>You can also use the UserRoles rule to require, for instance, that only certain custom user roles be used.</P><H2 id="toc-hId-454642618">Other news</H2><P>1.0.5 adds 30 supported names to the NamingConventions rule. Check out <A href="https://github.com/mwittrock/cpilint/wiki/The-NamingConventions-rule" target="_blank" rel="noopener nofollow noreferrer">this page</A> in the CPILint wiki for the full list of supported names.</P><P>There’s a new command line option called <FONT face="courier new,courier">-skipvercheck</FONT> that skips the automatic check for a new version. If you run CPILint in a non-interactive way, like for instance in a CI/CD pipeline or other automation context, you might want to do this to save a little time and bandwidth.</P><P>The DuplicateResourcesNotAllowed rule now supports JSON resources.</P><P>There is now <A href="https://github.com/mwittrock/cpilint/wiki/FAQ" target="_blank" rel="noopener nofollow noreferrer">an FAQ page</A> in the project wiki.</P><P>Last but definitely not least: The CPILint ASCII art is now 3D. Yes, I saved the best for last!</P><H2 id="toc-hId-258129113">Over to you</H2><P>That’s it for the CPILint 1.0.5 overview. Take the new release for a spin and please share your feedback with me in the comments below.</P> 2024-08-29T01:40:40.485000+02:00 https://community.sap.com/t5/technology-blogs-by-members/five-years-of-cpilint/ba-p/13812638 Five years of CPILint 2024-08-31T14:00:00.036000+02:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="CPILint-kagemand.jpg" style="width: 317px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/160628i953604117E2EA0AA/image-size/medium?v=v2&amp;px=400" role="button" title="CPILint-kagemand.jpg" alt="CPILint-kagemand.jpg" /></span></P><P>On this day five years ago, I released the first version of CPILint on GitHub. I finished <A href="https://community.sap.com/t5/technology-blogs-by-members/cpilint-version-1-0-5-is-here/ba-p/13810431" target="_blank">the latest version</A> two days ago, so this feels like a good time to take a break, enjoy a piece of birthday cake, and look back at the project’s early days.</P><P>(The cake is a “Kagemand”, by the way, which translates literally to “Cake Man”. They’re served at birthday parties in Denmark, and they’re delicious <span class="lia-unicode-emoji" title=":face_savoring_food:">😋</span>)</P><P>Version 1.0.0 came out on August 31st, 2019, but my earliest notes are from the autumn of 2018. They were jotted down between meetings during a visit to SAP in Walldorf. Seeing those notes today, I’m quite surprised how many of the early ideas eventually made their way into CPILint.</P><P>Reading the notes also reminded me that I originally used a different name: Flowmon. I think it was supposed to be a portmanteau of “iflow” and “monitor”, but it’s not a very good name, is it? I’m glad I changed it <span class="lia-unicode-emoji" title=":grinning_face_with_sweat:">😅</span></P><P>Even though I ended up writing CPILint in Java, I initially wanted to implement it in pure XSLT. I had a Schematron-like meta-programming approach in mind with a stylesheet compiling rules into another stylesheet, that would then transform an iflow’s internal XML format into compliance notifications.</P><P>I still have half a prototype, but the technique ultimately felt too limiting and I abandoned it. I still quite like the idea, though. It’s quirky and just a little chaotic <span class="lia-unicode-emoji" title=":upside_down_face:">🙃</span> And it’s not a <EM>bad</EM> thing that it didn’t work out, by the way! On the contrary, one of the wonderful things about hobby projects is that they let you follow new ideas to interesting places and generally - in the words of Kurt Vonnegut - fart around.</P><P>The first time I showed CPILint in public was at SAP Inside Track Walldorf in January 2019. I managed to have a prototype working just in time for the event. Committing publicly to doing a live demo in front of a large group of people is quite motivating after all 🫠</P><P>SIT Walldorf was also the first time I got to show off the CPILint logo:</P><P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="CPILint-logo.png" style="width: 475px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/160099iF469628E497D708A/image-dimensions/475x212?v=v2" width="475" height="212" role="button" title="CPILint-logo.png" alt="CPILint-logo.png" /></span></P><P>I was certain that someone would fairly quickly spot where the inspiration for the logo came from. However, five years later, no one has pointed out the connection. I’m a big fan of retro gaming, and the Atari 2600 console from 1977 is about as retro as it gets. This is the Asteroids game cartridge:</P><P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Asteroids.png" style="width: 485px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/160098i23A1298B60A76CC6/image-dimensions/485x584?v=v2" width="485" height="584" role="button" title="Asteroids.png" alt="Asteroids.png" /></span></P><P>Look familiar? <span class="lia-unicode-emoji" title=":face_with_tongue:">😛</span> For the fifth anniversary I’ve made these logo stickers:</P><P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Stickers.jpg" style="width: 498px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/160103iD488271AD26E2B08/image-dimensions/498x471?v=v2" width="498" height="471" role="button" title="Stickers.jpg" alt="Stickers.jpg" /></span></P><P>I’ll bring stickers with me to events in autumn, so if you’d like one, do come up and say hi!</P><P>Well, the “Kagemand” beckons, so let me wrap this up. Working on CPILint for the last five years has been so much fun, and I have no intention of stopping here! The list of features that I want to implement is still very long, and I’m excited to bring them to you in future releases.</P><P>Thank you for reading and thank you for supporting CPILint!</P> 2024-08-31T14:00:00.036000+02:00 https://community.sap.com/t5/technology-blogs-by-members/five-years-of-cpilint/bc-p/13851956#M169023 Re: Five years of CPILint 2024-09-03T00:32:28.940000+02:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Interesting use case, <a href="https://community.sap.com/t5/user/viewprofilepage/user-id/130169">@EuricoBorges</a>.&nbsp;It would be a great topic for a blog post <span class="lia-unicode-emoji" title=":slightly_smiling_face:">🙂</span></P> 2024-09-03T00:32:28.940000+02:00 https://community.sap.com/t5/devtoberfest/automate-your-sap-cloud-integration-governance-with-cpilint/ec-p/13877939#M828 Re: 🔴 Automate your SAP Cloud Integration governance with CPILint 2024-09-25T21:39:30.749000+02:00 MortenWittrock https://community.sap.com/t5/user/viewprofilepage/user-id/40 <P>Hi Mohamed</P><P>This is not necessarily a good fit for static analysis. You often want to measure, right? That's, by definition, not static. That said, the Design Guidelines have some checks that are performance-related, so you could take a look at those.</P><P>Regards,</P><P>Morten</P> 2024-09-25T21:39:30.749000+02:00