Search Engine: Elastic

Article ID: 134597, created on Nov 19, 2019, last review on Nov 19, 2019

Symptoms

Periodic task "Synchronize resource usage for APS application instance #123 (Azure Cloud Solution Provider)" fails with error like this:

Could not get resource usage for resource with UUID 'b3dd0a42-baea-557b-a1e3-854d51a457e7': Could not invoke endpoint url 'https://192.168.0.10:10443/azure/aps/tenants/b3dd0a42-baea-557b-a1e3-854d50a457e7' of application instance with UUID '75fac3d9-d152-4270-b41b-43f6bd2b4554'. RESTEASY004655: Unable to invoke request: Read timed out
500 Internal Server Error

The following error can be seen in azure.log :

2019-10-27 22:10:31,932 DEBUG [com.odin.azure.server.ServerLogs] (azure task-111) <SERVER> Incoming request: GET https://192.168.0.10:10443/azure/aps/tenants/b3dd0a42-baea-557b-a1e3-854d50a457e7
- headers:
        Accept-Encoding: gzip
        APS-Controller-URI: https://172.16.77.33:6308/
        APS-Instance-ID: b3dd0a42-baea-557b-a1e3-854d51a457e7
        APS-Version: 2.2
        Connection: Keep-Alive
        Host: 192.168.0.10:10443
        User-Agent: Apache-HttpClient/4.5.4 (Java/11.0.4)
        X-Correlation-ID: task:798441 Thread-95166-(ActiveMQ-client-global-threads):191307 pau
- body:
- end

...

2019-10-27 23:09:41,264 INFO  [com.odin.azure.api.PartnerCenterApi] (azure task-111) Starting request. Attempt 0         Time: 23:09:41.264
2019-10-27 23:09:42,540 INFO  [com.odin.azure.api.PartnerCenterApi] (azure task-111) Request completed                   Time: 23:09:42.540
2019-10-27 23:09:42,540 INFO  [com.odin.azure.api.PartnerCenterApi] (azure task-111) <PCSDK> The request: 'GET https://api.partnercenter.microsoft.com/v1/customers/1e88***1-92bfdef65aea/subscriptions/1B46E***0CD15A3/utilizations/azure?seek_operation=Next' has been completed: 'HTTP/1.1 401 Unauthorized access'
-headers:
        Content-Length: 0
        MS-CorrelationId: 8
        MS-RequestId: 
        MS-CV: zOHJXZ0fFk6iqWSJ.0
        MS-ServerId: 0000112D
        Request-Context: appId=cid-v1:03ce8ca8-8373-4021-8f25-d5dd45c7b12f
        WWW-Authenticate: Bearer, Bearer, Bearer, Bearer, Bearer, Bearer, Bearer, Bearer, Bearer
        Date: Sun, 27 Oct 2019 23:09:41 GMT

2019-10-27 23:09:42,540 ERROR [com.odin.azure.api.PartnerCenterApi] (azure task-111) Partner service failed response:
2019-10-27 23:09:42,543 DEBUG [com.odin.azure.api.PartnerCenterApi] (azure task-111) <API-GATE> Request failed: [com.microsoft.store.partnercenter.exception.PartnerException] Unauthorized access
2019-10-27 23:09:42,543 ERROR [com.odin.azure.common.JsonUtils] (azure task-111) Cannot parse JSON as type 'com.odin.azure.api.resources.pc.PartnerCenterErrorResponse': Unrecognized token 'Unauthorized': was
expecting ('true', 'false' or 'null')
 at [Source: Unauthorized access; line: 1, column: 13]
2019-10-27 23:09:42,544 ERROR [com.odin.azure.common.JsonUtils] (azure task-111) Cannot parse JSON as type 'com.odin.azure.api.resources.pc.CrestErrorResponse': Unrecognized token 'Unauthorized': was expecting ('true', 'false' or 'null')
 at [Source: Unauthorized access; line: 1, column: 13]

According to logs, usage was collected for the subscription for more than one hour.

Cause

Software-related issue #APSA-21670. Token received from Microsoft have a lifespan of one hour. But actually it expires earlier than that in some cases. Such situation is not processed by the application properly when subscription is being synchronized for more than one hour.

Resolution

There is no workaround for the case.

Contact your Technical Account Manager in order to clarify status of the issue.

Email subscription for changes to this article
Save as PDF