We've implemented a custom web part which we use to render content of an external website into a SharePoint page.
During our test we encountered some strange performance issues.
When we open a page with the web part for the first time it takes about 5 - 7 seconds to load the entire SharePoint page. If we then quickly (within the next 20-30 seconds) load another page with the same web part or click a link within the web part which reloads the page the whole page loads within 400 to 700 milliseconds.
But when we wait for a longer time before loading a new page or reloading the page the whole loading process of the SharePoint page takes again about 5 to 7 seconds.
The logic of our web part is very simple. Every time it loads, we dynamically request content of the external website. We don't use any caching mechanism in our web part.
To find the reason for the bad performance we activated the developer dashboard with extended tracing and and could see the event/step which takes so much time. Unfortunately we don't know what SharePoint does in this step. And also Google has no information for us on this.