Skip to main content
Inspiring
March 17, 2009
Answered

Slowing down my code

  • March 17, 2009
  • 2 replies
  • 376 views
I need to make a loop progress slower than it currently is. I have code that loops through a list of about 10,000 users and checks them against our companies LDAP server. Well this week our company instituted a policy that only allows around 200 hits per minute to the server from a single machine. Once you exceed that limit they lock your machine out. I found this out the hard way.

Is there a way I can force my code to pause during each iteration of the loop?
    This topic is closed to new replies. Start a new post to keep the conversation going.
    Correct answer Newsgroup_User


    Latests versions of CF, the sleep() function. Earlier MX versions
    java.lang.Thread.sleep() functions. Google for the exact syntax.

    2 replies

    spacehogAuthor
    Inspiring
    March 17, 2009
    Thanks. Looking into cfthread and sleep()
    Newsgroup_UserCorrect answer
    Inspiring
    March 17, 2009


    Latests versions of CF, the sleep() function. Earlier MX versions
    java.lang.Thread.sleep() functions. Google for the exact syntax.