Bug #90679 dragnet logging: make uninstall messages clearer and document dependency issues
Submitted: 29 Apr 2018 7:54 Modified: 30 Apr 2018 8:32
Reporter: Simon Mudd (OCA) Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Logging Severity:S3 (Non-critical)
Version:8.0 OS:Any
Assigned to: CPU Architecture:Any
Tags: dependencies, dragnet, logging

[29 Apr 2018 7:54] Simon Mudd
Description:
I install the dragnet logging and things work fine.
I want to uninstall this as I no longer need it and this is what I see:

myuser@myhost [(none)]> UNINSTALL COMPONENT 'file://component_log_filter_dragnet'; 
ERROR 3540 (HY000): Unregistration of service implementation 'log_service.log_filter_dragnet' provided by component 'mysql:log_filter_dragnet' failed during unloading of the component. 

I can do: 

myuser@myhost [(none)]> set global log_error_services = DEFAULT; 
Query OK, 0 rows affected (0.00 sec) 

myuser@myhost [(none)]> UNINSTALL COMPONENT 'file://component_log_filter_dragnet'; 
Query OK, 0 rows affected (0.01 sec) 

but I feel that the error report should give a better idea of what the problem is and how the user can achieve the desired goal. 

How to repeat:
see above

If you use components more frequently which I understand is the plan then this sort of issue will come up more frequently.

Suggested fix:
Suggestions:

* create a generic component error message which explains when you uninstall a component which one depends on it (so we can uninstall it first or reconfigure it to remove the dependency)
* document the uninstall process has dependencies and must be done the right way
* provide a way to query via SQL for component dependencies so we can script this whole procedure

Suggested specific error message:
* Unable to uninstall component xxxxx: please adjust log_error_services and remove the dragnet whatever configuration to remove this component
[30 Apr 2018 8:32] MySQL Verification Team
Hello Simon,

Thank you for the report and feedback!

Thanks,
Umesh