You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the payload above would have a timeout below 800ms, the call will fail.
288
-
289
-
## Call Chaining a basic Java Call
248
+
### Call Chaining a basic Java Call
290
249
291
250
We can chain a series of java calls in the same payload:
292
251
@@ -360,7 +319,7 @@ In the example above "ID-2" will use the return value of the call "ID-1" as ts f
360
319
**NOTE** : When passing a call result as an argument, it needs to be a String. In many languages such as JavaScript, the
361
320
JSON keys need not be a string, however, for this to work you need to pass the ID as a string.
362
321
363
-
### Call Chaining and Instance Methods
322
+
####Call Chaining and Instance Methods
364
323
365
324
We now have the possibility of injecting call results from one call to the other. In the example below we instantiate an
366
325
object, and in the following call we call a method of that object. This is done by passing the ID of the first call as
@@ -389,6 +348,61 @@ the `instance` value for the following call.
389
348
390
349
In the example above "ID-2" will use call the instance method of the object created in call "ID-1".
391
350
351
+
### Argument Types
352
+
Since we are using JSON to pass values to the method, we need to cover how different types are passed.
353
+
354
+
#### Simple Java Objects
355
+
The internal Java objects such as int, String and boolean can be passed with no problems
356
+
357
+
#### Lists and Arrays
358
+
List and Arrays can be passed as JSONArrays. IBS will transform them to the target argument when needed (_Available since 2.116_).
359
+
360
+
#### Complex Types
361
+
Some methods require complex Objects as arguments. In this case you need to have a constructor/factory call in one call, and pass they key as an argument.
362
+
363
+
#### Files
364
+
As of version 2.11.16 we have the possibility to pass a file to the bridgeService. When doing so, you need to send your request as a multi-part request. As in most multi-part requests, you need to give each uploaded file a key value. In that case the file is referenced with that key value.
365
+
366
+
## Managing Timeouts
367
+
368
+
As of version 2.11.6 we now introduce the notion of timeouts. This means that after a declared time a call will be
369
+
interrupted. Setting this value can be done at two levels:
370
+
371
+
* The deployment level
372
+
* The Call session
373
+
374
+
**Note :** If set to 0, there is no timeout.
375
+
376
+
### Setting Timeout Globally
377
+
378
+
You can set a default value when starting the service. This is done by setting the environment
379
+
variable `IBS.TIMEOUT.DEFAULT`. If not set, the default value is 10000ms.
380
+
381
+
### Setting a Timeout for the Call Session
382
+
383
+
We can also set the Timeout for a java call transaction. In that case the value you pass overrides the global value, but
384
+
only for you session. If the `timeout` is not test in the payload at the next call, the global value will be used.
385
+
386
+
In the example below the method `methodWithTimeOut` waits for the provided, in this case 800ms, amount of time. In the
387
+
example below the test will pass because we wait for 800ms, and the timeout is 1000s.
Copy file name to clipboardExpand all lines: ReleaseNotes.md
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -3,8 +3,10 @@
3
3
## 2.11.16-SNAPSHOT
4
4
***New Feature**[#3 Include an Assertion Feature](https://github.com/adobe/bridgeService/issues/3). We have now included the possibility for users to define assertions. This allows you to clarify accepted results for the call you make with the IBS.
5
5
***New Feature**[#79 Allow or passing secrets in headers](https://github.com/adobe/bridgeService/issues/79). You can now pass variables and secrets as headers.
6
+
***New Feature**[#110 Allow for Fileuploading and Multi-part requests](https://github.com/adobe/bridgeService/issues/100). We can now upload a file and reference it in the request.
6
7
*[#111 Allowing the passing of array and vararg arguments](https://github.com/adobe/bridgeService/issues/111). Previously we were unable to execute methods accepting Arrays and varargs. This has now been corrected.
7
8
*[#88 Logging action steps](https://github.com/adobe/bridgeService/issues/88). We now log the steps we take during execution for better debugging.
9
+
*[#48 Logging action steps](https://github.com/adobe/bridgeService/issues/48). We now log the current class and method being executed.
8
10
9
11
## 2.11.15
10
12
*[#71 Adding step name when throwing exceptions](https://github.com/adobe/bridgeService/issues/71). When an exception happens, include the step in which it occurred.
0 commit comments