private MessageSource configure(final AbstractResourceBasedMessageSource bean,
                                    final CasConfigurationProperties casProperties) {
        val mb = casProperties.getMessageBundle();
        bean.setDefaultEncoding(mb.getEncoding());
        bean.setCacheSeconds(Long.valueOf(Beans.newDuration(mb.getCacheSeconds()).toSeconds()).intValue());
        bean.setFallbackToSystemLocale(mb.isFallbackSystemLocale());
        bean.setUseCodeAsDefaultMessage(mb.isUseCodeMessage());
        bean.setBasenames(mb.getBaseNames().toArray(ArrayUtils.EMPTY_STRING_ARRAY));
        bean.setCommonMessages(getCommonMessages());
        return bean;
    }
Configure message source.

@param bean          the bean
@param casProperties the cas properties
@return the message source
core/cas-server-core-web-api/src/main/java/org/apereo/cas/web/view/CasReloadableMessageBundle.java