Buggy code:
public class Config implements AuthConstants { private static final Logger logger = LoggerFactory . getLogger ( Config . class ) ; private static final Config instance = new Config ( ) ; private static final String PASSWORD = "password" ; private static final String ACCESS_KEY = "accesskey" ; private ServletContext context = null ; private TokenCache < String , String > client = null ; private AuthClientFactory factory = null ; private String serviceIds ; private String endpointIds ; private long timeToCacheToken ; private boolean delayAuthDecision ; private int retries ; private int pauseTime ; private String authVersion ; private boolean includeCatalog ; private String adminAuthMethod ; private String adminProjectId ; private volatile boolean initialized = false ; private FilterConfig filterConfig ; private Config ( ) { } public static Config getInstance ( ) { } public synchronized void initialize ( FilterConfig config , ServletRequest req , Map < String , String > map ) throws ServletException { this . context = config . getServletContext ( ) ; this . filterConfig = config ; try { serviceIds = filterConfig . getInitParameter ( SERVICE_IDS ) ; endpointIds = filterConfig . getInitParameter ( ENDPOINT_IDS ) ; String host = filterConfig . getInitParameter ( SERVER_VIP ) ; int port = Integer . parseInt ( filterConfig . getInitParameter ( SERVER_PORT ) ) ; authVersion = getValue ( AUTH_VERSION , "v3.0" ) ; if ( ( ( ( ( serviceIds ) == null ) || ( serviceIds . isEmpty ( ) ) ) && ( ( ( endpointIds ) == null ) || ( endpointIds . isEmpty ( ) ) ) ) && ( authVersion . equalsIgnoreCase ( "v2.0" ) ) ) { throw new Throwable ( ( "Need<seq2seq4repair_space>to<seq2seq4repair_space>specify<seq2seq4repair_space>" + ( SERVICE_IDS ) ) ) ; } String keyStore = filterConfig . getInitParameter ( KEYSTORE ) ; String keyPass = filterConfig . getInitParameter ( KEYSTORE_PASS ) ; String trustStore = filterConfig . getInitParameter ( TRUSTSTORE ) ; String trustPass = filterConfig . getInitParameter ( TRUSTSTORE_PASS ) ; String adminToken = getValue ( ADMIN_TOKEN , "" ) ; final boolean useHttps = getValue ( USE_HTTPS , false ) ; int timeout = getValue ( CONN_TIMEOUT , 0 ) ; boolean clientAuth = getValue ( CONN_SSL_CLIENT_AUTH , true ) ; int maxActive = getValue ( CONN_POOL_MAX_ACTIVE , 3 ) ; int maxIdle = getValue ( CONN_POOL_MAX_IDLE , 3 ) ; long evictPeriod = getValue ( CONN_POOL_EVICT_PERIOD , 60000L ) ; long minIdleTime = getValue ( CONN_POOL_MIN_IDLE_TIME , 90000L ) ; retries = getValue ( CONN_TIMEOUT_RETRIES , 3 ) ; pauseTime = getValue ( PAUSE_BETWEEN_RETRIES , 100 ) ; delayAuthDecision = getValue ( DELAY_AUTH_DECISION , false ) ; includeCatalog = getValue ( INCLUDE_SERVICE_CATALOG , true ) ; adminAuthMethod = getValue ( ADMIN_AUTH_METHOD , "" ) ; adminProjectId = getValue ( ADMIN_PROJECT_ID , "" ) ; timeToCacheToken = getValue ( TIME_TO_CACHE_TOKEN , 600 ) ; long maxTokenCacheSize = getValue ( MAX_TOKEN_CACHE_SIZE , 1048576 ) ; this . factory = AuthClientFactory . build ( host , port , useHttps , timeout , clientAuth , keyStore , keyPass , trustStore , trustPass , maxActive , maxIdle , evictPeriod , minIdleTime , adminToken ) ; verifyRequiredParamsForAuthMethod ( ) ; <START_BUG> this . client = new TokenCache ( timeToCacheToken , maxTokenCacheSize , map ) ; <END_BUG> Config . logger . info ( "Using<seq2seq4repair_space>https<seq2seq4repair_space>{}" , useHttps ) ; if ( useHttps ) { Config . logger . info ( ( ( ( "Auth<seq2seq4repair_space>host<seq2seq4repair_space>(2-way<seq2seq4repair_space>SSL:<seq2seq4repair_space>" + clientAuth ) + "):<seq2seq4repair_space>" ) + host ) ) ; } Config . logger . info ( "Read<seq2seq4repair_space>Servlet<seq2seq4repair_space>Initialization<seq2seq4repair_space>Parameters<seq2seq4repair_space>" ) ; initialized = true ; } catch ( Throwable t ) { Config . logger . error ( "Failure<seq2seq4repair_space>initializing<seq2seq4repair_space>connection<seq2seq4repair_space>to<seq2seq4repair_space>authentication<seq2seq4repair_space>endpoint<seq2seq4repair_space>:<seq2seq4repair_space>{}" , t . getMessage ( ) ) ; throw new ServletException ( ( "Failure<seq2seq4repair_space>initializing<seq2seq4repair_space>connection<seq2seq4repair_space>to<seq2seq4repair_space>authentication<seq2seq4repair_space>endpoint<seq2seq4repair_space>::<seq2seq4repair_space>" + ( t . getMessage ( ) ) ) , t ) ; } } public boolean isInitialized ( ) { } protected String getAdminProject ( ) { } protected String getAdminAccessKey ( ) { } protected String getAdminSecretKey ( ) { } protected String getAdminToken ( ) { } protected String getAdminAuthMethod ( ) { } protected String getAdminUser ( ) { } protected String getAdminPassword ( ) { } protected boolean isIncludeCatalog ( ) { } protected String getAuthVersion ( ) { } protected ServletContext getConfig ( ) { } protected TokenCache < String , String > getClient ( ) { } protected AuthClientFactory getFactory ( ) { } protected String getServiceIds ( ) { } protected String getEndpointIds ( ) { } protected boolean isDelayAuthDecision ( ) { } protected int getRetries ( ) { } protected int getPauseTime ( ) { } public long getTimeToCacheToken ( ) { } public void setTimeToCacheToken ( long timeToCachedToken ) { } public void setClient ( TokenCache < String , String > client ) { } private < T > T getValue ( String paramName , T defaultValue ) { } private void verifyRequiredParamsForAuthMethod ( ) { } }

Fix:
this . client = new TokenCache ( maxTokenCacheSize , timeToCacheToken , map ) ;