code: public CredentialParams lookup(String correlationId) throws ApplicationException {
  		if (_credentials.size() == 0)
  			return null;
  
  		// Return connection that doesn't require discovery
  		for (CredentialParams credential : _credentials) {
  			if (!credential.useCredentialStore())
  				return credential;
  		}
  
  		// Return connection that require discovery
  		for (CredentialParams credential : _credentials) {
  			if (credential.useCredentialStore()) {
  				CredentialParams resolvedConnection = lookupInStores(correlationId, credential);
  				if (resolvedConnection != null)
  					return resolvedConnection;
  			}
  		}
  
  		return null;
  	}
docs: Looks up component credential parameters. If credentials are configured to be
  retrieved from Credential store it finds a ICredentialStore and lookups
  credentials there.
  
  @param correlationId (optional) transaction id to trace execution through
  call chain.
  @return resolved credential parameters or null if nothing was found.
  @throws ApplicationException when errors occured.