Hello, I can set socketTimeout at different block,...
# ktor
d
Hello, I can set socketTimeout at different block, is there any differences between the block between
engine block
and
customizeClient block
?
Copy code
val clientCall = HttpClient(Apache){
          engine {
            socketTimeout = config?.timeoutMsec ?: 10_000
            connectTimeout = config?.connectTimeout ?: 10_000
            connectionRequestTimeout = 20_000

            customizeClient {
              setProxy(requestProxyHost)

              socketTimeout = config?.timeoutMsec ?: 10_000
              connectTimeout = config?.connectTimeout ?: 10_000
              connectionRequestTimeout = 20_000
            }
          }
        }
e
customizeClient
is the
Apache
specific builder. So no difference for the
Apache
engine.
d
so at that code example, the duplicate code is useless, right? i shud remove one