Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9259621
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T12:42:02+00:00 2026-06-18T12:42:02+00:00

I am using the default service GroupsManager and Group to scan through all groups

  • 0

I am using the default service GroupsManager and Group to scan through all groups in a domain, check if a group does not have an owner and in that case set a default owner.

The number of groups in the domain are almost 2000 and this causes me a timeout. I have tried a try/catch statement inside the loop that processes the each group, but Google kills the script on the timeout.

I am happy to do this in batches, but how can I actually continue to execute my script once a timeout has occurred? Or am I supposed to monitor the execution time and use some sort of sleep?

Or do I have to face the reality and restart the script after each timeout.

Really need a response to this, thanks!

/ Don Pedro

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T12:42:03+00:00Added an answer on June 18, 2026 at 12:42 pm

    You shouldn’t let the script time out but instead try to process a limited number of items at a time on a specific time interval using a timer trigger.

    Well I guess you could answer that this is more easily said than done … but it is actually very simple :

    1. determine approximately how many group you can check in about 3 minutes (max execution time is 5′ but it’s always better to keep a comfortable margin)
    2. Count the processed groups and put this counter value somewhere… preferably in scriptProperties
    3. setup a timer trigger every 10 minutes or so that calls your function starting with the group indexed by the number you just memorized (the trigger can be set programmatically and removed as well or manually in the ressource menu of the script editor).
    4. kill the timer when you have reached the end of your task (again manually or programmatically)

    Hoping this will give you enough indications to start with.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a WCF service using BasicHttpBinding with Windows authentication. Most clients are domain
So I've been using the Windows Workflow default SQL persistence service that handles everything
I have webserver using default virtualhost apache <VirtualHost *:80> ServerAdmin webmaster@localhost DocumentRoot /var/www <Directory
I have been using the default colors Grey and Blue for cell selection, but
I have implemented whole push notification service for my application using easyapns . I
I'm using godaddy for hosting my site and using default godaddy mail service. Now
I am using the default hudson installation on windows as a service. It is
I have created a C# web service using visual studio to stop the windows
I'm trying to POST to a REST service using the default WebHttpBinding binding. The
I have web application running with a default impl of a backend service. One

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.