Spring LiveBeansView报错相关
Spring 启动后报这个错:
javax.naming.NameNotFoundException: Name [spring.liveBeansView.mbeanDomain] is not bound in this Context. Unable to find [spring.liveBeansView.mbeanDomain].
想问一下,这个liveBeansView该如何配置?
朵谢梅小先生
11 years, 2 months ago
Answers
我也遇到这个问题了。
怎么都注入不来..而另外一个项目是正确的,搞了一个下午了..
控制台报错信息:
[26/08/13 04:47:07:007 CST] DEBUG jndi.JndiPropertySource: JNDI lookup for name [spring.liveBeansView.mbeanDomain] threw NamingException with message: null. Returning null.
[26/08/13 04:47:07:007 CST] DEBUG env.PropertySourcesPropertyResolver: Searching for key 'spring.liveBeansView.mbeanDomain' in [systemProperties]
[26/08/13 04:47:07:007 CST] DEBUG env.PropertySourcesPropertyResolver: Searching for key 'spring.liveBeansView.mbeanDomain' in [systemEnvironment]
[26/08/13 04:47:07:007 CST] DEBUG env.SystemEnvironmentPropertySource: PropertySource [systemEnvironment] does not contain 'spring.liveBeansView.mbeanDomain'
[26/08/13 04:47:07:007 CST] DEBUG env.SystemEnvironmentPropertySource: PropertySource [systemEnvironment] does not contain 'spring_liveBeansView_mbeanDomain'
[26/08/13 04:47:07:007 CST] DEBUG env.SystemEnvironmentPropertySource: PropertySource [systemEnvironment] does not contain 'SPRING.LIVEBEANSVIEW.MBEANDOMAIN'
[26/08/13 04:47:07:007 CST] DEBUG env.SystemEnvironmentPropertySource: PropertySource [systemEnvironment] does not contain 'SPRING_LIVEBEANSVIEW_MBEANDOMAIN'
[26/08/13 04:47:07:007 CST] DEBUG env.PropertySourcesPropertyResolver: Searching for key 'spring.liveBeansView.mbeanDomain' in [class path resource [conf/test.properties]]
[26/08/13 04:47:07:007 CST] DEBUG env.PropertySourcesPropertyResolver: Searching for key 'spring.liveBeansView.mbeanDomain' in [class path resource [conf/appconfig.properties]]
[26/08/13 04:47:07:007 CST] DEBUG env.PropertySourcesPropertyResolver: Could not find key 'spring.liveBeansView.mbeanDomain' in any property source. Returning [null]
@Configuration
@PropertySource("classpath:/conf/appconfig.properties")
public class AppConfig {
// 集付通卡接口
@Value("${cnnct_Interface_URL}")
String cnnctInterfaceURL;
@Value("${cnnct_ic_suffix}")
String ICSuffix;
@Value("${jft_door_site_URL}")
String jftDoorSiteURL;
@Value("${jft_ds_suffix}")
String jftDSSuffix;
Marry_A
answered 11 years, 2 months ago