NutzCN Logo
问答 junit ioc注入为空
发布于 2702天前 作者 shenxiaolei123 2005 次浏览 复制 上一个帖子 下一个帖子
标签:

RunWith(MyNutTestRunner.class)
@IocBean // 必须有
@InjectName
public class SimpleTest extends Assert {

//private static final Log log = Logs.get();

// 跟通常的@Inject完全一样.
@Inject("refer:$ioc")
protected Ioc ioc;

@Inject
protected Dao dao;
@Inject
private SystemService service;

@org.junit.Test
public void test_user_service_create_user() {

/* //Ioc ioc = Mvcs.ctx().getDefaultIoc();
System.out.println(service);
SystemService service = ioc.get(SystemService.class);*/
StartPageModel model = service.getStartPageByDate();
System.out.println(model);
/* dao.create(User.class, false);
User user = new User("wendal", "1234512345");
dao.insert(user);

    user = dao.fetch(User.class, "wendal");
    assertNotNull(user);
    assertNotNull(user.getName());*/
}

}

此处的变量ioc 获得不到是空的怎么回事?

22 回复

public class MyNutTestRunner extends NutTestRunner {

public MyNutTestRunner(Class<?> klass) throws InitializationError {
    super(klass);
}

public Class<?> getMainModule() {
    return MainModule.class;
}

/**
 * 可覆盖createIoc,实现参数覆盖, bean替换,等定制.
 */
protected Ioc createIoc() {
    Ioc ioc = super.createIoc();
    SystemService service =  ioc.get(SystemService.class);
    System.out.println(service);

/* PropertiesProxy conf = ioc.get(PropertiesProxy.class, "conf");
conf.put("db.url", "jdbc:h2:~/test");*/
return ioc;
}
已经覆盖方法了

用"插入代码或日志片段"按钮重新贴代码

public class MyNutTestRunner extends NutTestRunner {

    public MyNutTestRunner(Class<?> klass) throws InitializationError {
        super(klass);
    }

    public Class<?> getMainModule() {
        return MainModule.class;
    }
    
    /**
     * 可覆盖createIoc,实现参数覆盖, bean替换,等定制.
     */
    protected Ioc createIoc() {
        Ioc ioc = super.createIoc();
        SystemService service =  ioc.get(SystemService.class);
        System.out.println(service);
        
/*        PropertiesProxy conf = ioc.get(PropertiesProxy.class, "conf");
        conf.put("db.url", "jdbc:h2:~/test");*/
        return ioc;
    }
SimpleTest .java
@RunWith(MyNutTestRunner.class)
@IocBean // 必须有
@InjectName
public class SimpleTest extends Assert {
    
    //private static final Log log = Logs.get();
    
    // 跟通常的@Inject完全一样.
    @Inject("refer:$ioc")
    protected Ioc ioc;
    
    @Inject
    protected Dao dao;
    @Inject
    private SystemService service;
    
