Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

start failed #442

Closed
galenzhao opened this issue Oct 24, 2016 · 5 comments
Closed

start failed #442

galenzhao opened this issue Oct 24, 2016 · 5 comments

Comments

@galenzhao
Copy link

org.springframework.beans.factory.BeanDefinitionStoreException: Failed to read candidate component class: URL [jar:file:/root/apollo-build-scripts/service/apollo-service.jar!/lib/apollo-common-0.2.0-SNAPSHOT.jar!/com/ctrip/framework/apollo/common/datasource/TitanEntityManager.class]; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholder 'fat_titan_url' in string value "${fat_titan_url}"

@nobodyiam
Copy link
Member

@galenzhao 你是通过quick start中的build.sh启动的吗?

里面有一些参数是预先设置好的,建议还是通过build.sh启动

@galenzhao
Copy link
Author

@nobodyiam
是的,是通过buildsh启动的,我看了这个shell,里边没有这个参数啊

@nobodyiam
Copy link
Member

@galenzhao 我们的代码是区分运行时profile的,上述的fat_titan_url参数只在ctrip profile才会被运行。
在quick start的build.sh里面应该能看到-Dspring.profiles.active=dev的,所以通过这个脚本执行的应该是不会尝试读取fat_titan_url的。。

@galenzhao
Copy link
Author

galenzhao commented Oct 26, 2016

@nobodyiam

+ echo '==== starting service ===='
==== starting service ====
+ export 'JAVA_OPTS=-Denv=dev -Ddev_meta=http://localhost:8080 -Dspring.profiles.active=dev -Deureka.service.url=http://localhost:8080/eureka/ -Dspring.datasource.url=jdbc:mysql://localhost:3306/ApolloConfigDB?characterEncoding=utf8 -Dspring.datasource.username=root -Dspring.datasource.password='
+ JAVA_OPTS='-Denv=dev -Ddev_meta=http://localhost:8080 -Dspring.profiles.active=dev -Deureka.service.url=http://localhost:8080/eureka/ -Dspring.datasource.url=jdbc:mysql://localhost:3306/ApolloConfigDB?characterEncoding=utf8 -Dspring.datasource.username=root -Dspring.datasource.password='
+ [[ -f ./service/apollo-service.jar ]]
+ rm -rf ./service/apollo-service.jar
+ ln apollo-all-in-one.jar ./service/apollo-service.jar
+ chmod a+x ./service/apollo-service.jar
+ java '-Denv=dev -Ddev_meta=http://localhost:8080 -Dspring.profiles.active=dev -Deureka.service.url=http://localhost:8080/eureka/ -Dspring.datasource.url=jdbc:mysql://localhost:3306/ApolloConfigDB?characterEncoding=utf8 -Dspring.datasource.username=root -Dspring.datasource.password=' -jar ./service/apollo-service.jar start --configservice --adminservice

我看shell带了这个参数,

@galenzhao
Copy link
Author

没问题了,多了个‘

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants