}
// initializing the query module command initializer.
// we can t inject Cache and CacheManager with @inject in there
Cache<?, ?> cache = cr.getComponent(Cache.class);
CommandInitializer initializer = cr.getComponent(CommandInitializer.class);
EmbeddedCacheManager cacheManager = cr.getGlobalComponentRegistry().getComponent(EmbeddedCacheManager.class);
initializer.setCache(cache, cacheManager);
QueryBox queryBox = new QueryBox();
queryBox.setCache(cache.getAdvancedCache());
cr.registerComponent(queryBox, QueryBox.class);