Pergunta AppFabric Cache - Performance

  • 02 Agustus 2012 8:11
     
      Memiliki Kode

    I have developed a RESTful `WCF` service (`WebHttpBinding`), which is an AppFabric Cache client. I ran a performance test using jMeter. The test plan contained one operation in the service, which will be called in 100 concurrent threads.

    However, I noticed that after running the test, `the first 20 to 30 threads are taking considerable amount of time to get the response (say 10-15 seconds)` and then all the other remaining threads will complete their execution in 2-3 seconds with AppFabric Cache related code turned on. Whenever I comment the AppFabric related code, it works just fine. Please note that I use only Get, no Put.

    My service has the below configurations as t AppFabric:

      

        <dataCacheClient requestTimeout="60000" channelOpenTimeout="15000" maxConnectionsToServer="2">
            <localCache isEnabled="true" sync="NotificationBased" ttlValue="300000" objectCount="100000" />
            <clientNotification pollInterval="10" maxQueueLength="100000" />
            <hosts>
              <host name="**********" cachePort="*******" />      
            </hosts>
            <securityProperties mode="Transport" protectionLevel="EncryptAndSign" />
            <transportProperties connectionBufferSize="131072" maxBufferPoolSize="268435456" maxBufferSize="8388608" maxOutputDelay="2" channelInitializationTimeout="60000" receiveTimeout="600000" />
          </dataCacheClient>

    Could someone please give some pointers as to what is causing this initial delay?

     

     

     

     

Semua Balasan

  • 03 Agustus 2012 16:37
     
     

    Are the first threads blocking while waiting for the creation of the datacachefactory ? This is an expensive operation as it establishes connections to each node in the cluster.

  • 06 Agustus 2012 2:37
     
     

    Hi,

    The DataCacheFactory will already be initialized at the application start. The operation that I am trying to test will have the DataCacheFactory already avaiable by the time I start testing. The DataCacheFactory is static and is available across the application for all operations once the application is up.