protected function load(array $ids = array())
    {
        $idsNotFound = array_filter($ids);

        $output = array();

        $stores = $this->stores;

        foreach ($this->stores as $storeName => $store) {
            if (!empty($idsNotFound)) {
                $objects = $store->load($idsNotFound);

                $loadedKeys = array_keys($objects);
                $remainingKeys = array_values(array_diff($idsNotFound, $loadedKeys));
                $idsNotFound = $remainingKeys;
                $output = $output + $objects;

                if (!empty($objects) && $store == $this->primaryStore) {
                    foreach ($stores as $storeName2 => $store2) {
                        if ($storeName2 !== $storeName) {
                            $ret = $store2->saveMulti($objects);
                        }
                    }
                }
            }
        }


        return $output;
    }