6 Replies Latest reply on Mar 25, 2014 7:55 PM by submarine

    Web Speed Lag


      We have are testing 12 in preparation to moving a system across.


      During testing, we have all noticed intermittent slowness on the FM12


      Here is what we found:

      (1) it is not an issue with the code, since the problem still occurred after stripping down the login page


      (2) TEST PAGE runs 80 queries nonstop: first, 20 fx, then 20 FM API, then 20 XML1 and finally, 20 XML2

      The numbers are the seconds that it takes to run the query, which are usually 1/10 sec, except when it lags

      The time in seconds is for the query only - no display of data or any other code.

      The 20 queries (eg, using fx) are the same, so the time differences are du e to server resources


      The results:

      If no one is on the system, the first two queries always take 20 seconds, then the queries are fast

      One minute later, the queries are slow 10 sec + 10 sec (approx)

      Then the queries speed up again , about 1/10 sec

      Every minute, the queries slow down.


      Effects of running it simultaneously in two browsers:

      While the first page is running the 80 queries, open the page in another browser (don't use same browser, you will be in same session)

      You will find that the queries on the second page hit a lag at the same as the queries on the first page. If the first page has just finished the lag when you open the page in the second browser, the first queries will be fast.



      The first query causes something to run. (I will call it a process.) It may be some type of connection script. (database? port ? or?) Something that must be active in order for FM db to be accessed

      This process runs every minute and takes about 20 seconds (because this is how long the queries are delayed during the lag time)

      When a query is run, something checks to see if the process has been run in the last minute; if not, it runs the process and re-sets the process clock to run one minute from that time.

      If there are 2 browsers open running the queries, instead of taking 10 seconds each for 2 queries (20 seconds), one query takes 20 seconds, so it becomes slower with added users.


      The Effect

      If you log in and it has been more than a minute since anyone has run a query, your login will be slow

      If someone has logged in more than 20 seconds but less than one minute ago, then your login will be fast

      If you run a search or any other action that requires a query and it has been more than a minute since someone else has r un a query, it will be slow




      Would be interested if anybody has either exprienced this issue or has a view on its causes. Other than the lag the system is considerably faster.


      System is running on a new server with 12gb of ram allocated to FM and fast HD's


        • 1. Re: Web Speed Lag

          Hi msawyer,


          I hope you still can read this old post.

          I am experiencing the same issue. Please see my post here - https://fmdev.filemaker.com/message/142675#142675


          On top of what you have described, I noticed an interesting fact when I am finding solution for this issue --

          I have 2 FM systems using PHP API. Both are embedded to a web portal.


          We authenticate users via single sign on where the portal login info will be passed on to a FM table to check the validity of a user. The FM table is a ODBC table - the same table storing the portal logins.

          Both systems have the same authentication process at the beginning and theoritically both should have the same lag as described by you, BUT it is not.


          One of the systems has no lag at all, it is all time 1/10 sec regardless of the sequence of running, while the other system has the exact lag as mentioned by you.

          The only distinct difference between the 2 systems is the fast system is a converted file from FM11 to FM12 and the slow system is a new file created in FM12.


          I wonder if this provides a clue to some expert out there?

          a 10 sec lag is totally unacceptable. How you resolve this issue?

          • 2. Re: Web Speed Lag

            Check the memeory available to FMS. IS it a decated machine or sharing resources with other apps or FM solutions?


            If the machine (or vitual machine) runs out of memory it resorts to swapping memory pages to disk which can cause sudden yet intermittent slowdowns.

            • 3. Re: Web Speed Lag

              If converted file is fast, you can chech whether the thema of new file is classic.

              • 4. Re: Web Speed Lag

                Had these issues once, make sure you have any external authentication accounts/groups in your account security are moved down the bottom of your list. When making a call to the database via CWP, if you use a local account FMS will try to authenticate each account in the order that is set in the accounts section. If you have an AD group above your local account, it will first authenticate through your AD server before authenticating the local account. Depending on the speed of your AD authentication, this can cause huge lag when web publishing. To see if it is the cause, drag the AD authentication groups to the bottom of the accounts list (so they authenticate last) or just temporarily remove them.

                Hope this helps.

                • 5. Re: Web Speed Lag

                  We had a similar situation with a CWP solution, and ended up having to completely disable the AD accounts. Never did solve it, even with valiant efforts on the part of FM Tech Support, because other databases on the same server operated normally. Weird.

                  • 6. Re: Web Speed Lag

                    Thanks PowerSlave, putting the AD groups to the bottom works for me!!!

                    The data query is unnoticeably fast now.