Source:
<code>public Session beginTransactionId(TransactionId transactionId, TransactionManager transactionManager, AccessControl accessControl) { requireNonNull(transactionId, "transactionId is null"); checkArgument(!this.transactionId.isPresent(), "Session already has an active transaction"); requireNonNull(transactionManager, "transactionManager is null"); requireNonNull(accessControl, "accessControl is null"); for (Entry<String, String> property : systemProperties.entrySet()) { accessControl.checkCanSetSystemSessionProperty(identity, property.getKey()); sessionPropertyManager.validateSystemSessionProperty(property.getKey(), property.getValue()); } ImmutableMap.Builder<ConnectorId, Map<String, String>> connectorProperties = ImmutableMap.builder(); for (Entry<String, Map<String, String>> catalogEntry : unprocessedCatalogProperties.entrySet()) { String catalogName = catalogEntry.getKey(); Map<String, String> catalogProperties = catalogEntry.getValue(); if (catalogProperties.isEmpty()) { continue; } ConnectorId connectorId = transactionManager.getOptionalCatalogMetadata(transactionId, catalogName) <START> .orElseThrow(() -> <END> new PrestoException(NOT_FOUND, "Catalog " + catalogName + " does not exist for session property: " + getFirst(catalogProperties.keySet(), null))) .getConnectorId(); for (Entry<String, String> property : catalogProperties.entrySet()) { accessControl.checkCanSetCatalogSessionProperty(transactionId, identity, catalogName, property.getKey()); sessionPropertyManager.validateCatalogSessionProperty(connectorId, catalogName, property.getKey(), property.getValue()); } connectorProperties.put(connectorId, catalogProperties); } return new Session( queryId, Optional.of(transactionId), clientTransactionSupport, identity, source, catalog, schema, timeZoneKey, locale, remoteUserAddress, userAgent, clientInfo, clientTags, startTime, systemProperties, connectorProperties.build(), ImmutableMap.of(), sessionPropertyManager, preparedStatements); }</code><technical_language>change error message this: java .orElseThrow(() -> new PrestoException(NOT_FOUND, "Session property catalog exist: " + catalogName)) full name of session property is relevant</technical_language>

Target:
public Session beginTransactionId(TransactionId transactionId, TransactionManager transactionManager, AccessControl accessControl) { requireNonNull(transactionId, "transactionId is null"); checkArgument(!this.transactionId.isPresent(), "Session already has an active transaction"); requireNonNull(transactionManager, "transactionManager is null"); requireNonNull(accessControl, "accessControl is null"); for (Entry<String, String> property : systemProperties.entrySet()) { accessControl.checkCanSetSystemSessionProperty(identity, property.getKey()); sessionPropertyManager.validateSystemSessionProperty(property.getKey(), property.getValue()); } ImmutableMap.Builder<ConnectorId, Map<String, String>> connectorProperties = ImmutableMap.builder(); for (Entry<String, Map<String, String>> catalogEntry : unprocessedCatalogProperties.entrySet()) { String catalogName = catalogEntry.getKey(); Map<String, String> catalogProperties = catalogEntry.getValue(); if (catalogProperties.isEmpty()) { continue; } ConnectorId connectorId = transactionManager.getOptionalCatalogMetadata(transactionId, catalogName) .orElseThrow(() -> new PrestoException(NOT_FOUND, "Session property catalog does not exist: " + catalogName)) .getConnectorId(); for (Entry<String, String> property : catalogProperties.entrySet()) { accessControl.checkCanSetCatalogSessionProperty(transactionId, identity, catalogName, property.getKey()); sessionPropertyManager.validateCatalogSessionProperty(connectorId, catalogName, property.getKey(), property.getValue()); } connectorProperties.put(connectorId, catalogProperties); } return new Session( queryId, Optional.of(transactionId), clientTransactionSupport, identity, source, catalog, schema, timeZoneKey, locale, remoteUserAddress, userAgent, clientInfo, clientTags, startTime, systemProperties, connectorProperties.build(), ImmutableMap.of(), sessionPropertyManager, preparedStatements); }