arunramani commented on PR #16510:
URL: https://github.com/apache/druid/pull/16510#issuecomment-2142726346

   If we want `Selector` to be general purpose, we need to clean it up a bit. 
When implementing a selector, you need to have 3 things: the list of 
selections, the evaluation criteria and the selection key. For this case, we 
could simplify it to just the list of selections and the selection key. The 
evaluation criteria can be defaulted to a simple "AND all of the keys except 
the select key". An example of how it should look
   ```
   "behaviorStrategy": {
       "type": "default",
       "selectKey": "category",
       "categorySelectors": [
         {
           "category": "low-throughput",
           "context.tags": {
             "billingCategory": [
               "streaming_ingestion"
             ]
           },
           "task": {
             "datasource": [
               "wikipedia"
             ]
           }
         },
         {
           "category": "medium-throughput",
           "task": {
             "type": [
               "index_kafka"
             ]
           }
         }
       ]
     }
   ```
   So now the evaluator would look at all of the keys EXCEPT `category` and one 
a match, it will return the category.
   
   What do you think?


-- 
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]

Reply via email to