Jackie-Jiang commented on code in PR #13573:
URL: https://github.com/apache/pinot/pull/13573#discussion_r1674558688
##########
pinot-query-planner/src/main/java/org/apache/pinot/calcite/sql/fun/PinotOperatorTable.java:
##########
@@ -46,127 +59,296 @@
* </ul>
*/
@SuppressWarnings("unused") // unused fields are accessed by reflection
-public class PinotOperatorTable extends SqlStdOperatorTable {
-
- private static @MonotonicNonNull PinotOperatorTable _instance;
-
- // TODO: clean up lazy init by using
Suppliers.memorized(this::computeInstance) and make getter wrapped around
- // supplier instance. this should replace all lazy init static objects in
the codebase
- public static synchronized PinotOperatorTable instance() {
- if (_instance == null) {
- // Creates and initializes the standard operator table.
- // Uses two-phase construction, because we can't initialize the
- // table until the constructor of the sub-class has completed.
- _instance = new PinotOperatorTable();
- _instance.initNoDuplicate();
- }
- return _instance;
+public class PinotOperatorTable implements SqlOperatorTable {
Review Comment:
Good catch. I forgot to update the javadoc for this class
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]