You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@jena.apache.org by "rvesse (via GitHub)" <gi...@apache.org> on 2023/03/29 12:06:19 UTC

[GitHub] [jena] rvesse opened a new issue, #1817: Expression Evaluation errors can flood the logs

rvesse opened a new issue, #1817:
URL: https://github.com/apache/jena/issues/1817

   ### Version
   
   4.x
   
   ### What happened?
   
   User report on the mailing list - https://lists.apache.org/thread/4kfpx9wpm38p3kbdh78dmgpoz2ckm4s1
   
   A query with a faulty `REGEX` on a large dataset resulted in massive log output because every single attempt to evaluate the expression produces an `ExprEvalException` and `QueryIterFilterExpr` logs every single one of those
   
   Workaround suggested on list is to disable the offending logger but since this is enabled by default it effectively provides a potential DoS vector against Jena based systems.  Logging could be made more intelligent in several ways:
   
   - Suppressing duplicate messages
   - Not logging specific classes of expression evaluation failures
   - Logging at a lower level that would not be output by default
   
   ### Relevant output and stacktrace
   
   ```shell
   See mailing list thread - https://lists.apache.org/thread/91qvxshm4njnd657g966yrbq8kmsy9ok
   ```
   
   
   ### Are you interested in making a pull request?
   
   Yes


-- 
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: issues-unsubscribe@jena.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@jena.apache.org
For additional commands, e-mail: issues-help@jena.apache.org


[GitHub] [jena] afs commented on issue #1817: Expression Evaluation errors can flood the logs

Posted by "afs (via GitHub)" <gi...@apache.org>.
afs commented on issue #1817:
URL: https://github.com/apache/jena/issues/1817#issuecomment-1488558068

   See mailing list. User query is suspect.
   
   This is because the regex is in a variable (and wrong) and may change every evaluation - so some can be right, some can be wrong.
   
   Usually, regex patterns are constants and compiled once. And so one log message per evaluation.
   
   We could consider not outputting the stacktrace but be careful of changing away from ExprException because of the more important static case.
   


-- 
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: issues-unsubscribe@jena.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@jena.apache.org
For additional commands, e-mail: issues-help@jena.apache.org