    @org.junit.Test
    public void test_user_service_create_user() {
/*    	//Ioc ioc = Mvcs.ctx().getDefaultIoc();
    	System.out.println(service);
    	SystemService service = ioc.get(SystemService.class);*/
    	StartPageModel model =  service.getStartPageByDate();
    	System.out.println(model);
/*        dao.create(User.class, false);
        User user = new User("wendal", "1234512345");
        dao.insert(user);
        
        user = dao.fetch(User.class, "wendal");
        assertNotNull(user);
        assertNotNull(user.getName());*/
    }
}

dao属性是null?

后台日志也贴一下

dao有的,我在js中手动注入的。

simpleTest : {
		type : "test.SimpleTest",
		fields : {
			dao : { refer : "dao" },
			service:{refer:"systemService"}
		}	
	}

不手动注入dao也是空的

不需要在js里面声明test类,删掉

然后贴后台日志

好吧删掉日志好多

2017-06-22 14:35:44,602 [main] INFO  org.nutz.resource.impl.ErrorResourceLocation - [loc=D:\%e8%bd%af%e4%bb%b6\eclipse\eclipse\configuration\org.eclipse.osgi\383\0\.cp]not exist
2017-06-22 14:35:44,602 [main] INFO  org.nutz.resource.impl.ErrorResourceLocation - [loc=D:\%e8%bd%af%e4%bb%b6\eclipse\eclipse\configuration\org.eclipse.osgi\383\0\.cp]not exist
2017-06-22 14:35:44,606 [main] INFO  org.nutz.resource.impl.ErrorResourceLocation - [loc=D:\%e8%bd%af%e4%bb%b6\eclipse\eclipse\configuration\org.eclipse.osgi\382\0\.cp]not exist
2017-06-22 14:35:44,606 [main] INFO  org.nutz.resource.impl.ErrorResourceLocation - [loc=D:\%e8%bd%af%e4%bb%b6\eclipse\eclipse\configuration\org.eclipse.osgi\382\0\.cp]not exist
2017-06-22 14:35:45,448 [main] DEBUG org.nutz.resource.Scans - Locations for Scans:
[Dir[path=E:\workspace4\juhe_live_mobile], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\nutz-1.r.60-20161201.073210-3.jar], ErrorResourceLocation [loc=D:\%e8%bd%af%e4%bb%b6\eclipse\eclipse\configuration\org.eclipse.osgi\383\0\.cp], ErrorResourceLocation [loc=D:\%e8%bd%af%e4%bb%b6\eclipse\eclipse\configuration\org.eclipse.osgi\382\0\.cp], Dir[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\classes], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\c3p0-0.9.1.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-beanutils-1.8.3.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-codec-1.7.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-collections-3.2.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-dbcp.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-fileupload-1.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-httpclient-3.0.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-io-2.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-lang-2.6.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-lang3-3.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-logging-1.0.3.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-pool.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\druid-1.0.16.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\fastjson-1.1.22.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\fluent-hc-4.3.4.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\freemarker.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\gson-2.2.2.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\guagua-zone-apisdk-1.005.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\guagua_base_util-1.0.2624.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\guagua_user-1.0.3605.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\guava-13.0.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\httpclient-4.4.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\httpclient-cache-4.3.4.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\httpcore-4.4.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\httpmime-4.4.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\ipaddress.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\jedis-2.1.0.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\jstl.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\jta1.0.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\log4j-1.2.14.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\log4j-1.2.17.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\mail.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\mockito-core-1.10.19.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\mysql-connector-java-5.1.26-bin.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\noggit-0.6.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\nutz-plugins-mock-1.r.60-20161201.074856-1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\servlet-api-2.5.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\slf4j-api-1.7.2.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\slf4j-log4j12-1.7.5.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\solr-core-5.3.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\solr-solrj-5.3.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\sqljdbc4.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\standard.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\thumbnailator-0.4.2.jar], Jar[path=D:\软件\eclipse\eclipse\plugins\org.junit_4.12.0.v201504281640\junit.jar], Jar[path=D:\软件\eclipse\eclipse\plugins\org.hamcrest.core_1.3.0.v201303031735.jar], Dir[path=D:\软件\eclipse\eclipse\configuration\org.eclipse.osgi\383\0\.cp], Dir[path=D:\软件\eclipse\eclipse\configuration\org.eclipse.osgi\382\0\.cp]]
2017-06-22 14:35:45,448 [main] DEBUG org.nutz.resource.Scans - Locations for Scans:
[Dir[path=E:\workspace4\juhe_live_mobile], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\nutz-1.r.60-20161201.073210-3.jar], ErrorResourceLocation [loc=D:\%e8%bd%af%e4%bb%b6\eclipse\eclipse\configuration\org.eclipse.osgi\383\0\.cp], ErrorResourceLocation [loc=D:\%e8%bd%af%e4%bb%b6\eclipse\eclipse\configuration\org.eclipse.osgi\382\0\.cp], Dir[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\classes], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\c3p0-0.9.1.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-beanutils-1.8.3.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-codec-1.7.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-collections-3.2.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-dbcp.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-fileupload-1.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-httpclient-3.0.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-io-2.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-lang-2.6.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-lang3-3.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-logging-1.0.3.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\commons-pool.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\druid-1.0.16.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\fastjson-1.1.22.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\fluent-hc-4.3.4.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\freemarker.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\gson-2.2.2.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\guagua-zone-apisdk-1.005.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\guagua_base_util-1.0.2624.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\guagua_user-1.0.3605.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\guava-13.0.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\httpclient-4.4.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\httpclient-cache-4.3.4.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\httpcore-4.4.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\httpmime-4.4.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\ipaddress.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\jedis-2.1.0.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\jstl.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\jta1.0.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\log4j-1.2.14.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\log4j-1.2.17.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\mail.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\mockito-core-1.10.19.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\mysql-connector-java-5.1.26-bin.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\noggit-0.6.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\nutz-plugins-mock-1.r.60-20161201.074856-1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\servlet-api-2.5.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\slf4j-api-1.7.2.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\slf4j-log4j12-1.7.5.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\solr-core-5.3.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\solr-solrj-5.3.1.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\sqljdbc4.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\standard.jar], Jar[path=E:\workspace4\juhe_live_mobile\WebContent\WEB-INF\lib\thumbnailator-0.4.2.jar], Jar[path=D:\软件\eclipse\eclipse\plugins\org.junit_4.12.0.v201504281640\junit.jar], Jar[path=D:\软件\eclipse\eclipse\plugins\org.hamcrest.core_1.3.0.v201303031735.jar], Dir[path=D:\软件\eclipse\eclipse\configuration\org.eclipse.osgi\383\0\.cp], Dir[path=D:\软件\eclipse\eclipse\configuration\org.eclipse.osgi\382\0\.cp]]
2017-06-22 14:35:45,501 [main] DEBUG org.nutz.resource.Scans - Found 17 resource by src( ioc/ ) , regex( ^(.+[.])(js|json)$ )
2017-06-22 14:35:45,501 [main] DEBUG org.nutz.resource.Scans - Found 17 resource by src( ioc/ ) , regex( ^(.+[.])(js|json)$ )
2017-06-22 14:35:45,505 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [activity.js]
2017-06-22 14:35:45,505 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [activity.js]
2017-06-22 14:35:45,574 [main] DEBUG org.nutz.castor.Castors - Using 94 castor for Castors
2017-06-22 14:35:45,574 [main] DEBUG org.nutz.castor.Castors - Using 94 castor for Castors
2017-06-22 14:35:45,578 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [aop.js]
2017-06-22 14:35:45,578 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [aop.js]
2017-06-22 14:35:45,579 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [avatarupload.js]
2017-06-22 14:35:45,579 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [avatarupload.js]
2017-06-22 14:35:45,582 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [codeupdate.js]
2017-06-22 14:35:45,582 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [codeupdate.js]
2017-06-22 14:35:45,585 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [dao.js]
2017-06-22 14:35:45,585 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [dao.js]
2017-06-22 14:35:45,587 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [feedback.js]
2017-06-22 14:35:45,587 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [feedback.js]
2017-06-22 14:35:45,588 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [follow.js]
2017-06-22 14:35:45,588 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [follow.js]
2017-06-22 14:35:45,591 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [index.js]
2017-06-22 14:35:45,591 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [index.js]
2017-06-22 14:35:45,594 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [log.js]
2017-06-22 14:35:45,594 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [log.js]
2017-06-22 14:35:45,595 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [mic.js]
2017-06-22 14:35:45,595 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [mic.js]
2017-06-22 14:35:45,601 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [noticePro.js]
2017-06-22 14:35:45,601 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [noticePro.js]
2017-06-22 14:35:45,604 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [pets.js]
2017-06-22 14:35:45,604 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [pets.js]
2017-06-22 14:35:45,604 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [reportdevice.js]
2017-06-22 14:35:45,604 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [reportdevice.js]
2017-06-22 14:35:45,605 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [room.js]
2017-06-22 14:35:45,605 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [room.js]
2017-06-22 14:35:45,606 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [system.js]
2017-06-22 14:35:45,606 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [system.js]
2017-06-22 14:35:45,607 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [test.js]
2017-06-22 14:35:45,607 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [test.js]
2017-06-22 14:35:45,608 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [user.js]
2017-06-22 14:35:45,608 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - loading ioc js config from [user.js]
2017-06-22 14:35:45,609 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - Loaded 66 bean define from path=[ioc/] --> [feedbackService, userLogic, test, userService, signCheckInterceptor, noticeService, verifyCodeUtil, $aop, tmpFilePool, activityModule, userAvatarService, roomDataService, activityProvideService, followProvideService, pets, noticeProModule, reportDeviceModule, reportDeviceDao, roomInfoService, indexModule, indexHepler, indexService, broadcastInfoService, daoLive, followRulesService, rsService, followRoomProvideService, daofollows, followModule, logModule, dao, systemService, daoSource, searchVerProvideService, daounicom, daolive, codeUpdateProvideService, systemModule, userValidityInterceptor, userModule, unicomService, roomFaceService, activityLogic, beforeVerProvideService, daoUniom, noticeProvideService, micService, uploadMediaContext, guaguaJsonView, userChatService, roomLogic, rsProvideService, followService, activityService, roomInfoProvideService, myMediaUpload, logInterceptor, roomModule, baseDataService, utils, followLogic, feedBackModule, roomService, petModule, reportDeviceService, masters]
2017-06-22 14:35:45,609 [main] DEBUG org.nutz.ioc.loader.json.JsonLoader - Loaded 66 bean define from path=[ioc/] --> [feedbackService, userLogic, test, userService, signCheckInterceptor, noticeService, verifyCodeUtil, $aop, tmpFilePool, activityModule, userAvatarService, roomDataService, activityProvideService, followProvideService, pets, noticeProModule, reportDeviceModule, reportDeviceDao, roomInfoService, indexModule, indexHepler, indexService, broadcastInfoService, daoLive, followRulesService, rsService, followRoomProvideService, daofollows, followModule, logModule, dao, systemService, daoSource, searchVerProvideService, daounicom, daolive, codeUpdateProvideService, systemModule, userValidityInterceptor, userModule, unicomService, roomFaceService, activityLogic, beforeVerProvideService, daoUniom, noticeProvideService, micService, uploadMediaContext, guaguaJsonView, userChatService, roomLogic, rsProvideService, followService, activityService, roomInfoProvideService, myMediaUpload, logInterceptor, roomModule, baseDataService, utils, followLogic, feedBackModule, roomService, petModule, reportDeviceService, masters]
2017-06-22 14:35:45,613 [main] WARN  org.nutz.ioc.loader.annotation.AnnotationIocLoader - NONE Annotation-Class found!! Check your ioc configure!! packages=[]
2017-06-22 14:35:45,613 [main] WARN  org.nutz.ioc.loader.annotation.AnnotationIocLoader - NONE Annotation-Class found!! Check your ioc configure!! packages=[]
2017-06-22 14:35:45,619 [main] INFO  org.nutz.ioc.impl.NutIoc - NutIoc init begin ...
2017-06-22 14:35:45,619 [main] INFO  org.nutz.ioc.impl.NutIoc - NutIoc init begin ...
2017-06-22 14:35:45,622 [main] INFO  org.nutz.ioc.impl.NutIoc - ... NutIoc init complete
2017-06-22 14:35:45,622 [main] INFO  org.nutz.ioc.impl.NutIoc - ... NutIoc init complete
2017-06-22 14:35:45,622 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'systemService'<class cn.guagua.mobile.system.SystemService>
2017-06-22 14:35:45,622 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'systemService'<class cn.guagua.mobile.system.SystemService>
2017-06-22 14:35:45,623 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get '$aop'<interface org.nutz.ioc.aop.config.AopConfigration>
2017-06-22 14:35:45,623 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get '$aop'<interface org.nutz.ioc.aop.config.AopConfigration>
2017-06-22 14:35:45,624 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=$aop
2017-06-22 14:35:45,624 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=$aop
2017-06-22 14:35:45,625 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=$aop
2017-06-22 14:35:45,625 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=$aop
2017-06-22 14:35:45,629 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject($aop) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:45,629 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject($aop) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:45,629 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'$aop'<interface org.nutz.ioc.aop.config.AopConfigration>
2017-06-22 14:35:45,629 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'$aop'<interface org.nutz.ioc.aop.config.AopConfigration>
2017-06-22 14:35:45,631 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object '$aop' to [app] 
2017-06-22 14:35:45,631 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object '$aop' to [app] 
2017-06-22 14:35:45,638 [main] DEBUG org.nutz.ioc.aop.SimpleAopMaker - Load AopConfigure for anno=org.nutz.ioc.aop.Aop by type=org.nutz.ioc.aop.config.impl.AnnotationAopConfigration
2017-06-22 14:35:45,638 [main] DEBUG org.nutz.ioc.aop.SimpleAopMaker - Load AopConfigure for anno=org.nutz.ioc.aop.Aop by type=org.nutz.ioc.aop.config.impl.AnnotationAopConfigration
2017-06-22 14:35:45,642 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=systemService
2017-06-22 14:35:45,642 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=systemService
2017-06-22 14:35:45,642 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=systemService
2017-06-22 14:35:45,642 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=systemService
2017-06-22 14:35:45,644 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(systemService) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:45,644 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(systemService) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:45,645 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'systemService'<class cn.guagua.mobile.system.SystemService>
2017-06-22 14:35:45,645 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'systemService'<class cn.guagua.mobile.system.SystemService>
2017-06-22 14:35:45,664 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class cn.guagua.mobile.system.SystemService without AOP
2017-06-22 14:35:45,664 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class cn.guagua.mobile.system.SystemService without AOP
2017-06-22 14:35:45,665 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'systemService' to [app] 
2017-06-22 14:35:45,665 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'systemService' to [app] 
2017-06-22 14:35:45,666 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'dao'<>
2017-06-22 14:35:45,666 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'dao'<>
2017-06-22 14:35:45,667 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=dao
2017-06-22 14:35:45,667 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=dao
2017-06-22 14:35:45,667 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=dao
2017-06-22 14:35:45,667 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=dao
2017-06-22 14:35:45,670 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(dao) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:45,670 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(dao) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:45,671 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'dao'<>
2017-06-22 14:35:45,671 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'dao'<>
2017-06-22 14:35:45,683 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class org.nutz.dao.impl.NutDao without AOP
2017-06-22 14:35:45,683 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class org.nutz.dao.impl.NutDao without AOP
2017-06-22 14:35:45,684 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'dao' to [app] 
2017-06-22 14:35:45,684 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'dao' to [app] 
2017-06-22 14:35:45,685 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daoSource'<>
2017-06-22 14:35:45,685 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daoSource'<>
2017-06-22 14:35:45,685 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=daoSource
2017-06-22 14:35:45,685 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=daoSource
2017-06-22 14:35:45,686 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=daoSource
2017-06-22 14:35:45,686 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=daoSource
2017-06-22 14:35:45,694 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(daoSource) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:45,694 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(daoSource) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:45,694 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'daoSource'<>
2017-06-22 14:35:45,694 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'daoSource'<>
2017-06-22 14:35:45,732 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class com.alibaba.druid.pool.DruidDataSource without AOP
2017-06-22 14:35:45,732 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class com.alibaba.druid.pool.DruidDataSource without AOP
2017-06-22 14:35:45,733 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'daoSource' to [app] 
2017-06-22 14:35:45,733 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'daoSource' to [app] 
2017-06-22 14:35:45,762 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daoSource'<>
2017-06-22 14:35:45,762 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daoSource'<>
2017-06-22 14:35:45,771 [main] DEBUG org.nutz.dao.impl.NutDao - NutDao[_selfId=0] init ...
2017-06-22 14:35:45,771 [main] DEBUG org.nutz.dao.impl.NutDao - NutDao[_selfId=0] init ...
2017-06-22 14:35:45,800 [main] INFO  org.nutz.filepool.NutFilePool - Init file-pool by: C:\Users\Administrator/.nutz/tmp/dao/ [200000]
2017-06-22 14:35:45,800 [main] INFO  org.nutz.filepool.NutFilePool - Init file-pool by: C:\Users\Administrator/.nutz/tmp/dao/ [200000]
2017-06-22 14:35:45,801 [main] DEBUG org.nutz.filepool.NutFilePool - file-pool.home: 'C:\Users\Administrator\.nutz\tmp\dao'
2017-06-22 14:35:45,801 [main] DEBUG org.nutz.filepool.NutFilePool - file-pool.home: 'C:\Users\Administrator\.nutz\tmp\dao'
2017-06-22 14:35:45,803 [main] INFO  org.nutz.filepool.NutFilePool - file-pool.cursor: 0
2017-06-22 14:35:45,803 [main] INFO  org.nutz.filepool.NutFilePool - file-pool.cursor: 0
2017-06-22 14:35:45,813 [main] DEBUG org.nutz.dao.jdbc.Jdbcs - Jdbcs init complete
2017-06-22 14:35:45,813 [main] DEBUG org.nutz.dao.jdbc.Jdbcs - Jdbcs init complete
2017-06-22 14:35:45,813 [main] INFO  org.nutz.dao.jdbc.Jdbcs - Get Connection from DataSource for JdbcExpert, if you look at here, check your database server and configure
2017-06-22 14:35:45,813 [main] INFO  org.nutz.dao.jdbc.Jdbcs - Get Connection from DataSource for JdbcExpert, if you look at here, check your database server and configure
2017-06-22 14:35:45,978 [main] ERROR com.alibaba.druid.pool.DruidDataSource - testWhileIdle is true, validationQuery not set
2017-06-22 14:35:45,994 [main] INFO  com.alibaba.druid.pool.DruidDataSource - {dataSource-1} inited
2017-06-22 14:35:46,507 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC Driver --> 2.0.1803.100
2017-06-22 14:35:46,507 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC Driver --> 2.0.1803.100
2017-06-22 14:35:46,507 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC Name   --> Microsoft SQL Server JDBC Driver 2.0
2017-06-22 14:35:46,507 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC Name   --> Microsoft SQL Server JDBC Driver 2.0
2017-06-22 14:35:46,508 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC URL    --> jdbc:sqlserver://120.132.38.209:21003;xopenStates=false;trustServerCertificate=false;sendStringParametersAsUnicode=true;selectMethod=direct;responseBuffering=adaptive;packetSize=8000;loginTimeout=15;lockTimeout=-1;lastUpdateCount=true;encrypt=false;disableStatementPooling=true;databaseName=juhe_livemobile_dev;applicationName=Microsoft SQL Server JDBC Driver;
2017-06-22 14:35:46,508 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC URL    --> jdbc:sqlserver://120.132.38.209:21003;xopenStates=false;trustServerCertificate=false;sendStringParametersAsUnicode=true;selectMethod=direct;responseBuffering=adaptive;packetSize=8000;loginTimeout=15;lockTimeout=-1;lastUpdateCount=true;encrypt=false;disableStatementPooling=true;databaseName=juhe_livemobile_dev;applicationName=Microsoft SQL Server JDBC Driver;
2017-06-22 14:35:46,508 [main] DEBUG org.nutz.dao.impl.DaoSupport - Database info --> SQLSERVER:[Microsoft SQL Server - 10.00.5500]
2017-06-22 14:35:46,508 [main] DEBUG org.nutz.dao.impl.DaoSupport - Database info --> SQLSERVER:[Microsoft SQL Server - 10.00.5500]
2017-06-22 14:35:46,512 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'dao'<>
2017-06-22 14:35:46,512 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'dao'<>
2017-06-22 14:35:46,513 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'baseDataService'<>
2017-06-22 14:35:46,513 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'baseDataService'<>
2017-06-22 14:35:46,513 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=baseDataService
2017-06-22 14:35:46,513 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=baseDataService
2017-06-22 14:35:46,514 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=baseDataService
2017-06-22 14:35:46,514 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=baseDataService
2017-06-22 14:35:46,514 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(baseDataService) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:46,514 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(baseDataService) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:46,515 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'baseDataService'<>
2017-06-22 14:35:46,515 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'baseDataService'<>
2017-06-22 14:35:46,515 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class cn.guagua.mobile.remote.basedata.BaseDataService without AOP
2017-06-22 14:35:46,515 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class cn.guagua.mobile.remote.basedata.BaseDataService without AOP
2017-06-22 14:35:46,515 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'baseDataService' to [app] 
2017-06-22 14:35:46,515 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'baseDataService' to [app] 
2017-06-22 14:35:46,517 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'unicomService'<>
2017-06-22 14:35:46,517 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'unicomService'<>
2017-06-22 14:35:46,517 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=unicomService
2017-06-22 14:35:46,517 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=unicomService
2017-06-22 14:35:46,518 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=unicomService
2017-06-22 14:35:46,518 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=unicomService
2017-06-22 14:35:46,518 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(unicomService) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:46,518 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(unicomService) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:46,519 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'unicomService'<>
2017-06-22 14:35:46,519 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'unicomService'<>
2017-06-22 14:35:46,519 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class cn.guagua.mobile.remote.basedata.UnicomService without AOP
2017-06-22 14:35:46,519 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class cn.guagua.mobile.remote.basedata.UnicomService without AOP
2017-06-22 14:35:46,520 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'unicomService' to [app] 
2017-06-22 14:35:46,520 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'unicomService' to [app] 
2017-06-22 14:35:46,520 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daounicom'<>
2017-06-22 14:35:46,520 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daounicom'<>
2017-06-22 14:35:46,521 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=daounicom
2017-06-22 14:35:46,521 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=daounicom
2017-06-22 14:35:46,521 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=daounicom
2017-06-22 14:35:46,521 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=daounicom
2017-06-22 14:35:46,522 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(daounicom) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:46,522 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(daounicom) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:46,529 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'daounicom'<>
2017-06-22 14:35:46,529 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'daounicom'<>
2017-06-22 14:35:46,530 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class org.nutz.dao.impl.NutDao without AOP
2017-06-22 14:35:46,530 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class org.nutz.dao.impl.NutDao without AOP
2017-06-22 14:35:46,530 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'daounicom' to [app] 
2017-06-22 14:35:46,530 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'daounicom' to [app] 
2017-06-22 14:35:46,531 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daoUniom'<>
2017-06-22 14:35:46,531 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daoUniom'<>
2017-06-22 14:35:46,531 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=daoUniom
2017-06-22 14:35:46,531 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=daoUniom
2017-06-22 14:35:46,531 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=daoUniom
2017-06-22 14:35:46,531 [main] DEBUG org.nutz.ioc.loader.map.MapLoader - Loading define for name=daoUniom
2017-06-22 14:35:46,532 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(daoUniom) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:46,532 [main] DEBUG org.nutz.ioc.loader.combo.ComboIocLoader - Found IocObject(daoUniom) in JsonLoader(paths=[ioc/])
2017-06-22 14:35:46,533 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'daoUniom'<>
2017-06-22 14:35:46,533 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Make...'daoUniom'<>
2017-06-22 14:35:46,533 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class com.alibaba.druid.pool.DruidDataSource without AOP
2017-06-22 14:35:46,533 [main] DEBUG org.nutz.ioc.aop.impl.DefaultMirrorFactory - Load class com.alibaba.druid.pool.DruidDataSource without AOP
2017-06-22 14:35:46,534 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'daoUniom' to [app] 
2017-06-22 14:35:46,534 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Save object 'daoUniom' to [app] 
2017-06-22 14:35:46,535 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daoUniom'<>
2017-06-22 14:35:46,535 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daoUniom'<>
2017-06-22 14:35:46,536 [main] DEBUG org.nutz.dao.impl.NutDao - NutDao[_selfId=1] init ...
2017-06-22 14:35:46,536 [main] DEBUG org.nutz.dao.impl.NutDao - NutDao[_selfId=1] init ...
2017-06-22 14:35:46,536 [main] INFO  org.nutz.dao.jdbc.Jdbcs - Get Connection from DataSource for JdbcExpert, if you look at here, check your database server and configure
2017-06-22 14:35:46,536 [main] INFO  org.nutz.dao.jdbc.Jdbcs - Get Connection from DataSource for JdbcExpert, if you look at here, check your database server and configure
2017-06-22 14:35:46,537 [main] ERROR com.alibaba.druid.pool.DruidDataSource - testWhileIdle is true, validationQuery not set
2017-06-22 14:35:46,539 [main] INFO  com.alibaba.druid.pool.DruidDataSource - {dataSource-2} inited
2017-06-22 14:35:46,579 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC Driver --> 2.0.1803.100
2017-06-22 14:35:46,579 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC Driver --> 2.0.1803.100
2017-06-22 14:35:46,579 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC Name   --> Microsoft SQL Server JDBC Driver 2.0
2017-06-22 14:35:46,579 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC Name   --> Microsoft SQL Server JDBC Driver 2.0
2017-06-22 14:35:46,580 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC URL    --> jdbc:sqlserver://120.132.38.209:21003;xopenStates=false;trustServerCertificate=false;sendStringParametersAsUnicode=true;selectMethod=direct;responseBuffering=adaptive;packetSize=8000;loginTimeout=15;lockTimeout=-1;lastUpdateCount=true;encrypt=false;disableStatementPooling=true;databaseName=juhe_unicom;applicationName=Microsoft SQL Server JDBC Driver;
2017-06-22 14:35:46,580 [main] DEBUG org.nutz.dao.impl.DaoSupport - JDBC URL    --> jdbc:sqlserver://120.132.38.209:21003;xopenStates=false;trustServerCertificate=false;sendStringParametersAsUnicode=true;selectMethod=direct;responseBuffering=adaptive;packetSize=8000;loginTimeout=15;lockTimeout=-1;lastUpdateCount=true;encrypt=false;disableStatementPooling=true;databaseName=juhe_unicom;applicationName=Microsoft SQL Server JDBC Driver;
2017-06-22 14:35:46,580 [main] DEBUG org.nutz.dao.impl.DaoSupport - Database info --> SQLSERVER:[Microsoft SQL Server - 10.00.5500]
2017-06-22 14:35:46,580 [main] DEBUG org.nutz.dao.impl.DaoSupport - Database info --> SQLSERVER:[Microsoft SQL Server - 10.00.5500]
2017-06-22 14:35:46,581 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daounicom'<>
2017-06-22 14:35:46,581 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'daounicom'<>
cn.guagua.mobile.system.SystemService@68cf9105
2017-06-22 14:35:46,583 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'simpleTest'<class test.SimpleTest>
2017-06-22 14:35:46,583 [main] DEBUG org.nutz.ioc.impl.NutIoc - Get 'simpleTest'<class test.SimpleTest>
2017-06-22 14:35:46,583 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=simpleTest
2017-06-22 14:35:46,583 [main] DEBUG org.nutz.ioc.impl.NutIoc - 	 >> Load definition name=simpleTest
2017-06-22 14:35:46,591 [main] INFO  org.nutz.ioc.impl.NutIoc - org.nutz.ioc.impl.NutIoc@1213037502 is closing. startup date [17-06-22 14:35:45.620]
2017-06-22 14:35:46,591 [main] INFO  org.nutz.ioc.impl.NutIoc - org.nutz.ioc.impl.NutIoc@1213037502 is closing. startup date [17-06-22 14:35:45.620]
2017-06-22 14:35:46,591 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'daounicom' ...
2017-06-22 14:35:46,591 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'daounicom' ...
2017-06-22 14:35:46,592 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'unicomService' ...
2017-06-22 14:35:46,592 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'unicomService' ...
2017-06-22 14:35:46,592 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'baseDataService' ...
2017-06-22 14:35:46,592 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'baseDataService' ...
2017-06-22 14:35:46,592 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'dao' ...
2017-06-22 14:35:46,592 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'dao' ...
2017-06-22 14:35:46,593 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'systemService' ...
2017-06-22 14:35:46,593 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'systemService' ...
2017-06-22 14:35:46,594 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object '$aop' ...
2017-06-22 14:35:46,594 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object '$aop' ...
2017-06-22 14:35:46,594 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'daoUniom' ...
2017-06-22 14:35:46,594 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'daoUniom' ...
2017-06-22 14:35:46,597 [main] INFO  com.alibaba.druid.pool.DruidDataSource - {dataSource-2} closed
2017-06-22 14:35:46,597 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'daoSource' ...
2017-06-22 14:35:46,597 [main] DEBUG org.nutz.ioc.impl.ScopeContext - Depose object 'daoSource' ...
2017-06-22 14:35:46,598 [main] INFO  com.alibaba.druid.pool.DruidDataSource - {dataSource-1} closed
2017-06-22 14:35:46,598 [main] INFO  org.nutz.ioc.impl.NutIoc - org.nutz.ioc.impl.NutIoc@1213037502 is deposed. startup date [17-06-22 14:35:45.620]
2017-06-22 14:35:46,598 [main] INFO  org.nutz.ioc.impl.NutIoc - org.nutz.ioc.impl.NutIoc@1213037502 is deposed. startup date [17-06-22 14:35:45.620]

