- Issue created by @ChrisDarke
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.
Enable logging with Basic auth, try a search query and see nothing shows up in the logs.
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.
Update StandardConnector and BasicAuthConnector to allow the logging code to be extended on Fork
Testing
Create Merge Request
Review
Merge
UI should stay the same
Active
8.0
Code