jhc-systems / sqlest

Write SQL in Scala
https://jhc-systems.github.io/sqlest/latest/api/
Apache License 2.0
30 stars 17 forks source link

Don't "Log & Throw" #81

Closed kutchar closed 7 years ago

kutchar commented 7 years ago

"Log & throw" is an anti-pattern and makes for noisy log files. For example, duplicate key exceptions are handled by the application logic and don't really need to be logged as errors.

https://github.com/jhc-systems/sqlest/blob/master/sqlest/src/main/scala/sqlest/executor/Database.scala#L109

https://github.com/jhc-systems/sqlest/blob/master/sqlest/src/main/scala/sqlest/executor/Database.scala#L284

https://github.com/jhc-systems/sqlest/blob/master/sqlest/src/main/scala/sqlest/executor/Database.scala#L315

kutchar commented 7 years ago

@DavidGregory084 thanks for merging it. Any idea when you'd be able to release it?