Skip to content
Snippets Groups Projects
Commit b6879174 authored by Cam Saül's avatar Cam Saül
Browse files

Add notes about how annotate/sort should be decoupled/reörganized

parent 073ec4d7
No related branches found
No related tags found
No related merge requests found
(ns metabase.query-processor.annotate
"Code that analyzes the results of running a query and adds relevant type information about results (including foreign key information).
TODO - The code in this namespace could definitely use a little cleanup to make it a little easier to wrap one's head around :)"
"Code that analyzes the results of running a query and adds relevant type information about results (including foreign key information)."
;; TODO - The code in this namespace could definitely use a little cleanup to make it a little easier to wrap one's head around :)
;; TODO - This namespace should be called something like `metabase.query-processor.middleware.annotate`
(:require [clojure
[set :as set]
[string :as str]]
......
(ns metabase.query-processor.middleware.annotate-and-sort
"Middleware for annotating (adding type information to) the results of a query and sorting the columns in the results."
;; TODO - `annotate` and `sort` are technically two seperate steps. We should decouple them and replace
;; `metabase.query-processor.annotate`, ``metabase.query-processor.sort`, and `metabase.query-processor.middleware.annotate-and-sort`
;; with two namespaces called `metabase.query-processor.middleware.annotate` and `metabase.query-processor.middleware.sort`
(:require [metabase.driver :as driver]
(metabase.query-processor [annotate :as annotate]
[util :as qputil])))
[metabase.query-processor
[annotate :as annotate]
[util :as qputil]]))
(def ^:private ^:const ^Integer max-rows-to-scan-for-column-type-inference
"Maximum number of rows to scan to look for a non-`nil` value to determine type information.
......
(ns metabase.query-processor.sort
"Code for determining the order columns should be returned in from query results."
;; TODO - This namespace should be called something like `metabase.query-processor.middleware.sort`
(:require [clojure.tools.logging :as log]
[metabase.query-processor.interface :as i]
[metabase.util :as u]))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment