Ambiguous reference configuring logging to ElasticCloud in Elastic.Serilog.Sinks

I'm following the documentation for adding the logging configuration for writing to elastic using the Elastic.Serilog.Sinks and when I try to use the logging configuration extension method xxx.WriteTo.ElasticCloud(xxxx) I get the following error:

The call is ambiguous between the following methods or properties: 'ConfigSinkExtensions.ElasticCloud(LoggerSinkConfiguration, string, string, string, Action?, Action?, LoggingLevelSwitch?, LogEventLevel)' and 'ElasticsearchSinkExtensions.ElasticCloud(LoggerSinkConfiguration, string, string, string, Action?, Action?, LoggingLevelSwitch?, LogEventLevel)

Is this a bug or am I configuring something incorrectly?

I'm having the same error! @kabcampbell have you managed to find a fix?

I wasn't able to solve the ambiguous reference with that particular method signature, however I switch to authenticating with an API key instead of a username and password and that method signature worked for me:

config.WriteTo.ElasticCloud(elasticCloudID, elasticApiKey, opts =>
{
    opts.DataStream = new Elastic.Ingest.Elasticsearch.DataStreams.DataStreamName(dataStream_Type, dataStream_DataSet, dataStream_Namespace);
});
1 Like