I'm seeing intermittent 404 errors when attempting to use lightning components inside a Visualforce page via Lightning Out, but one org seems far more affected than others.
The VF markup:
<apex:page standardController="AMS_Order__c" >
<apex:includeLightning />
<div id="lightning"/>
<script>
$Lightning.use("c:BGM_OB_OrderHeaderApp", function() {
$Lightning.createComponent("c:BGM_OB_OrderHeaderContainer",
{orderId: "{!AMS_Order__c.Id}"},
"lightning"
);
});
</script>
</apex:page>
So pretty much as per the docs and has been working fine for several months now.
Since Winter 17, and particularly in one org, I get intermittent blank page results, and when I go to the JavaScript console I see the following error:
Failed to load resource: https://bgm-dev-ed--c.eu3.visual.force.com/c/BGM_OB_OrderHeaderApp.app?aura.format=JSON&aura.formatAdapter=LIGHTNING_OUT the server responded with a status of 404 (Not Found)
If I open that URL directly it works every time I try it. After I've loaded the app reference directly, the page then loads. I can also make the page load by disabling the cache and reloading 5-6 times.