@@ -36,60 +36,60 @@ func (b *NodeBuilder) ExecFallback(prepResult any, err error) (any, error) {
3636
3737// GetMaxRetries implements RetryableNode.GetMaxRetries by delegating to the embedded BaseNode
3838func (b * NodeBuilder ) GetMaxRetries () int {
39- return b .CustomNode .BaseNode . GetMaxRetries ()
39+ return b .CustomNode .GetMaxRetries ()
4040}
4141
4242// GetWait implements RetryableNode.GetWait by delegating to the embedded BaseNode
4343func (b * NodeBuilder ) GetWait () time.Duration {
44- return b .CustomNode .BaseNode . GetWait ()
44+ return b .CustomNode .GetWait ()
4545}
4646
4747// WithMaxRetries sets the maximum number of retries for the node's Exec phase.
4848// Returns the builder for method chaining.
4949func (b * NodeBuilder ) WithMaxRetries (retries int ) * NodeBuilder {
50- WithMaxRetries (retries )(b .CustomNode . BaseNode )
50+ WithMaxRetries (retries )(b .BaseNode )
5151 return b
5252}
5353
5454// WithWait sets the wait duration between retries.
5555// Returns the builder for method chaining.
5656func (b * NodeBuilder ) WithWait (wait time.Duration ) * NodeBuilder {
57- WithWait (wait )(b .CustomNode . BaseNode )
57+ WithWait (wait )(b .BaseNode )
5858 return b
5959}
6060
6161// WithPrepFunc sets a custom Prep implementation using Result types.
6262// Returns the builder for method chaining.
6363func (b * NodeBuilder ) WithPrepFunc (fn func (context.Context , * SharedStore ) (Result , error )) * NodeBuilder {
64- b .CustomNode . prepFunc = fn
64+ b .prepFunc = fn
6565 return b
6666}
6767
6868// WithExecFunc sets a custom Exec implementation using Result types.
6969// Returns the builder for method chaining.
7070func (b * NodeBuilder ) WithExecFunc (fn func (context.Context , Result ) (Result , error )) * NodeBuilder {
71- b .CustomNode . execFunc = fn
71+ b .execFunc = fn
7272 return b
7373}
7474
7575// WithPostFunc sets a custom Post implementation using Result types.
7676// Returns the builder for method chaining.
7777func (b * NodeBuilder ) WithPostFunc (fn func (context.Context , * SharedStore , Result , Result ) (Action , error )) * NodeBuilder {
78- b .CustomNode . postFunc = fn
78+ b .postFunc = fn
7979 return b
8080}
8181
8282// WithExecFallbackFunc sets a custom ExecFallback implementation.
8383// Returns the builder for method chaining.
8484func (b * NodeBuilder ) WithExecFallbackFunc (fn func (any , error ) (any , error )) * NodeBuilder {
85- b .CustomNode . execFallbackFunc = fn
85+ b .execFallbackFunc = fn
8686 return b
8787}
8888
8989// WithPrepFuncAny sets a custom Prep implementation using any types.
9090// Returns the builder for method chaining.
9191func (b * NodeBuilder ) WithPrepFuncAny (fn func (context.Context , * SharedStore ) (any , error )) * NodeBuilder {
92- b .CustomNode . prepFunc = func (ctx context.Context , shared * SharedStore ) (Result , error ) {
92+ b .prepFunc = func (ctx context.Context , shared * SharedStore ) (Result , error ) {
9393 val , err := fn (ctx , shared )
9494 if err != nil {
9595 return Result {}, err
@@ -102,7 +102,7 @@ func (b *NodeBuilder) WithPrepFuncAny(fn func(context.Context, *SharedStore) (an
102102// WithExecFuncAny sets a custom Exec implementation using any types.
103103// Returns the builder for method chaining.
104104func (b * NodeBuilder ) WithExecFuncAny (fn func (context.Context , any ) (any , error )) * NodeBuilder {
105- b .CustomNode . execFunc = func (ctx context.Context , prepResult Result ) (Result , error ) {
105+ b .execFunc = func (ctx context.Context , prepResult Result ) (Result , error ) {
106106 val , err := fn (ctx , prepResult .Value ())
107107 if err != nil {
108108 return Result {}, err
@@ -115,7 +115,7 @@ func (b *NodeBuilder) WithExecFuncAny(fn func(context.Context, any) (any, error)
115115// WithPostFuncAny sets a custom Post implementation using any types.
116116// Returns the builder for method chaining.
117117func (b * NodeBuilder ) WithPostFuncAny (fn func (context.Context , * SharedStore , any , any ) (Action , error )) * NodeBuilder {
118- b .CustomNode . postFunc = func (ctx context.Context , shared * SharedStore , prepResult , execResult Result ) (Action , error ) {
118+ b .postFunc = func (ctx context.Context , shared * SharedStore , prepResult , execResult Result ) (Action , error ) {
119119 return fn (ctx , shared , prepResult .Value (), execResult .Value ())
120120 }
121121 return b
@@ -124,17 +124,17 @@ func (b *NodeBuilder) WithPostFuncAny(fn func(context.Context, *SharedStore, any
124124// WithBatchConcurrency sets the concurrency level for batch processing.
125125// Returns the builder for method chaining.
126126func (b * NodeBuilder ) WithBatchConcurrency (n int ) * NodeBuilder {
127- b .CustomNode . BaseNode . batchConcurrency = n
127+ b .batchConcurrency = n
128128 return b
129129}
130130
131131// WithBatchErrorHandling sets the error handling strategy for batch processing.
132132// Returns the builder for method chaining.
133133func (b * NodeBuilder ) WithBatchErrorHandling (continueOnError bool ) * NodeBuilder {
134134 if continueOnError {
135- b .CustomNode . BaseNode . batchErrorHandling = "continue"
135+ b .batchErrorHandling = "continue"
136136 } else {
137- b .CustomNode . BaseNode . batchErrorHandling = "stop"
137+ b .batchErrorHandling = "stop"
138138 }
139139 return b
140140}
0 commit comments