HaoWang9909 commented on issue #5526:
URL: https://github.com/apache/openwhisk/issues/5526#issuecomment-2591651091

   Hi! Thank you for your response!
   I did not use the FPCpoolBalancer, so I did not use the scheduler.
   # Prewarm Duration Discrepancy
   ## Experiment Setup: 
   I performed five separate experiments.
   1. Using ansible to deploy a new openwhisk service every time.
   2. Invoke the first action from a Prewarm container.
   3. Invoke subsequent actions from the same setup, but using different 
Prewarm containers.
   
![Image](https://github.com/user-attachments/assets/fc686dc0-1861-446f-a636-b01cb2a28d85)
   ## Observations:
   1. The first invocation consistently exhibited a higher duration compared to 
subsequent invocations, even though all were executed from Prewarm containers 
(not Cold Start or Warm Start).
   2. This discrepancy is primarily due to increased initialization time.
   
   ## Hypotheses
   I guess it might have something to do with the File System and Linux Page 
Cache.
   So I deployed Openwhisk one more time and performed five invocations from 
the same deployment. However, before each invocation, I cleared the system 
cache using the following command:
   ```
   sudo sync; echo 3 > /proc/sys/vm/drop_caches
   ```
   ## New Observations: 
   As shown in the figure below , each invocation took similar time ( 1600ms 
for the ”TN” action), regardless of whether it was the first or a subsequent 
invocation. This duration matched the first invocation times of the first 
invocation from the previous experiments.
   
   
![Image](https://github.com/user-attachments/assets/eb40d1fe-c91d-47a3-b586-23f3339173f4)
   
   #  Prewarm vs. Cold Start
   ## Experiment Setup:
   A comparison was made between the Prewarm container’s first invocation 
duration and the Cold Start duration.
   ## Observations:
   Initial observations suggested that Prewarm container initialization could 
occasionally be slower than Cold Start. However, further experiments revealed 
that this is not consistently the case. For example, the first Cold Start 
invocation of the ”TN” action occasionally reached durations of 2000ms or 
1800ms, which exceeded the Prewarm container’s first invocation duration. So my 
previous discovery may only be an accidental phenomenon.
   
   # Question
   Is my hypothesis correct that the discrepancy in Prewarm container 
initialization time is caused by the absence of file system caching during the 
first invocation?
   
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to