Allow logging from BasicAuthConnector

Created on 11 June 2025, 24 days ago

Problem/Motivation

In the closed issue Logging should be configurable (3427092) 📌 Logging should be configurable Fixed , one of the lines in the description said:

User interface changes
Adds a Enable debugging mode: log ElasticSearch network traffic checkbox to the Standard and Basic Authentication server types.

However, this issue was not correctly written out and there was some assumptions made that are not correct in this line:

Note that plugin.plugin_configuration.elasticsearch_connector.basicauth extends plugin.plugin_configuration.elasticsearch_connector.standard configuration, so enable_debug_logging automatically gets added to plugin.plugin_configuration.elasticsearch_connector.basicauth

.

Since the getClient() method on BasicAuthConnector does not call its parent, it is totally skipping the process of setting up the logger, hence logging doesn't work on BasicAuthConnector.

Steps to reproduce

Enable logging with Basic auth, try a search query and see nothing shows up in the logs.

Proposed resolution

Write the getClient() method correctly to make the extension from StandardConnector work correctly.
Isolating the ->setBasicAuthentication($this->configuration['username'], $this->configuration['password']) from the rest which can be shared would be one way.

Remaining tasks


Update StandardConnector and BasicAuthConnector to allow the logging code to be extended on Fork
Testing
Create Merge Request
Review
Merge

User interface changes

UI should stay the same

📌 Task
Status

Active

Version

8.0

Component

Code

Created by

🇬🇧United Kingdom ChrisDarke London

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024