Skip to main content

Hi,



We are using the open-source tool grouper for managing the groups in BOX. The grouper uses the Box SDK to query the users or groups, manage the groups, and manage the group membership. The Box API throws a 503 error randomly while querying users or groups. Please review the error message and let me know if you need anything.



type: consumer, finalLog: false, state: init, consumerName: provisioner_incremental_boxProvisioner, totalCount: 147, currentSequenceNumber: null, publisherClass: edu.internet2.middleware.grouper.app.provisioning.ProvisioningConsumer, runId: vuk1k5nv, exception: java.lang.RuntimeException: provisionerClass: GrouperBoxProvisioner, configId: boxProvisioner, provisioningType: incrementalProvisionChangeLog, state: retrieveIncrementalTargetData, changeLogRawCount: 147, changeLogItemsApplicableByType: 106, recalcEventsDuringFullSync: 0, checkErrors: all, syncGroupsToQuery: 20, syncGroupsFound: 1, retrieveSyncGroupsMillis: 1, syncGroupCount: 1, filterByNotProvisionable: 89, convertToFullSyncScore: 17, recalcEventsDuringGroupSync: 0, syncMembershipsToQuery: 17, syncMembershipsFromMembership: 17, retrieveSyncMembershipsMillis: 3, syncMembershipCount: 17, syncMembersToQuery: 17, syncMembersFound: 17, retrieveSyncMembersMillis: 0, syncMemberCount: 17, retrieveDataStartMillisSince1970: 1693472400430, retrieveGrouperMshipsMillis: 7, grouperMshipCount: 17, retrieveGrouperGroupsMillis: 1, grouperGroupCount: 1, retrieveGrouperEntitiesMillis: 6, grouperEntityCount: 34, retrieveGrouperDataMillis: 14, exception: java.lang.RuntimeException: Invalid return code ‘503’, expecting: 200, 404, 429. ‘https://api.box.com/2.0/users?offset=39000&limit=1000&fields=name,id,login’ {“type”:“error”,“status”:503,“code”:“service_unavailable”,“help_url”:“http://developers.box.com/docs/#errors",“message”:"Service Unavailable”,“request_id”:“06725dc829d6ef2b12b228f9f58865fc9”},


Problem in job: retrieveEntity_boxProvisioner_vuk1k5nv


at edu.internet2.middleware.grouper.app.boxProvisioner.GrouperBoxApiCommands.executeMethod(GrouperBoxApiCommands.java:245)


at edu.internet2.middleware.grouper.app.boxProvisioner.GrouperBoxApiCommands.executeGetMethod(GrouperBoxApiCommands.java:151)


at edu.internet2.middleware.grouper.app.boxProvisioner.GrouperBoxApiCommands.retrieveBoxUsers(GrouperBoxApiCommands.java:730)


at edu.internet2.middleware.grouper.app.boxProvisioner.GrouperBoxTargetDao.retrieveEntity(GrouperBoxTargetDao.java:485)


at edu.internet2.middleware.grouper.app.provisioning.targetDao.GrouperProvisionerTargetDaoAdapter.retrieveEntityHelper(GrouperProvisionerTargetDaoAdapter.java:2463)


at edu.internet2.middleware.grouper.app.provisioning.targetDao.GrouperProvisionerTargetDaoAdapter.access$1200(GrouperProvisionerTargetDaoAdapter.java:43)


at edu.internet2.middleware.grouper.app.provisioning.targetDao.GrouperProvisionerTargetDaoAdapter$14.callLogic(GrouperProvisionerTargetDaoAdapter.java:2277)


at edu.internet2.middleware.grouper.app.provisioning.targetDao.GrouperProvisionerTargetDaoAdapter$14.callLogic(GrouperProvisionerTargetDaoAdapter.java:2268)


at edu.internet2.middleware.grouper.util.GrouperCallable$1.callback(GrouperCallable.java:203)


at edu.internet2.middleware.grouper.GrouperSession.callbackGrouperSession(GrouperSession.java:1000)


at edu.internet2.middleware.grouper.util.GrouperCallable.callLogicWithSessionIfExists(GrouperCallable.java:200)


at edu.internet2.middleware.grouper.util.GrouperCallable.call(GrouperCallable.java:166)


at java.util.concurrent.FutureTask.run(FutureTask.java:266)


at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)


at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)


at java.lang.Thread.run(Thread.java:750)


, finalLog: true, queryCount: 17, tookMillis: 88087, took: 00:01:28.087


at edu.internet2.middleware.grouper.app.provisioning.GrouperProvisioner.provisionFinallyBlock(GrouperProvisioner.java:910)


at edu.internet2.middleware.grouper.app.provisioning.GrouperProvisioner.provision(GrouperProvisioner.java:829)


at edu.internet2.middleware.grouper.app.provisioning.ProvisioningConsumer.dispatchEventList(ProvisioningConsumer.java:91)


at edu.internet2.middleware.grouper.changeLog.esb.consumer.EsbConsumer.processChangeLogEntries(EsbConsumer.java:503)


at edu.internet2.middleware.grouper.changeLog.ChangeLogHelper.processRecords(ChangeLogHelper.java:261)


at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$6.runJob(GrouperLoaderType.java:676)


at edu.internet2.middleware.grouper.app.loader.GrouperLoaderJob.runJob(GrouperLoaderJob.java:541)


at edu.internet2.middleware.grouper.app.loader.GrouperLoaderJob.execute(GrouperLoaderJob.java:345)


at org.quartz.core.JobRunShell.run(JobRunShell.java:202)


at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573)



Thanks,


Ameer Basha

Hi 👋,



Does this happen all the time? Where the solution never works? Or does it work most of the time and you only sometimes get a 503?



Thanks,


Alex, Box Developer Advocate 🥑


Hi,


Thanks for responding.



It works all the time, but sometimes throws 503 errors.



Thanks,


Ameer Basha


Yes - rare 503s are to be expected, especially in applications the make lots or frequent calls. It is recommended that retry logic is written into your code.



May I have the client ID of the application?


Hi,



Thanks for responding. I am providing the client id: 67wjzzov3cal8z44bwi31zjfrfij8f41


Thanks,


Ameer Basha


Reply