cvc-complex-type.2.4.d:发现以元素 'sslCertificateAlias' 开头的无效内容。此时不应有子元素
cvc-complex-type.2.4.d: Invalid content was found starting with element 'sslCertificateAlias'. No child element is expected at this point
当我在 adapter.xml 中启用 SSL 元素时。我收到错误
cvc-complex-type.2.4.d: 发现以元素 'sslCertificateAlias' 开头的无效内容。此时不需要子元素。
有什么办法可以解决吗?
我的 xml 结构如下所示。
<displayName>Test525Adapter</displayName>
<description>Test525Adapter</description>
<connectivity>
<connectionPolicy xsi:type="http:HTTPConnectionPolicyType">
<protocol>https</protocol>
<domain>docs.oracle.com</domain>
<port>443</port>
<connectionTimeoutInMilliseconds>30000</connectionTimeoutInMilliseconds>
<socketTimeoutInMilliseconds>30000</socketTimeoutInMilliseconds>
<maxConcurrentConnectionsPerNode>50</maxConcurrentConnectionsPerNode>
<sslCertificateAlias></sslCertificateAlias>
<sslCertificatePassword></sslCertificatePassword>
</connectionPolicy>
</connectivity>
这是因为元素的顺序。改成如下应该就可以了:
<connectionPolicy xsi:type="http:HTTPConnectionPolicyType">
<protocol>https</protocol>
<domain>developer.ibm.com</domain>
<port>443</port>
<connectionTimeoutInMilliseconds>30000</connectionTimeoutInMilliseconds>
<socketTimeoutInMilliseconds>30000</socketTimeoutInMilliseconds>
<sslCertificateAlias>...</sslCertificateAlias>
<sslCertificatePassword>...</sslCertificatePassword>
<maxConcurrentConnectionsPerNode>50</maxConcurrentConnectionsPerNode>
</connectionPolicy>
当我在 adapter.xml 中启用 SSL 元素时。我收到错误
cvc-complex-type.2.4.d: 发现以元素 'sslCertificateAlias' 开头的无效内容。此时不需要子元素。
有什么办法可以解决吗?
我的 xml 结构如下所示。
<displayName>Test525Adapter</displayName>
<description>Test525Adapter</description>
<connectivity>
<connectionPolicy xsi:type="http:HTTPConnectionPolicyType">
<protocol>https</protocol>
<domain>docs.oracle.com</domain>
<port>443</port>
<connectionTimeoutInMilliseconds>30000</connectionTimeoutInMilliseconds>
<socketTimeoutInMilliseconds>30000</socketTimeoutInMilliseconds>
<maxConcurrentConnectionsPerNode>50</maxConcurrentConnectionsPerNode>
<sslCertificateAlias></sslCertificateAlias>
<sslCertificatePassword></sslCertificatePassword>
</connectionPolicy>
</connectivity>
这是因为元素的顺序。改成如下应该就可以了:
<connectionPolicy xsi:type="http:HTTPConnectionPolicyType">
<protocol>https</protocol>
<domain>developer.ibm.com</domain>
<port>443</port>
<connectionTimeoutInMilliseconds>30000</connectionTimeoutInMilliseconds>
<socketTimeoutInMilliseconds>30000</socketTimeoutInMilliseconds>
<sslCertificateAlias>...</sslCertificateAlias>
<sslCertificatePassword>...</sslCertificatePassword>
<maxConcurrentConnectionsPerNode>50</maxConcurrentConnectionsPerNode>
</connectionPolicy>