Github user vanzin commented on the issue:
https://github.com/apache/spark/pull/19981
> Code readability is important to Spark, we should not sacrifice it
without real benefits.
I agree, but I also think that duplicating code in disjoint places hurts
readability, not helps it.
> but can we guarantee it in all other places like streaming
Those are not being installed with this interface, are they?
> which may stop us from catching Spark events in SQL listener in the future
The listener is now being installed before it was before (when the context
starts, instead of later), so it's less likely that it will miss events.
As I mentioned in the other PR you commented on, I do understand that the
code here is not super pretty. But I really don't think going back to the
previous way is the right thing.
For example, a way to simplify the plugin code is to change the way
visibility of the SQL tab is done. Either always show it (simpler), or add a
new method in `SparkUITab` that says whether the tab is visible, and have the
SQL tab override it. Either of those would simplify the plugin code a lot
(setupListener would just install the listener, always, setupUI would just add
the tab, always).
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]