其他模式我配置测试都没有问题,就是这个simple模式,url配置的string报转换类型错误。不知为何?从报错看需要key,value的SshUriProperties格式
Property: spring.cloud.config.server.git.repos[simple]
Value: https://github.com/xiaoni2009/simple/spring-cloud-config-repo
Reason: Failed to convert property value of type 'java.lang.String' to required type 'org.springframework.cloud.config.server.ssh.SshUriProperties$SshUriNestedRepoProperties' for property 'repos[simple]'; nested exception is java.lang.IllegalStateException: Cannot convert value of type 'java.lang.String' to required type 'org.springframework.cloud.config.server.ssh.SshUriPropertiesDescription:
Binding to target org.springframework.cloud.config.server.ssh.SshUriProperties(uri=https://github.com/xiaoni2009/spring-cloud-config-repo hostKeyAlgorithm=null, hostKey=null, privateKey=null, ignoreLocalSshSettings=false, knownHostsFile=null, preferredAuthentications=null, strictHostKeyChecking=true,){repos={special=org.springframework.cloud.config.server.ssh.SshUriProperties(uri=https://github.com/xiaoni2009/spring-cloud-config-repo hostKeyAlgorithm=null, hostKey=null, privateKey=null, ignoreLocalSshSettings=false, knownHostsFile=null, preferredAuthentications=null, strictHostKeyChecking=true,), local=org.springframework.cloud.config.server.ssh.SshUriProperties(uri=file:D:/WorkSpace/spring-cloud-config-repo hostKeyAlgorithm=null, hostKey=null, privateKey=null, ignoreLocalSshSettings=false, knownHostsFile=null, preferredAuthentications=null, strictHostKeyChecking=true,)}} failed:
Property: spring.cloud.config.server.git.repos[simple]
Value: https://github.com/xiaoni2009/simple/spring-cloud-config-repo
Reason: Failed to convert property value of type 'java.lang.String' to required type 'org.springframework.cloud.config.server.ssh.SshUriProperties$SshUriNestedRepoProperties' for property 'repos[simple]'; nested exception is java.lang.IllegalStateException: Cannot convert value of type 'java.lang.String' to required type 'org.springframework.cloud.config.server.ssh.SshUriProperties$SshUriNestedRepoProperties' for property 'repos[simple]': no matching editors or conversion strategy found$SshUriNestedRepoProperties' for property 'repos[simple]': no matching editors or conversion strategy found