Technical Articles
CPI MPL Custom Header Property Search with SuperEasy
As Santhosh Kumar Vellingiri shared his findings in this blog post about how MPL Custom Header Properties can be used for search with OData APIs. He also encouraged me to add this feature to SuperEasy. Thank you for the challenge, Santhosh! It is a pleasure for me to improve CPI experience! (Thanks again for the APIs & open-minded approach SAP team! The APIs were my dream for years working on PI/PO.)
Note: It is not yet clear if these properties are indexed, so you should only use it for occasional searches.
Update(2021-04-08): Since these are part of the official UI, you can use these custom properties with peace of mind.
Usage
There is a new menu for MPL Custom Header Property Search. You enter property key, value and click “Search”. You can jump to the standard monitoring screens by clicking “Message” or “Correlation” links.
This is the log “Text View” for the same message:
Update for Wildcard Search(2020-10-12)
Search now supports wildcard! Thanks for the idea, high-quality feedback, and contribution from Raffael Herrmann you can use *(asterisk) anywhere in the value to search.
For example, for the value 12345ABC67890 you can even use *23*ABC*67*
Groovy Example
I have also added the Groovy example & explanation to the CPI Groovy Examples Repository
GitHub:
https://github.com/pizug/cpi-groovy-examples/tree/master/mpl-custom-header-property
Example page:
https://pizug.com/cpi-groovy-examples/mpl-custom-header-property
Install Extension
Chrome Extension Install:
https://chrome.google.com/webstore/detail/mdpgroup-supereasy-extens/nbeijdcbojmlpnhdikiebpdkikkmkljh
Microsoft Edge(Chromium-based) Extension Install:
https://microsoftedge.microsoft.com/addons/detail/pkfgnpdpdchmplpadeekbhonknnhknkl
Thanks for reading!
Fatih
Hi Fatih,
that is a great feature! Maybe we can bring it even to the next level. What about using wildcards in search? (Sometimes leading zeros or number ranges make search hard, thus wildcards could come in handy.)
Currently you're calling the following API url:
For wildcard support you could change the urls as follows. (Maybe there are more intelligent solutions, but this is how I would do it right now.)
Case 1
Fieldname: Material, Searchpattern: 1234
Url: Keep as it is implemented right now.
Case 2
Fieldname: Material, Searchpattern: *1234
Url:
Case 3
Fieldname: Material, Searchpattern: 1234*
Url:
Case 4
Fieldname: Material, Searchpattern: *1234*
Url:
So basically, if pattern starts with *, then remove * from pattern use "endswith"-style url. If pattern ends with *, then remove * from pattern use "startswith"-style url. If pattern starts and ends with *, then remove * from pattern use "substringof"-style url.
If pattern contains more then two * or a * inbetween the pattern, I can think of three options:
Best regards,
Raffael
Hello Raffael,
Thank you for the complete and detailed analysis for the feature! It makes sense to provide this option since the first use-case is not even affected. Hopefully, I will try to implement it soon.
Best regards,
Fatih
That is your tool too? Impressive!! Thank you once more 🙂
Thanks for your feedback, Christopher! My fuel is the scalable positive impact on other Integration Consultants' lives. I mean I can sleep but the tools should work. 🙂