Skip to content
Advertisement

Tag: laravel

Default to Laravel File cache if redis is down

In the spirit of “chaos monkey” I’m trying to ensure that a laravel application keeps going even when the services it depends on are down. It uses a DB for primary storage, and a redis cache. What I’d like to do is have it automatically fall back to the file cache if and when redis fails. I haven’t been able

Laravel, how to ignore an accessor

I have a model with a custom accessor so I get that custom attribute, But now, in one case, I need to get only some fields, without this OrderContents one. But doing it this way, it returns me the OrderContents as well.. is there a way to not get that field? Thanks! Answer There’s no way to do it in

Advertisement