[ 
https://issues.apache.org/jira/browse/FLINK-24381?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17437315#comment-17437315
 ] 

Jark Wu commented on FLINK-24381:
---------------------------------

The release-1.13 branch keeps failing on the new introduced test:

https://dev.azure.com/apache-flink/apache-flink/_build?definitionId=1&_a=summary&repositoryFilter=1&branchFilter=11516%2C11516%2C11516%2C11516

{code}
2021-11-01T10:44:56.1806689Z Nov 01 10:44:56 [ERROR] Failures: 
2021-11-01T10:44:56.1807226Z Nov 01 10:44:56 [ERROR]   
FactoryUtilTest.testSecretOption 
2021-11-01T10:44:56.1808215Z Nov 01 10:44:56 Expected: (an instance of 
org.apache.flink.table.api.ValidationException and Expected failure cause is 
<org.apache.flink.table.api.ValidationException: Table options are:
2021-11-01T10:44:56.1809278Z Nov 01 10:44:56 
2021-11-01T10:44:56.1810394Z Nov 01 10:44:56 'buffer-size'='1000'
2021-11-01T10:44:56.1810967Z Nov 01 10:44:56 'connector'='test-connector'
2021-11-01T10:44:56.1811459Z Nov 01 10:44:56 'key.format'='test-format'
2021-11-01T10:44:56.1811990Z Nov 01 10:44:56 'key.test-format.delimiter'=','
2021-11-01T10:44:56.1812682Z Nov 01 10:44:56 'password'='******'
2021-11-01T10:44:56.1813467Z Nov 01 10:44:56 'property-version'='1'
2021-11-01T10:44:56.1813906Z Nov 01 10:44:56 'value.format'='test-format'
2021-11-01T10:44:56.1814681Z Nov 01 10:44:56 'value.test-format.delimiter'='|'
2021-11-01T10:44:56.1815202Z Nov 01 10:44:56 
'value.test-format.fail-on-missing'='true'>)
2021-11-01T10:44:56.1815728Z Nov 01 10:44:56      but: Expected failure cause 
is <org.apache.flink.table.api.ValidationException: Table options are:
2021-11-01T10:44:56.1816352Z Nov 01 10:44:56 
2021-11-01T10:44:56.1816764Z Nov 01 10:44:56 'buffer-size'='1000'
2021-11-01T10:44:56.1817319Z Nov 01 10:44:56 'connector'='test-connector'
2021-11-01T10:44:56.1817772Z Nov 01 10:44:56 'key.format'='test-format'
2021-11-01T10:44:56.1818274Z Nov 01 10:44:56 'key.test-format.delimiter'=','
2021-11-01T10:44:56.1818869Z Nov 01 10:44:56 'password'='******'
2021-11-01T10:44:56.1819309Z Nov 01 10:44:56 'property-version'='1'
2021-11-01T10:44:56.1819886Z Nov 01 10:44:56 'value.format'='test-format'
2021-11-01T10:44:56.1820357Z Nov 01 10:44:56 'value.test-format.delimiter'='|'
2021-11-01T10:44:56.1821233Z Nov 01 10:44:56 
'value.test-format.fail-on-missing'='true'> The throwable 
<org.apache.flink.table.api.ValidationException: Unable to create a source for 
reading table 'default.default.t1'.
2021-11-01T10:44:56.1821796Z Nov 01 10:44:56 
2021-11-01T10:44:56.1822044Z Nov 01 10:44:56 Table options are:
2021-11-01T10:44:56.1822416Z Nov 01 10:44:56 
2021-11-01T10:44:56.1822809Z Nov 01 10:44:56 'buffer-size'='1000'
2021-11-01T10:44:56.1823327Z Nov 01 10:44:56 'connector'='test-connector'
2021-11-01T10:44:56.1823794Z Nov 01 10:44:56 'key.format'='test-format'
2021-11-01T10:44:56.1824244Z Nov 01 10:44:56 'key.test-format.delimiter'=','
2021-11-01T10:44:56.1824689Z Nov 01 10:44:56 'password'='******'
2021-11-01T10:44:56.1825124Z Nov 01 10:44:56 'property-version'='1'
2021-11-01T10:44:56.1825558Z Nov 01 10:44:56 'value.format'='test-format'
2021-11-01T10:44:56.1826034Z Nov 01 10:44:56 'value.test-format.delimiter'='|'
2021-11-01T10:44:56.1826869Z Nov 01 10:44:56 
'value.test-format.fail-on-missing'='true'> does not contain the expected 
failure cause <org.apache.flink.table.api.ValidationException: Table options 
are:
2021-11-01T10:44:56.1827422Z Nov 01 10:44:56 
2021-11-01T10:44:56.1827827Z Nov 01 10:44:56 'buffer-size'='1000'
2021-11-01T10:44:56.1828263Z Nov 01 10:44:56 'connector'='test-connector'
2021-11-01T10:44:56.1828789Z Nov 01 10:44:56 'key.format'='test-format'
2021-11-01T10:44:56.1829244Z Nov 01 10:44:56 'key.test-format.delimiter'=','
2021-11-01T10:44:56.1829690Z Nov 01 10:44:56 'password'='******'
2021-11-01T10:44:56.1830104Z Nov 01 10:44:56 'property-version'='1'
2021-11-01T10:44:56.1830551Z Nov 01 10:44:56 'value.format'='test-format'
2021-11-01T10:44:56.1831018Z Nov 01 10:44:56 'value.test-format.delimiter'='|'
2021-11-01T10:44:56.1831504Z Nov 01 10:44:56 
'value.test-format.fail-on-missing'='true'>
2021-11-01T10:44:56.1832345Z Nov 01 10:44:56 Stacktrace was: 
org.apache.flink.table.api.ValidationException: Unable to create a source for 
reading table 'default.default.t1'.
2021-11-01T10:44:56.1832822Z Nov 01 10:44:56 
2021-11-01T10:44:56.1833070Z Nov 01 10:44:56 Table options are:
2021-11-01T10:44:56.1833332Z Nov 01 10:44:56 
2021-11-01T10:44:56.1833726Z Nov 01 10:44:56 'buffer-size'='1000'
2021-11-01T10:44:56.1834177Z Nov 01 10:44:56 'connector'='test-connector'
2021-11-01T10:44:56.1834615Z Nov 01 10:44:56 'key.format'='test-format'
2021-11-01T10:44:56.1835077Z Nov 01 10:44:56 'key.test-format.delimiter'=','
2021-11-01T10:44:56.1835521Z Nov 01 10:44:56 'password'='******'
2021-11-01T10:44:56.1835935Z Nov 01 10:44:56 'property-version'='1'
2021-11-01T10:44:56.1836387Z Nov 01 10:44:56 'value.format'='test-format'
2021-11-01T10:44:56.1836841Z Nov 01 10:44:56 'value.test-format.delimiter'='|'
2021-11-01T10:44:56.1837349Z Nov 01 10:44:56 
'value.test-format.fail-on-missing'='true'
2021-11-01T10:44:56.1837871Z Nov 01 10:44:56    at 
org.apache.flink.table.factories.FactoryUtil.createTableSource(FactoryUtil.java:140)
2021-11-01T10:44:56.1838644Z Nov 01 10:44:56    at 
org.apache.flink.table.factories.utils.FactoryMocks.createTableSource(FactoryMocks.java:58)
2021-11-01T10:44:56.1839648Z Nov 01 10:44:56    at 
org.apache.flink.table.factories.FactoryUtilTest.testError(FactoryUtilTest.java:374)
2021-11-01T10:44:56.1840250Z Nov 01 10:44:56    at 
org.apache.flink.table.factories.FactoryUtilTest.testSecretOption(FactoryUtilTest.java:162)
2021-11-01T10:44:56.1840845Z Nov 01 10:44:56    at 
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2021-11-01T10:44:56.1841351Z Nov 01 10:44:56    at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
2021-11-01T10:44:56.1841909Z Nov 01 10:44:56    at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
2021-11-01T10:44:56.1842511Z Nov 01 10:44:56    at 
java.lang.reflect.Method.invoke(Method.java:498)
2021-11-01T10:44:56.1843031Z Nov 01 10:44:56    at 
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
2021-11-01T10:44:56.1843585Z Nov 01 10:44:56    at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
2021-11-01T10:44:56.1844165Z Nov 01 10:44:56    at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
2021-11-01T10:44:56.1844737Z Nov 01 10:44:56    at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
2021-11-01T10:44:56.1845314Z Nov 01 10:44:56    at 
org.junit.rules.ExpectedException$ExpectedExceptionStatement.evaluate(ExpectedException.java:239)
2021-11-01T10:44:56.1845853Z Nov 01 10:44:56    at 
org.junit.rules.RunRules.evaluate(RunRules.java:20)
2021-11-01T10:44:56.1846320Z Nov 01 10:44:56    at 
org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
2021-11-01T10:44:56.1846827Z Nov 01 10:44:56    at 
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
2021-11-01T10:44:56.1847383Z Nov 01 10:44:56    at 
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
2021-11-01T10:44:56.1847882Z Nov 01 10:44:56    at 
org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
2021-11-01T10:44:56.1848368Z Nov 01 10:44:56    at 
org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
2021-11-01T10:44:56.1848944Z Nov 01 10:44:56    at 
org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
2021-11-01T10:44:56.1849425Z Nov 01 10:44:56    at 
org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
2021-11-01T10:44:56.1849948Z Nov 01 10:44:56    at 
org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
2021-11-01T10:44:56.1850615Z Nov 01 10:44:56    at 
org.junit.runners.ParentRunner.run(ParentRunner.java:363)
2021-11-01T10:44:56.1851135Z Nov 01 10:44:56    at 
org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:365)
2021-11-01T10:44:56.1851720Z Nov 01 10:44:56    at 
org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:273)
2021-11-01T10:44:56.1852374Z Nov 01 10:44:56    at 
org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:238)
2021-11-01T10:44:56.1852953Z Nov 01 10:44:56    at 
org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:159)
2021-11-01T10:44:56.1853562Z Nov 01 10:44:56    at 
org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:384)
2021-11-01T10:44:56.1854159Z Nov 01 10:44:56    at 
org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:345)
2021-11-01T10:44:56.1854723Z Nov 01 10:44:56    at 
org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:126)
2021-11-01T10:44:56.1855266Z Nov 01 10:44:56    at 
org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:418)
2021-11-01T10:44:56.1855815Z Nov 01 10:44:56 Caused by: 
org.apache.flink.table.api.ValidationException: One or more required options 
are missing.
2021-11-01T10:44:56.1856232Z Nov 01 10:44:56 
2021-11-01T10:44:56.1856505Z Nov 01 10:44:56 Missing required options are:
2021-11-01T10:44:56.1856793Z Nov 01 10:44:56 
2021-11-01T10:44:56.1857029Z Nov 01 10:44:56 target
2021-11-01T10:44:56.1857549Z Nov 01 10:44:56    at 
org.apache.flink.table.factories.FactoryUtil.validateFactoryOptions(FactoryUtil.java:384)
2021-11-01T10:44:56.1858212Z Nov 01 10:44:56    at 
org.apache.flink.table.factories.FactoryUtil.validateFactoryOptions(FactoryUtil.java:357)
2021-11-01T10:44:56.1858942Z Nov 01 10:44:56    at 
org.apache.flink.table.factories.FactoryUtil$TableFactoryHelper.validate(FactoryUtil.java:718)
2021-11-01T10:44:56.1859611Z Nov 01 10:44:56    at 
org.apache.flink.table.factories.TestDynamicTableFactory.createDynamicTableSource(TestDynamicTableFactory.java:80)
2021-11-01T10:44:56.1860254Z Nov 01 10:44:56    at 
org.apache.flink.table.factories.FactoryUtil.createTableSource(FactoryUtil.java:137)
2021-11-01T10:44:56.1860658Z Nov 01 10:44:56    ... 30 more
2021-11-01T10:44:56.1860902Z Nov 01 10:44:56 
2021-11-01T10:44:56.1861143Z Nov 01 10:44:56 [INFO] 
2021-11-01T10:44:56.1861484Z Nov 01 10:44:56 [ERROR] Tests run: 1396, Failures: 
1, Errors: 0, Skipped: 0
{code}

