Scenario: We have Configuration Page in Tridion, sometimes we get Error on Production Servers that the Configuration Page is not Published, that means it is not in DD4T Cache nor in Broker. We are using DD4T 2.2 and SDL Web 8.5, it is happening only for Configuration Page
Findings: Error comes exactly for the same time(5 minutes, strangely which is DD4T Cache duration as well) then it goes away and everything seems to be working fine.
When I went through the Code for DD4T Page Factory, it basically tries to search for a page from DD4T Cache and if is not in Cache then it fetches the Page from Broker and if it finds the page then it stores it in DD4T Cache, so the next time it will serve the Page from DD4T Cache only.
There is one more thing like if Page is not in Cache nor in Broker then it stores the Page in Cache with the Page Title "DD4T-Special-Value-PageNotFound", so the next time if we visit any Page and if the Page is in Cache but with the Page Title "DD4T-Special-Value-PageNotFound" then it will directly return null from Cache itself. And this will happen till the Cache duration which is Set in the Configuration File.
So basically First time if the page is not in Cache nor in Broker, DD4T set that special page title and store such pages in Cache so the next time it will Directly return null from Cache itself.
In Our case, Like we are getting null from Page Factory for exactly 5 minutes (DD4T Cache Duration), I assume Somehow the Page Title set to that DD4T Special Page Title and we get the Configuration Page Error.
Now the big Question is how?
What I Suspect is that as it is not able to find configuration page in the broker, and as it is only happening for Configuration page. And the Configuration page is very heavy, means it has all the configuration and schema's as key-value pair.
So is it a known issue in DD4T that it's not able to retrieve large pages from a broker?