# Spring boot Workflow config

**URL:** <https://community.temporal.io/t/spring-boot-workflow-config/8624>\
**Category:** Community Support\
**Tags:** java-sdk\
**Created:** [June 23, 2023, 6:50am UTC](https://community.temporal.io/t/spring-boot-workflow-config/8624 "2023-06-23T06:50:47Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![wanny](https://sea2.discourse-cdn.com/flex016/user_avatar/community.temporal.io/wanny/32/3948_2.png) [@wanny](https://community.temporal.io/u/wanny)\
**Post date:** [June 23, 2023, 6:50am UTC](https://community.temporal.io/t/spring-boot-workflow-config/8624/1 "2023-06-23T06:50:47Z")

</div>

How can I add a custom exception (extending TemporalException) to workflow exception types `(WorkflowImplementationOptions.failWorkflowExceptionTypes)` in **Springboot**? So it will not be retried.

Throwing an exception like this `throw ApplicationFailure.newNonRetryableFailure` from the workflow fails the workflow. However, I am hoping to fail the workflow using a custom exception.

---

<div class="post-metadata">

**Author:** ![tihomir](https://sea2.discourse-cdn.com/flex016/user_avatar/community.temporal.io/tihomir/32/6580_2.png) [@tihomir](https://community.temporal.io/u/tihomir)\
**Post date:** [June 23, 2023, 3:36pm UTC](https://community.temporal.io/t/spring-boot-workflow-config/8624/3 "2023-06-23T15:36:38Z")

</div>

It’s not possible currently to specify WorkflowImplementationOptions, see feature request [here](https://github.com/temporalio/sdk-java/issues/1647).

Until it’s added would use ApplicationFailure (you don’t have to throw nonRetryable kind, workflows do not have default retry policy like activities).  
Re-throwing ActivityFailure/ChildWorkflowFailure would fail workflow execution as well.

What is the use case where you want to explicitly fail the execution?
