Quantcast
Channel: UiPath Community Forum - Topics tagged error
Viewing all articles
Browse latest Browse all 4384

Orchestrator API - bearer Token cancellation Error via UiPath Studio

$
0
0

@Adrian_Star wrote:

Hi,
I have a problem colecting data from the Orchestrator database via API queries from UiPath Studio.
I created a mechanism for collecting parameters (counters) of status of cases in queues. I used the for each function to search through subsequent queues and collect data to the table.

The first authentication takes place without problems, data is collected and loaded into a row in the table.
At the second attempt, an error appears:
If I have used the Authentication sequence in the ‘for each’ activity, the error is on the second Authentication, I get the error:

RemoteException wrapping System.InvalidOperationException: Could not invoke client method.  ---> RemoteException wrapping System.ObjectDisposedException: Cannot access a disposed object.
Object name: 'System.Net.Http.HttpClient'. 
   at System.Net.Http.HttpClient.CheckDisposed()
   at System.Net.Http.HttpClient.SendAsync(HttpRequestMessage request,
HttpCompletionOption completionOption,
CancellationToken cancellationToken)
   at UiPathWebApi.AccountClient.<AuthenticateAsync>d__14.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at UiPath.WebClient.Activities.Generator.Swagger.BaseSwaggerActivity`3.<ExecuteAsync>d__50.MoveNext()
	--- End of inner exception stack trace ---
   at UiPath.WebClient.Activities.Generator.Swagger.BaseSwaggerActivity`3.<ExecuteAsync>d__50.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at UiPath.WebClient.Activities.Generator.Code.AsyncTaskCodeActivityImplementation.EndExecute(AsyncCodeActivityContext context,
IAsyncResult result)
   at UiPath.WebClient.Activities.Generator.Code.AsyncTaskCodeActivity.EndExecute(AsyncCodeActivityContext context,
IAsyncResult result)
   at System.Activities.AsyncCodeActivity.System.Activities.IAsyncCodeActivity.FinishExecution(AsyncCodeActivityContext context,
IAsyncResult result)
   at System.Activities.AsyncCodeActivity.CompleteAsyncCodeActivityData.CompleteAsyncCodeActivityWorkItem.Execute(ActivityExecutor executor,
BookmarkManager bookmarkManager)

In turn, if authentication pulls before activity ‘for each’ error, it appears when processing the second case in Get Queue Definitions.
The error message is similar in both cases, and it’s about canceling the Token.

Is the problem the validity of bearer Token?
The production environment has Orchestator 2018.4.4, and the documentation says that the default course is 30 minutes.

https://docs.uipath.com/orchestrator/v2018.4/reference#authenticating

What settings do I have on the Orchestrator, I do not know yet - this is in the process of determining, but please direct me if the cause of the problem lies in the bearer Token?

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 4384

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>