All Products
Search
Document Center

HTTPDNS:Custom resolution interfaces (Deprecated)

Last Updated:Jun 22, 2026

Introduction

All APIs in this document require custom resolution functions for scenarios where basic resolution does not meet your requirements.

Configure common parameters for custom resolution requests by setting global parameters for custom resolution.

Custom synchronous non-blocking resolution interfaces

Custom synchronous non-blocking interfaces resolve domain names without blocking the current thread, but may return an empty result.

These interfaces query only the cache. If no result exists or the cached result has expired, a worker thread resolves the domain name and updates the cache for subsequent calls.

getIpsByHostAsync

Performs custom resolution for IPv4 addresses in a synchronous, non-blocking way.

Interface definition

HTTPDNSResult getIpsByHostAsync(String host, Map<String,String> params, String cacheKey)

Class

HttpDnsService

Introduced in version

1.3.0

Deprecated version

2.3.2

Replacement interface

HTTPDNSResult getHttpDnsResultForHostSyncNonBlocking(String host, RequestIpType requestIpType, Map<String, String> params, String cacheKey)

Parameters

Parameter

Type

Required

Description

host

String

Yes

The domain name to parse.

params

Map<String, String>

Yes

Extra parameters for domain name resolution, corresponding to event.parameters in the server-side custom resolution function.

cacheKey

String

Yes

Local cache key for the domain name. Change this value when extra parameters change and re-resolution from the server is required.

Return value

Type

Description

HTTPDNSResult

The resolution result.

getHttpDnsResultForHostAsync

Performs custom resolution for IPv4 addresses in a synchronous, non-blocking way.

Interface definition

HTTPDNSResult getHttpDnsResultForHostAsync(String host, Map<String, String> params, String cacheKey);

Class

HttpDnsService

Introduced in version

2.0.2

Deprecated versions

2.4.0

Replacement interface

HTTPDNSResult getHttpDnsResultForHostSyncNonBlocking(String host, RequestIpType requestIpType, Map<String, String> params, String cacheKey)

Parameters

Parameter

Type

Required

Description

host

String

Yes

The domain name to parse.

params

Map<String, String>

Yes

Extra parameters for domain name resolution, corresponding to event.parameters in the server-side custom resolution function.

cacheKey

String

Yes

Local cache key for the domain name. Change this value when extra parameters change and re-resolution from the server is required.

Return value

Type

Description

HTTPDNSResult

The resolution result.

getIpsByHostAsync

Performs custom resolution for IP addresses of a specified type in a synchronous, non-blocking way.

Interface definition

HTTPDNSResult getIpsByHostAsync(String host, RequestIpType requestIpType, Map<String,String> params, String cacheKey)

Class

HttpDnsService

Introduced in version

2.0.2

Deprecated in version

2.4.0

Replacement interface

HTTPDNSResult getHttpDnsResultForHostSyncNonBlocking(String host, RequestIpType requestIpType, Map params, String cacheKey)

Parameters

Parameter

Type

Required

Description

host

String

Yes

The domain name to parse.

requestIpType

RequestIpType

Yes

The IP type to parse. Use RequestIpType.both.

params

Map<String, String>

Yes

Extra parameters for domain name resolution, corresponding to event.parameters in the server-side custom resolution function.

cacheKey

String

Yes

Local cache key for the domain name. Change this value when extra parameters change and re-resolution from the server is required.

Return value

Type

Description

HTTPDNSResult

The resolution result.

getHttpDnsResultForHostAsync

Interface definition

HTTPDNSResult getHttpDnsResultForHostAsync(String host, RequestIpType type, Map<String, String> params, String cacheKey)

Class

HttpDnsService

Introduced in version

2.0.2

Deprecated in version

2.4.0

Replacement interface

HTTPDNSResult getHttpDnsResultForHostSyncNonBlocking(String host, RequestIpType requestIpType, Map params, String cacheKey)

Parameters

Parameter

Type

Required

Description

host

String

Yes

The domain name to parse.

requestIpType

RequestIpType

Yes

The IP type to parse. Use RequestIpType.both.

params

Map<String, String>

Yes

Extra parameters for domain name resolution, corresponding to event.parameters in the server-side custom resolution function.

cacheKey

String

Yes

Local cache key for the domain name. Change this value when extra parameters change and re-resolution from the server is required.

Return value

Type

Description

HTTPDNSResult

The resolution result.