We need to improve warning collection as follows.
- Can we determine whether a warning is a duplicate without constructing the warning message?
- Limit the number of runtime warnings at a task level and use that as well to disable runtime warnings (set to 0).
- Always keep + return counter for (non-unique) warnings - reported in the metrics.
- Number of runtime warnings is a service level configuration that can be overridden per request using a SET statement.
- Compile time warnings are not limited (but can be disabled).