8 Replies Latest reply on Jan 25, 2016 7:58 AM by Mariano Bosco

    API

    Mariano Bosco

        Hi to everybody!

       

      We are developing an API for a mobile app comunication in JSON based in FM server 13 & FM API PHP.

      We have a server web wich accepts the queries  from the mobile app and then the php running in the server web makes the queries to FM server and replies in JSON format to the app.

       

      The JSON replies are short messages ex.

      {

       

      "oggi":  

       

      {

       

      "visite_fatte": "1"

       

      "visite_da_fare": "2"

       

      }

       

      "settimana":  

       

      {

       

      "visite_fatte": "4"

       

      "visite_da_fare": "3"

       

      }

       

      "mese":  

       

      {

       

      "visite_fatte": "6"

       

      "visite_da_fare": "5"

       

      }

       

      }

       

      We also have 200 - 250 clients (app installations) that will use this API.

       

      The question is: Will FM Server have any problem with 200 - 250 clients that will query FM in the very bad situation "all together in the same time"?

       

      Web server: 4core - 8GB Ram

      FM Server: 8core - 32GB RaM

       

      Thanks to all!

       

        • 1. Re: API

          If performance/cost are not satisfactory, could you move your data from FMS to, say, MySQL or some other data server or is this a FM application that users are actively adding data to?

           

          You probably need to do some testing to see if the performance is satisfactory even if FMS can handle the connection count.

           

          - m

          • 2. Re: API
            CarlSchwarz

            Technical Specifications for FileMaker Server 13 | FileMaker

             

            Supported connections is 200, theoretical max 2000.  Your requests are very light!  I'd say you would struggle to notice that many people on the server at once based on tests I've done.

             

            All your PHP requests go through a single connection (the web server that hosts the PHP) and that changes things, you actually only have 1 connection!  I've never tested how that effects things at volume though but it does remove the 4-5 second connection establishment per new connection.  I'd assume that it is a good thing.

            • 3. Re: API
              APIcoder

              I've run the following test, based on your info

               

              Shell Script with 200 cURLl http request in sequence.

              Simulate a login:

              create a request to find a random user from 300 users.

              Simulate return data

              create a find request to return JSON data from a Filemaker field.

               

              It takes about 15 / 18 seconds, to perform to the commands in sequence.

              Keep in mind that the resulting data is processed quickly in this test setup.

              (The test circumstances are ideal, what the results positively influenced)

              With slow Internet from mobile devices, it takes somewhat longer

               

              Test Environment:

              1 Mac Mini server quad core i7

              Filemaker Server 13

               

              2 Mac mini server quad core i7

              Web Server , contains the PHP API files

              Shell Script run from Terminal

              • 4. Re: API

                Not knowing your client base, I would be surprised if more than 10% were concurrent at any one time.

                • 5. Re: API
                  CarlSchwarz

                  If those speeds are a problem then I need to point out that the mac mini is your problem.  They have laptop grade equipment, e.g. slow RAM/BUS speeds, smaller pipes (less bits per channel).  Get a couple of cheap servers with decent RAM speeds and XEON (server) CPU's and you'll see a good increase in performance.  That means going Windows because Mac doesn't make server hardware like that unless you want to spend the cash on a MacPro, but that's overkill (the expensive video cards do nothing for FMServer).

                  Then if you want more performance get proper database servers with all the database enhancing hardware.

                   

                  Next point - don't worry about the slow mobile speeds because you have a web server in the middle.  In one deployment we had mobiles directly accessing the servers through the PHP API and the lag brought the server to a halt (it would literally fail to respond).  Once we moved the PHP to a web server that had basically no lag to the Filemaker server then the server had instant performance again and the clients had very good access.  The web server in the middle would make the request to FMServer in a fraction of a second and handle the lag to the mobile, rather than FileMaker Server hanging on the lag.

                  • 6. Re: API
                    APIcoder

                    I just performed a test for TS,..... if it is slow or not, that is to the TS to decide

                    I do not say it's slow or fast.

                     

                    I do not think a Mac Mini Server 2012 i7 Quad-Core is so bad

                    In the past I've done speedtest between Windows Server and Mac Mini Server,

                    The Mac Mini 2012 i7 Quad-Core was often faster and more stable,

                    with our test environment, I do not say it's always the outcome.

                    I think (and hope) that a new Windows Server with a 8 or 12-CORE  will be much faster.

                     

                    Maybe someone can perform the same test on a fast Windows Server,

                    I like to know, possibly my next Server will be a Windows Server. (I think the new Mac Mini's are not an option for me)

                     

                    It is not the intention to let someone to choose, pro or con, Windows or Mac

                    I do not want to start a discussion, between Mac and Windows. I know the benefits of redundancy.

                    I have my reasons to choose a particular configuration and thats alright.

                    • 7. Re: API
                      CarlSchwarz

                      Apologies, I thought that you were the original poster and thought I should point out that the server setup will make a difference!  I think it's awesome that you ran such a detailed test for him.

                      The Mac Mini has a nice i7 processor but the processor is not the issue in the example above (simple find and the PHP API request).  It does however have small channel ram, it's either 16 or 32 bit, where as full size RAM is 64 bit.  It's 1600Mhz Ram and there is faster RAM, so wider pipes and faster RAM are available on a cheap desktop or blade server.  Same with the entire setup because it's made out of laptop components.  This is an explanation of the RAM in the Mac Mini (LPDDR3) Mobile DDR - Wikipedia, the free encyclopedia

                      So a cheap server gives you the option to purchase the stuff that's most important, SSD's, fast RAM.

                      An expensive database server has lots of weird things I don't understand... SAS has a different set of instructions for retrieving data than SATA, XEON CPU's are different to desktop CPU's targeted for server processing, and other stuff that makes server manufacturers quote that their servers serve databases several *times* faster than standard servers.  And I see those results on Filemaker when it gets pushed.

                       

                      ... Just adding, that I have noticed that an iMac will be a faster database server than a Mac Mini (not in specific tests, it just 'felt' faster) and I just checked the tech specs page because I assumed that the iMac had the same RAM, and it still does have LPDDR3 RAM but it has a faster speed.  So there you go!

                      • 8. Re: API
                        Mariano Bosco

                        Hello to everyone from your advice and your experience, I understand that I should not have big problems, and the only thing that you need a good internet connection.

                        If you have other tips do not hesitate to post them

                        Thank you all