shuttie opened a new pull request, #55:
URL: https://github.com/apache/flink-connector-opensearch/pull/55

   
[https://issues.apache.org/jira/browse/FLINK-38863](https://issues.apache.org/jira/browse/FLINK-38863)
   
   This PR fixes the `mvn test` failing with the error:
   
   ```
   [INFO] Running org.apache.flink.architecture.rules.ConnectorRules
   [ERROR] Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 
0.029 s <<< FAILURE! - in org.apache.flink.architecture.rules.ConnectorRules
   [ERROR] ConnectorRules.CONNECTOR_CLASSES_ONLY_DEPEND_ON_PUBLIC_API  Time 
elapsed: 0.027 s  <<< FAILURE!
   java.lang.AssertionError: 
   Architecture Violation [Priority: MEDIUM] - Rule 'Connector production code 
must depend only on public API when outside of connector packages' was violated 
(1 times):
   Method 
<org.apache.flink.connector.opensearch.table.IndexGeneratorFactory.createRuntimeIndexGenerator(java.lang.String,
 [Ljava.lang.String;, [Lorg.apache.flink.table.types.DataType;, 
   
org.apache.flink.connector.opensearch.table.IndexGeneratorFactory$IndexHelper, 
java.time.ZoneId)> has parameter of type 
<[Lorg.apache.flink.table.types.DataType;> in (IndexGeneratorFactory.java:0)
           at 
com.tngtech.archunit.lang.ArchRule$Assertions.assertNoViolation(ArchRule.java:94)
           at 
com.tngtech.archunit.lang.ArchRule$Assertions.check(ArchRule.java:86)
           at 
com.tngtech.archunit.library.freeze.FreezingArchRule.check(FreezingArchRule.java:97)
           at 
com.tngtech.archunit.junit.internal.ArchUnitTestDescriptor$ArchUnitRuleDescriptor.execute(ArchUnitTestDescriptor.java:166)
           at 
com.tngtech.archunit.junit.internal.ArchUnitTestDescriptor$ArchUnitRuleDescriptor.execute(ArchUnitTestDescriptor.java:149)
           at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
           at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
           at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
           at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
   ```
   
   Changes:
   * As `createRuntimeIndexGenerator` only needs `LogicalType` and not 
`DataType`, we just change the signature to use non-private class. 
   * We also removed excessive List <-> Array conversions.
   
   This PR should have no user-visible changes.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to