HttpConnectionResolver class Null safety
Helper class to retrieve connections for HTTP-based services abd clients.
In addition to regular functions of ConnectionResolver is able to parse http:// URIs and validate connection parameters before returning them.
discovery_key: (optional) a key to retrieve the connection from IDiscovery
- ... other connection parameters
connections: alternative to connection
connection params 1: first connection parameters
connection params N: Nth connection parameters
\*:discovery:\*:\*:1.0(optional) IDiscovery services
var config = ConfigParams.fromTuples([ 'connection.host', '10.1.1.100', 'connection.port', 8080 ]); var connectionResolver = HttpConnectionResolver(); connectionResolver.configure(config); connectionResolver.setReferences(references); var connection = connectionResolver.resolve('123', // Now use connection...
- connectionResolver → ConnectionResolver
The base connection resolver.
- credentialResolver → CredentialResolver
The base credential resolver.
- hashCode → int
The hash code for this object.
- runtimeType → Type
A representation of the runtime type of the object.
ConfigParams config) → void
- Configures component by passing configuration parameters.
Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
String? correlationId) → Future
- Registers the given connection in all referenced discovery services. This method can be used for dynamic service discovery.
String? correlationId) → Future< ConfigParams?>
- Resolves a single component connection. If connections are configured to be retrieved from Discovery service it finds a IDiscovery and resolves the connection there.
String? correlationId) → Future< ConfigParams>
- Resolves all component connection. If connections are configured to be retrieved from Discovery service it finds a IDiscovery and resolves the connection there.
IReferences references) → void
- Sets references to dependent components.
) → String
A string representation of this object.