报错的信息

org.nutz.ioc.IocException: [simpleTest] # For object [simpleTest] - type:[class test.SimpleTest]
	at org.nutz.ioc.impl.NutIoc.get(NutIoc.java:218)
	at org.nutz.ioc.impl.NutIoc.get(NutIoc.java:239)
	at org.nutz.ioc.impl.NutIoc.get(NutIoc.java:146)
	at org.nutz.mock.NutTestRunner.createTest(NutTestRunner.java:71)
	at org.junit.runners.BlockJUnit4ClassRunner$1.runReflectiveCall(BlockJUnit4ClassRunner.java:266)
	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
	at org.junit.runners.BlockJUnit4ClassRunner.methodBlock(BlockJUnit4ClassRunner.java:263)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
	at org.nutz.mock.NutTestRunner.runChild(NutTestRunner.java:33)
	at org.nutz.mock.NutTestRunner.runChild(NutTestRunner.java:14)
	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
	at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86)
	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)
Caused by: org.nutz.ioc.ObjectLoadException: Object 'simpleTest' without define!
	at org.nutz.ioc.loader.combo.ComboIocLoader.load(ComboIocLoader.java:174)
	at org.nutz.ioc.impl.NutIoc.get(NutIoc.java:180)
	... 21 more

所有bean都是用js配的??? @IocBy贴一下, *anno后面肯定缺了参数.

另外,你的日志配得有问题, 全部打印2次了.

所有的bean好像都得在js中配一遍。
MainModule.java

@Modules(scanPackage=true)
@IocBy(type = ComboIocProvider.class, args = {"*js", "ioc/","*org.nutz.ioc.loader.annotation.AnnotationIocLoader"})
@SetupBy(HelloMvcSetup.class)
@Localization("msg")
@Views({GuaguaViewMaker.class})
@Ok("ggjson")
@Fail("errMsg")
public class MainModule {}

因为你配错咯, AnnotationIocLoader后面就没带参数,所有@IocBean/@Inject都不会生效.

@IocBy(type = ComboIocProvider.class, args = {"*js", "ioc/","*anno", "你的package"})

把这个改对之后, 标注了@IocBean的类,就不要在js里面配了,统统干掉

改成你的这种样子可以不在js中配了,但如果有两层包呢,一个是cn包下的,一个根包text下的,
那个你的package那怎么写呢

anno可以多个参数

试了在后面在加个包路径可以,junit 测试是不是不走@SetupBy配置的setup

@wendal 好的另外使用mock测试请求,有没有代码可参考呢

看mocktio库吧

@wendal mvcmock重新开个贴你看看。

添加回复
请先登陆
回到顶部