Class ConnectionSettings
Provides the connection settings for OpenSearchClient
Inheritance
ConnectionConfiguration<ConnectionSettings>
ConnectionSettingsBase<ConnectionSettings>
ConnectionSettings
Inherited Members
Namespace: OpenSearch.Client
Assembly: OpenSearch.Client.dll
Syntax
public class ConnectionSettings : ConnectionSettingsBase<ConnectionSettings>, IConnectionSettingsValues, IConnectionConfigurationValues, IDisposable
Constructors
| Edit this page View SourceConnectionSettings(IConnectionPool)
Declaration
public ConnectionSettings(IConnectionPool connectionPool)
Parameters
Type | Name | Description |
---|---|---|
IConnectionPool | connectionPool |
ConnectionSettings(IConnectionPool, SourceSerializerFactory)
Declaration
public ConnectionSettings(IConnectionPool connectionPool, ConnectionSettings.SourceSerializerFactory sourceSerializer)
Parameters
Type | Name | Description |
---|---|---|
IConnectionPool | connectionPool | |
ConnectionSettings.SourceSerializerFactory | sourceSerializer |
ConnectionSettings(IConnectionPool, IConnection)
Declaration
public ConnectionSettings(IConnectionPool connectionPool, IConnection connection)
Parameters
Type | Name | Description |
---|---|---|
IConnectionPool | connectionPool | |
IConnection | connection |
ConnectionSettings(IConnectionPool, IConnection, SourceSerializerFactory)
Declaration
public ConnectionSettings(IConnectionPool connectionPool, IConnection connection, ConnectionSettings.SourceSerializerFactory sourceSerializer)
Parameters
Type | Name | Description |
---|---|---|
IConnectionPool | connectionPool | |
IConnection | connection | |
ConnectionSettings.SourceSerializerFactory | sourceSerializer |
ConnectionSettings(IConnectionPool, IConnection, SourceSerializerFactory, IPropertyMappingProvider)
Declaration
public ConnectionSettings(IConnectionPool connectionPool, IConnection connection, ConnectionSettings.SourceSerializerFactory sourceSerializer, IPropertyMappingProvider propertyMappingProvider)
Parameters
Type | Name | Description |
---|---|---|
IConnectionPool | connectionPool | |
IConnection | connection | |
ConnectionSettings.SourceSerializerFactory | sourceSerializer | |
IPropertyMappingProvider | propertyMappingProvider |
ConnectionSettings(InMemoryConnection)
Instantiate connection settings using a SingleNodeConnectionPool using the provided InMemoryConnection that never uses any IO.
Declaration
public ConnectionSettings(InMemoryConnection connection)
Parameters
Type | Name | Description |
---|---|---|
InMemoryConnection | connection |
ConnectionSettings(string, ApiKeyAuthenticationCredentials)
Sets up the client to communicate to OpenSearch Cloud using cloudId
,
CloudConnectionPool documentation for more information on how to obtain your Cloud Id
Declaration
public ConnectionSettings(string cloudId, ApiKeyAuthenticationCredentials credentials)
Parameters
Type | Name | Description |
---|---|---|
string | cloudId | |
ApiKeyAuthenticationCredentials | credentials |
ConnectionSettings(string, BasicAuthenticationCredentials)
Sets up the client to communicate to OpenSearch Cloud using cloudId
,
CloudConnectionPool documentation for more information on how to obtain your Cloud Id
Declaration
public ConnectionSettings(string cloudId, BasicAuthenticationCredentials credentials)
Parameters
Type | Name | Description |
---|---|---|
string | cloudId | |
BasicAuthenticationCredentials | credentials |
ConnectionSettings(Uri, IConnection)
Creates a new instance of connection settings, if uri
is not specified will default to connecting to http://localhost:9200
Declaration
public ConnectionSettings(Uri uri = null, IConnection connection = null)
Parameters
Type | Name | Description |
---|---|---|
Uri | uri | |
IConnection | connection |
Fields
| Edit this page View SourceDefaultUserAgent
The default user agent for OpenSearch.Client
Declaration
public static readonly string DefaultUserAgent
Field Value
Type | Description |
---|---|
string |