private function parseElasticCloudId()

in src/TransportBuilder.php [137:151]


    private function parseElasticCloudId(string $cloudId): string
    {
        if (strpos($cloudId, ':') !== false) {
            list($name, $encoded) = explode(':', $cloudId, 2);
            $base64 = base64_decode($encoded, true);
            if ($base64 !== false && strpos($base64, '$') !== false) {
                list($uri, $uuids) = explode('$', $base64);
                return sprintf("https://%s.%s", $uuids, $uri);
            }
        }
        throw new Exception\CloudIdParseException(sprintf(
            'Cloud ID %s is not valid', 
            $name ?? ''
        ));
    }