Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introducing RequiredFileNamePatterns feature to read files depending on the existence of other files #2099

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

olhepp-avintis
Copy link

Purpose

The purpose of this pull request is to introduce a feature covering a common use case, which is reading a file depending of the existence of another file.

Release note

Added RequiredFileNamePatterns feature to process files depending on the existence of other files using regular expressions.

Documentation

Example for usage:

<parameter name="transport.vfs.FileNamePattern">(.*)[.](hl7|pdf)$</parameter>
<parameter name="transport.vfs.RequiredFileNamePatterns">$1[.]pdf,$1[.]hl7</parameter>

The above mentioned example shows that a file (with .hl7 or .pdf extension) is only transfered, if both regular expression defined in the “RequiredFileNamePattern” are satisfied.
The $1 part represents the first group (parentheses) of the FileNamePattern property.
Processing files will be processed in the order of their appearance in RequiredFileNamePatterns parameter.

@CLAassistant
Copy link

CLAassistant commented Sep 13, 2023

CLA assistant check
All committers have signed the CLA.

@olhepp-avintis olhepp-avintis changed the title WSO2-214: Implemented RequiredFileNamePatterns feature Introducing RequiredFileNamePatterns feature to read files depending on the existence of other files Sep 13, 2023
rmsamitha pushed a commit to rmsamitha/wso2-synapse that referenced this pull request Sep 19, 2023
…x-full

Log improvement in FilePropertyResolver
@arunans23
Copy link
Member

arunans23 commented Jul 11, 2024

Thank you for your contribution. Can you sign the CLA to merge the PR?

Comment on lines +1285 to +1287
for (String groupName: groups) {
relevantname+=matcher.group(groupName);
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shall we format the code segments? It seems both tabs and spaces are used. Let's use only spaces and format the code. Please check other places as well.

@arunans23
Copy link
Member

Shall we explain in the PR description a little bit more about why this requirement came up?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants