<?php
// Included from marker function before either observer or business PDO.
$l=getenv('NF_LANE');if(!in_array($l,['B','C'],true))throw new RuntimeException('Exact lane before PDO');
$uuids=['B'=>'B8247519-0EDA-6239-9A8A-FEA2D6C86F4B','C'=>'FCEECEFB-C32E-4977-8A65-EE2210A42095'];$actors=['B'=>97260,'C'=>2791];
if(($plan['target'][$l]['uuid']??null)!==$uuids[$l]||($plan['target'][$l]['actor_id']??null)!==$actors[$l])throw new RuntimeException('Own actor mapping before PDO');
$base=__DIR__.'/private/baseline-original-'.$l.'.json';if(hash_file('sha256',$base)!==$plan['target'][$l]['baseline_sha256'])throw new RuntimeException('Exact baseline bytes before PDO');
$s=json_decode(file_get_contents($base),true)['source'];if(count($s['actor'])!==1||$s['actor'][0]['id']!==$actors[$l]||count(array_filter($s['nutrition'],static function($r)use($uuids,$l){return $r['uuid']===$uuids[$l]&&$r['name']==='CDXNF11F5-candidate-product';}))!==1)throw new RuntimeException('Exact baseline ownership before PDO');
$map=json_decode(file_get_contents(__DIR__.'/source-lock.json'),true);if(count($map)!==959||hash_file('sha256',__DIR__.'/source-lock.json')!==$plan['source_lock']['mapping_sha256'])throw new RuntimeException('Root source lock before PDO');
$actual=[];$iter=new RecursiveIteratorIterator(new RecursiveDirectoryIterator(__DIR__.'/source/application',FilesystemIterator::SKIP_DOTS));foreach($iter as $f){if($f->isLink())throw new RuntimeException('No source symlink');if($f->isFile()){$rel=substr($f->getPathname(),strlen(__DIR__.'/source/application/'));if(strpos(basename($rel),'._')===0)throw new RuntimeException('No AppleDouble source');$actual[$rel]=hash_file('sha256',$f->getPathname());}}
ksort($map);ksort($actual);if($actual!==$map)throw new RuntimeException('Complete actual APP959 source fileset');
if($plan['runtime']!=='/tmp/cdx-store-plain-overflow-fixed-20261011'||$plan['ports']!==['B'=>18981,'C'=>18982]||$plan['cache_prefix']!=='CDXNF11SCALARFIXED')throw new RuntimeException('Exclusive resources before PDO');
