Class GradleEnterpriseBuildCache

    • Constructor Detail

      • GradleEnterpriseBuildCache

        public GradleEnterpriseBuildCache()
        Deprecated.
    • Method Detail

      • getServer

        @Nullable
        public java.lang.String getServer()
        Deprecated.
        The address of the build cache server to use, if not using the built-in build cache of the server specified by GradleEnterpriseExtension.getServer().
        Returns:
        null if the built-in build cache of the Gradle Enterprise server should be used, or the address of the build cache server that should be used
        See Also:
        setServer(String)
      • setServer

        public void setServer​(@Nullable
                              java.lang.String server)
        Deprecated.
        Sets the build cache server address to use, if not using the default build cache of the server specified by GradleEnterpriseExtension.getServer().

        Setting this option is necessary when using a dedicated build cache node instead of the Gradle Enterprise built-in build cache.

        The value set must not include any request path or query string. It must only specify the protocol, hostname and port.

        If an access key is available for the GradleEnterpriseExtension.getServer() value it will be used to authenticate with the build cache, regardless of the build cache server address set with this method.

        Parameters:
        server - the server address
      • getPath

        @Nullable
        public java.lang.String getPath()
        Deprecated.
        The custom request path for the build cache server.

        It is generally not necessary to set this value, as the default value used is suitable for the default configuration of Gradle Enterprise build cache nodes (including the built-in build cache).

        Returns:
        the custom request path for the build cache server
        See Also:
        setPath(String)
      • setPath

        public void setPath​(@Nullable
                            java.lang.String path)
        Deprecated.
        Set a custom request path for the build cache server specified by getServer() or GradleEnterpriseExtension.getServer().

        It is generally not necessary to set this value, as the default value used is suitable for the default configuration of Gradle Enterprise build cache nodes (including the built-in build cache).

        Parameters:
        path - a custom request path for the build cache server
      • setAllowUntrustedServer

        public void setAllowUntrustedServer​(boolean allowUntrustedServer)
        Deprecated.
        Specifies whether it is acceptable to communicate with the build cache server using an untrusted SSL certificate.

        If the build cache server are uses an internally provisioned or self-signed certificate it will not be trusted by default. Allowing communication with untrusted servers keeps data encrypted during transmission, but makes it easy for a man-in-the-middle to impersonate the intended server and capture data.

        In such a scenario, you can either configure the build JVM environment to trust the certificate, or call this method with true to disable verification of the server's identity.

        This value has no effect if communicating with the server using the HTTP protocol (i.e. has SSL disabled).

        Parameters:
        allowUntrustedServer - whether to allow communication with an HTTPS server with an untrusted certificate
      • getAllowInsecureProtocol

        public boolean getAllowInsecureProtocol()
        Deprecated.
        Whether the use of plain/unencrypted HTTP is allowed when communicating with the build cache server.
        Returns:
        whether the use of plain/unencrypted HTTP is allowed when communicating with the build cache server
        See Also:
        setAllowInsecureProtocol(boolean)
      • setAllowInsecureProtocol

        public void setAllowInsecureProtocol​(boolean allowInsecureProtocol)
        Deprecated.
        Sets whether the use of plain/unencrypted HTTP is allowed when communicating with the build cache server.

        This value defaults to false.

        Use of unencrypted HTTP allows interception of build cache entries while in transit and is a significant privacy risk. Use of HTTPS instead of enabling this setting is strongly recommended

        Parameters:
        allowInsecureProtocol - whether to allow the use of plain/unencrypted HTTP
      • usernameAndPassword

        public void usernameAndPassword​(java.lang.String username,
                                        java.lang.String password)
        Deprecated.
        Sets the username/password to use to authenticate with the build cache server.

        This is a convenient variant of setUsernameAndPassword(UsernameAndPassword).

        Parameters:
        username - the username
        password - the password
      • setUsernameAndPassword

        public void setUsernameAndPassword​(@Nullable
                                           GradleEnterpriseBuildCache.UsernameAndPassword usernameAndPassword)
        Deprecated.
        Sets the username/password to use to authenticate with the build cache server.

        If specified, the username/password will be used instead of any available Gradle Enterprise access key. Use of access keys should be preferred.

        Parameters:
        usernameAndPassword - the username and password
      • getUseExpectContinue

        public boolean getUseExpectContinue()
        Deprecated.
        Whether to use HTTP Expect-Continue when storing data on the build cache server.
        Returns:
        whether the use of HTTP Expect-Continue is configured when communicating with the build cache server
        Since:
        3.12
        See Also:
        setUseExpectContinue(boolean)
      • setUseExpectContinue

        public void setUseExpectContinue​(boolean useExpectContinue)
        Deprecated.
        Sets whether to use HTTP Expect-Continue when storing data on the build cache server.

        This causes PUT requests to happen in two parts: first a check whether a body would be accepted, then transmission of the body if the server indicates it will accept it. This is particularly suitable for Build Cache servers that routinely redirect or reject PUT requests, as it avoids transmitting the cache entry just to have it rejected. This additional check incurs extra latency when the server accepts the request, but reduces latency when the request is rejected or redirected.

        This value defaults to false.

        While the Gradle Enterprise Build Cache Node supports Expect-Continue, not all HTTP servers and proxies reliably do. Be sure to check that your Build Cache server does support it before enabling.

        Parameters:
        useExpectContinue - whether to use HTTP Expect-Continue
        Since:
        3.12