本文整理汇总了Java中org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer类的典型用法代码示例。如果您正苦于以下问题:Java JCacheManagerCustomizer类的具体用法?Java JCacheManagerCustomizer怎么用?Java JCacheManagerCustomizer使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
JCacheManagerCustomizer类属于org.springframework.boot.autoconfigure.cache包,在下文中一共展示了JCacheManagerCustomizer类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: cacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer cacheManagerCustomizer() {
return cm -> {
cm.createCache(com.microsoft.labrat.domain.User.class.getName(), jcacheConfiguration);
cm.createCache(com.microsoft.labrat.domain.Authority.class.getName(), jcacheConfiguration);
cm.createCache(com.microsoft.labrat.domain.User.class.getName() + ".authorities", jcacheConfiguration);
cm.createCache(com.microsoft.labrat.domain.PersistentToken.class.getName(), jcacheConfiguration);
cm.createCache(com.microsoft.labrat.domain.User.class.getName() + ".persistentTokens", jcacheConfiguration);
cm.createCache(com.microsoft.labrat.domain.SocialUserConnection.class.getName(), jcacheConfiguration);
cm.createCache(com.microsoft.labrat.domain.Participant.class.getName(), jcacheConfiguration);
cm.createCache(com.microsoft.labrat.domain.Device.class.getName(), jcacheConfiguration);
cm.createCache(com.microsoft.labrat.domain.Lease.class.getName(), jcacheConfiguration);
cm.createCache(com.microsoft.labrat.domain.Intervention.class.getName(), jcacheConfiguration);
// jhipster-needle-ehcache-add-entry
};
}
示例2: cacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer cacheManagerCustomizer() {
return cm -> {
cm.createCache(com.idurdyev.torgcrm.jhipster.repository.UserRepository.USERS_BY_LOGIN_CACHE, jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.repository.UserRepository.USERS_BY_EMAIL_CACHE, jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.User.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Authority.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.User.class.getName() + ".authorities", jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Project.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Customer.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Customer.class.getName() + ".projects", jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Customer.class.getName() + ".deals", jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Employee.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Department.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Deal.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Task.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Menu.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.MenuItem.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Menu.class.getName() + ".items", jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.CustomerType.class.getName(), jcacheConfiguration);
cm.createCache(com.idurdyev.torgcrm.jhipster.domain.Manager.class.getName(), jcacheConfiguration);
// jhipster-needle-ehcache-add-entry
};
}
示例3: cacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer cacheManagerCustomizer() {
return cm -> {
cm.createCache(com.springio.store.domain.User.class.getName(), jcacheConfiguration);
cm.createCache(com.springio.store.domain.Authority.class.getName(), jcacheConfiguration);
cm.createCache(com.springio.store.domain.User.class.getName() + ".authorities", jcacheConfiguration);
cm.createCache(com.springio.store.domain.SocialUserConnection.class.getName(), jcacheConfiguration);
cm.createCache(com.springio.store.domain.Brand.class.getName(), jcacheConfiguration);
cm.createCache(com.springio.store.domain.Brand.class.getName() + ".products", jcacheConfiguration);
cm.createCache(com.springio.store.domain.Product.class.getName(), jcacheConfiguration);
cm.createCache(com.springio.store.domain.Product.class.getName() + ".subcategories", jcacheConfiguration);
cm.createCache(com.springio.store.domain.Category.class.getName(), jcacheConfiguration);
cm.createCache(com.springio.store.domain.Category.class.getName() + ".subcategories", jcacheConfiguration);
cm.createCache(com.springio.store.domain.SubCategory.class.getName(), jcacheConfiguration);
cm.createCache(com.springio.store.domain.SubCategory.class.getName() + ".products", jcacheConfiguration);
// jhipster-needle-ehcache-add-entry
};
}
示例4: cacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer cacheManagerCustomizer() {
return cm -> {
cm.createCache("users", jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.User.class.getName(), jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.Authority.class.getName(), jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.User.class.getName() + ".authorities", jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.PersistentToken.class.getName(), jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.User.class.getName() + ".persistentTokens", jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.Campagne.class.getName(), jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.Campagne.class.getName() + ".testeurs", jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.Application.class.getName(), jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.TypeTest.class.getName(), jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.Resultat.class.getName(), jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.Testeur.class.getName(), jcacheConfiguration);
cm.createCache(io.github.pascalgrimaud.qualitoast.domain.Testeur.class.getName() + ".campagnes", jcacheConfiguration);
// jhipster-needle-ehcache-add-entry
};
}
示例5: cacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer cacheManagerCustomizer() {
return cm -> {
<%_ if (authenticationType === 'oauth2' && applicationType === 'microservice') { _%>
cm.createCache("oAuth2Authentication", jcacheConfiguration);
<%_ } _%>
<%_ if (!skipUserManagement || (authenticationType === 'oauth2' && applicationType === 'monolith')) { _%>
cm.createCache(<%=packageName%>.repository.UserRepository.USERS_BY_LOGIN_CACHE, jcacheConfiguration);
cm.createCache(<%=packageName%>.repository.UserRepository.USERS_BY_EMAIL_CACHE, jcacheConfiguration);
<%_ if (enableHibernateCache) { _%>
cm.createCache(<%=packageName%>.domain.User.class.getName(), jcacheConfiguration);
cm.createCache(<%=packageName%>.domain.Authority.class.getName(), jcacheConfiguration);
cm.createCache(<%=packageName%>.domain.User.class.getName() + ".authorities", jcacheConfiguration);
<%_ if (authenticationType === 'session') { _%>
cm.createCache(<%=packageName%>.domain.PersistentToken.class.getName(), jcacheConfiguration);
cm.createCache(<%=packageName%>.domain.User.class.getName() + ".persistentTokens", jcacheConfiguration);
<%_ } _%>
<%_ if (enableSocialSignIn) { _%>
cm.createCache(<%=packageName%>.domain.SocialUserConnection.class.getName(), jcacheConfiguration);
<%_ } _%>
<%_ } _%>
<%_ } _%>
// jhipster-needle-ehcache-add-entry
};
}
示例6: initializrCacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer initializrCacheManagerCustomizer() {
return cm -> {
cm.createCache("initializr", config().setExpiryPolicyFactory(
CreatedExpiryPolicy.factoryOf(Duration.TEN_MINUTES)));
cm.createCache("dependency-metadata", config());
cm.createCache("project-resources", config());
};
}
示例7: cacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer cacheManagerCustomizer() {
return cm -> {
Configuration<Object, Object> cacheConfiguration = createCacheConfiguration();
cm.createCache("vets", cacheConfiguration);
};
}
示例8: cacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer cacheManagerCustomizer() {
return cm -> {
cm.createCache(com.sgcs.speaktogether.domain.User.class.getName(), jcacheConfiguration);
cm.createCache(com.sgcs.speaktogether.domain.Authority.class.getName(), jcacheConfiguration);
cm.createCache(com.sgcs.speaktogether.domain.User.class.getName() + ".authorities", jcacheConfiguration);
// jhipster-needle-ehcache-add-entry
};
}
示例9: cacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer cacheManagerCustomizer() {
return cm -> {
cm.createCache("users", jcacheConfiguration);
cm.createCache(codemotion.domain.User.class.getName(), jcacheConfiguration);
cm.createCache(codemotion.domain.Authority.class.getName(), jcacheConfiguration);
cm.createCache(codemotion.domain.User.class.getName() + ".authorities", jcacheConfiguration);
cm.createCache(codemotion.domain.Task.class.getName(), jcacheConfiguration);
cm.createCache(codemotion.domain.Category.class.getName(), jcacheConfiguration);
cm.createCache(codemotion.domain.Category.class.getName() + ".tasks", jcacheConfiguration);
// jhipster-needle-ehcache-add-entry
};
}
示例10: initializrCacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer initializrCacheManagerCustomizer() {
return cm -> {
cm.createCache("initializr.metadata", config().setExpiryPolicyFactory(
CreatedExpiryPolicy.factoryOf(Duration.TEN_MINUTES)));
cm.createCache("initializr.dependency-metadata", config());
cm.createCache("initializr.project-resources", config());
};
}
示例11: cacheManagerCustomizer
import org.springframework.boot.autoconfigure.cache.JCacheManagerCustomizer; //导入依赖的package包/类
@Bean
public JCacheManagerCustomizer cacheManagerCustomizer() {
return new CustomerJCacheManagerCustomizer();
}