3 Replies Latest reply on Nov 17, 2017 3:28 PM by jstarnes

    Deleting event frames too slow

    ibrahimnoureddine

      Hello ,

       

      I am trying to delete event frames between two dates (hour by hour) ;

      I first used AFEventFrame.FindEventFrames , it was fast enough however i can't use it since i want to delete all event frames within a start-end date but i don't know the count

      of the event frames between these two dates so it will not work. So i used AFEventFrameSearch.FindEventFrames but it's too slow in getting event frames within two dates that doesn't 

      contain event frames.

      Assume i have event frames at 22/09/2017 at 8:00 am , and the user picked the start date at 20/09/2017 and the end date 23/09/2017 ,

       

      The RPC Metrics for the AFEventFrame.FindEventFrames is :

      2017-11-17 09:44:49: [Message] AF client

      2017-11-17 09:44:49: [Message] name : CheckInDatabase, count : 3,  Elapsed :661.4

      2017-11-17 09:44:49: [Message] name : GetRpcMetrics, count : 1,  Elapsed :63.9

      2017-11-17 09:44:49: [Message] name : FindEventFramesByTime, count : 1,  Elapsed :3181.8

      2017-11-17 09:44:49: [Message] name : GetEventFrame, count : 1000,  Elapsed :26071.3

      2017-11-17 09:44:49: [Message] name : GetElementTemplateList, count : 1,  Elapsed :396.4

      2017-11-17 09:44:49: [Message] name : GetElementTemplate, count : 1,  Elapsed :400.5

      2017-11-17 09:44:49: [Message] name : CheckInEventFrame, count : 7,  Elapsed :8848.5

      2017-11-17 09:44:49: [Message] AF server

      2017-11-17 09:44:49: [Message] name : GetElementTemplateList, count : 1,  Elapsed :122.5

      2017-11-17 09:44:49: [Message] name : FindChangesRID, count : 40,  Elapsed :1650.6

      2017-11-17 09:44:49: [Message] name : GetElementTemplate, count : 1,  Elapsed :77.5

      2017-11-17 09:44:49: [Message] name : CheckInDatabase, count : 3,  Elapsed :650.3

      2017-11-17 09:44:49: [Message] name : FindChangesRID_NoChange, count : 36,  Elapsed :0.6

      2017-11-17 09:44:49: [Message] name : SetValue, count : 1,  Elapsed :40.2

      2017-11-17 09:44:49: [Message] name : CheckInEventFrame, count : 7,  Elapsed :8331.1

      2017-11-17 09:44:49: [Message] name : FindEventFramesByTime, count : 1,  Elapsed :2930.4

      2017-11-17 09:44:49: [Message] name : GetEventFrame_CheckOut, count : 1000,  Elapsed :10336.9

      FindEventFramesByTime is taking a max time of 3 sec .

       

      however when using AFEventFrameSearch.FindEventFrames the RPC Metrics for each hour(not containing any event frame) is :

      2017-11-16 03:01:00: [Message] AF client

      2017-11-16 03:01:00: [Message] name : GetCheckOutInfo, count : 2,  Elapsed :12.6

      2017-11-16 03:01:00: [Message] name : CheckInDatabase, count : 2,  Elapsed :18.3

      2017-11-16 03:01:00: [Message] name : GetRpcMetrics, count : 1,  Elapsed :243.0

      2017-11-16 03:01:00: [Message] name : SearchEventFrames, count : 1,  Elapsed :71091.8

      2017-11-16 03:01:00: [Message] AF server

      2017-11-16 03:01:00: [Message] name : GetSystemVersions, count : 10,  Elapsed :13.8

      2017-11-16 03:01:00: [Message] name : ReportServerStatus, count : 10,  Elapsed :0.1

      2017-11-16 03:01:00: [Message] name : GetCheckOutInfo, count : 2,  Elapsed :1.5

      2017-11-16 03:01:00: [Message] name : CheckInDatabase, count : 2,  Elapsed :5.8

      2017-11-16 03:01:00: [Message] name : GetReservedKeys, count : 1029,  Elapsed :5142.2

      2017-11-16 03:01:01: [Message] name : CheckInEventFrame, count : 7,  Elapsed :21938.7

      2017-11-16 03:01:01: [Message] name : SearchEventFrames, count : 1,  Elapsed :71086.3

       

      SearchEventFrames is taking 71 sec , in an hour empty of event frames. however it's fast if event frames exist in the chosen hour.

      so it will take about an hour just to retrieve nothing !

      what should i use ?

      thank you ,