Skip to content

Commit

Permalink
Reword JavaDoc
Browse files Browse the repository at this point in the history
  • Loading branch information
hiddenalpha committed May 21, 2024
1 parent 7d1e970 commit d7506f0
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,18 @@
* So now through this abstraction, both applications can choose the behavior
* they need.
*
* If dependency-injection gets applied properly, an app can even provide its
* custom implementation to fine-tune the exact behavior even further.
* There are two default options an app can use (if it does not want to provide
* a custom impl).
* One is {@link GateleenThriftyExceptionFactory}. It trades maintainability
* for speed. For example prefers lightweight exceptions without stacktrace
* recording. Plus it may apply other tricks to reduce resource costs.
* The other one is {@link GateleenWastefulExceptionFactory}. It trades speed
* for maintainability. So it tries to track as much error details as possible.
* For example recording stack traces, keeping 'cause' and 'suppressed'
* exceptions, plus maybe more.
*
* If none of those defaults matches, an app can provide its custom
* implementation via dependency injection.
*/
public interface GateleenExceptionFactory {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,7 @@
import io.vertx.core.eventbus.ReplyFailure;

/**
* Trades maintainability for speed. For example prefers lightweight
* exceptions without stacktrace recording. It may even decide to drop 'cause'
* or other details. If an app needs more error details it should use
* {@link GateleenWastefulExceptionFactory}. If none of those fits the apps needs, it
* can provide its own implementation.
* See {@link GateleenExceptionFactory} for details.
*/
class GateleenThriftyExceptionFactory implements GateleenExceptionFactory {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@
import io.vertx.core.eventbus.ReplyFailure;

/**
* Trades speed for maintainability. For example invests more resources like
* recording stack traces (which likely provocates more logs) to get easier
* to debug error messages and better hints of what is happening. It also
* keeps details like 'causes' and 'suppressed' exceptions. If an app needs
* more error details it should use {@link GateleenWastefulExceptionFactory}. If none
* of those fits the apps needs, it can provide its own implementation.
* See {@link GateleenExceptionFactory} for details.
*/
class GateleenWastefulExceptionFactory implements GateleenExceptionFactory {

Expand Down

0 comments on commit d7506f0

Please sign in to comment.