@@ -1212,8 +1212,6 @@ export class WorkflowClient extends BaseClient {
12121212 const dataConverter = this . dataConverter ;
12131213 const context = this . workflowSerializationContext ( input . workflowExecution . workflowId ! ) ;
12141214 const internalOptions = ( input as InternalWorkflowSignalInput ) [ InternalWorkflowSignalOptionsSymbol ] ;
1215- // Server currently only supports workflow_event and batch_job link types.
1216- const links = internalOptions ?. links ?. filter ( ( link ) => link . workflowEvent != null || link . batchJob != null ) ;
12171215 const req : temporal . api . workflowservice . v1 . ISignalWorkflowExecutionRequest = {
12181216 identity : this . options . identity ,
12191217 namespace : this . options . namespace ,
@@ -1223,7 +1221,7 @@ export class WorkflowClient extends BaseClient {
12231221 signalName : input . signalName ,
12241222 header : { fields : input . headers } ,
12251223 input : { payloads : await encodeToPayloadsWithContext ( dataConverter , context , input . args ) } ,
1226- links,
1224+ links : internalOptions ?. links ,
12271225 } ;
12281226 try {
12291227 const response = await this . workflowService . signalWorkflowExecution ( req ) ;
@@ -1248,8 +1246,6 @@ export class WorkflowClient extends BaseClient {
12481246 const dataConverter = this . dataConverter ;
12491247 const context = this . workflowSerializationContext ( options . workflowId ) ;
12501248 const internalOptions = ( options as InternalWorkflowStartOptions ) [ InternalWorkflowStartOptionsSymbol ] ;
1251- // Server currently only supports workflow_event and batch_job link types.
1252- const links = internalOptions ?. links ?. filter ( ( link ) => link . workflowEvent != null || link . batchJob != null ) ;
12531249 const req : temporal . api . workflowservice . v1 . ISignalWithStartWorkflowExecutionRequest = {
12541250 namespace : this . options . namespace ,
12551251 identity,
@@ -1282,7 +1278,7 @@ export class WorkflowClient extends BaseClient {
12821278 userMetadata : await encodeUserMetadata ( dataConverter , options . staticSummary , options . staticDetails , context ) ,
12831279 priority : options . priority ? compilePriority ( options . priority ) : undefined ,
12841280 versioningOverride : options . versioningOverride ?? undefined ,
1285- links,
1281+ links : internalOptions ?. links ,
12861282 } ;
12871283 try {
12881284 const response = await this . workflowService . signalWithStartWorkflowExecution ( req ) ;
@@ -1350,19 +1346,6 @@ export class WorkflowClient extends BaseClient {
13501346 ) ;
13511347 }
13521348
1353- // Server currently only supports workflow_event and batch_job
1354- // link types. This filter should be removed or adapted as
1355- // server-side support comes online.
1356- // See https://github.com/temporalio/temporal/issues/10345
1357- const links = internalOptions ?. links ?. filter ( ( link ) => link . workflowEvent != null || link . batchJob != null ) ;
1358-
1359- const completionCallbacks = internalOptions ?. completionCallbacks ?. map ( ( cb ) => {
1360- const links = cb ?. links ?. filter ( ( link ) => link . workflowEvent != null || link . batchJob != null ) ;
1361- return { ...cb , links } ;
1362- } ) ;
1363-
1364- const resolvedInternalOptions = { ...( internalOptions ?? { } ) , links, completionCallbacks } ;
1365-
13661349 return {
13671350 namespace,
13681351 identity,
@@ -1394,7 +1377,7 @@ export class WorkflowClient extends BaseClient {
13941377 priority : opts . priority ? compilePriority ( opts . priority ) : undefined ,
13951378 versioningOverride : opts . versioningOverride ?? undefined ,
13961379 requestEagerExecution : opts . requestEagerStart ,
1397- ...filterNullAndUndefined ( resolvedInternalOptions ) ,
1380+ ...filterNullAndUndefined ( internalOptions ?? { } ) ,
13981381 } ;
13991382 }
14001383
0 commit comments