Merge pull request #1 from abhupadh/CI-7239

relaxing constraint for extension name validation
This commit is contained in:
Abhishek Upadhyay 2025-02-28 13:16:30 -08:00 committed by GitHub
commit e0100b917a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 2 deletions

View File

@ -224,7 +224,7 @@ public abstract class BaseCloudEventBuilder<SELF extends BaseCloudEventBuilder<S
}
/**
* Validates the extension name as defined in CloudEvents spec.
* Validates the extension name as defined in CloudEvents spec.
*
* @param name the extension name
* @return true if extension name is valid, false otherwise
@ -240,7 +240,7 @@ public abstract class BaseCloudEventBuilder<SELF extends BaseCloudEventBuilder<S
}
private static boolean isValidChar(char c) {
return (c >= 'a' && c <= 'z') || (c >= '0' && c <= '9');
return (c >= 'a' && c <= 'z') || (c >= '0' && c <= '9') || c == '_';
}
protected void requireValidAttributeWrite(String name) {

View File

@ -122,6 +122,11 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>${maven-surefire-plugin.version}</version>
<configuration>
<excludes>
<exclude>**/*TestMicroprofile.java</exclude>
</excludes>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>