> Table API exceptions may leak sensitive configuration values
> ------------------------------------------------------------
>
>                 Key: FLINK-24381
>                 URL: https://issues.apache.org/jira/browse/FLINK-24381
>             Project: Flink
>          Issue Type: Bug
>          Components: Table SQL / Planner
>    Affects Versions: 1.13.0
>            Reporter: Ada Wong
>            Assignee: Ada Wong
>            Priority: Critical
>              Labels: pull-request-available
>             Fix For: 1.15.0, 1.14.1, 1.13.4
>
>
> This following is error message. Password is 'bar' and is displayed.
> Could we hidden it to password='******' or password='<hidden>' inspired by 
> Apache Kafka source code.
> {code:java}
> Missing required options are:
> hosts 
> Unable to create a sink for writing table 
> 'default_catalog.default_database.dws'.
> Table options are:
> 'connector'='elasticsearch7-x'
> 'index'='foo'
> 'password'='bar'
>       at 
> org.apache.flink.table.factories.FactoryUtil.createTableSink(FactoryUtil.java:208)
>       at 
> org.apache.flink.table.planner.delegation.PlannerBase.getTableSink(PlannerBase.scala:369)
>       at 
> org.apache.flink.table.planner.delegation.PlannerBase.translateToRel(PlannerBase.scala:221)
>       at 
> org.apache.flink.table.planner.delegation.PlannerBase.$anonfun$translate$1(PlannerBase.scala:159
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to