# |
Dec 12th 2019, 12:47 |
neon1024 |
Of what? An example of `null`? |
# |
Dec 12th 2019, 12:46 |
kevin.pfeifer |
example? |
# |
Dec 12th 2019, 12:45 |
neon1024 |
Anyone using Twig for templating having any issues with Entity accessor methods being NULL in the template |
# |
Dec 12th 2019, 12:45 |
neon1024 |
@jotpe Heading out in the rain at lunchtime to vote |
# |
Dec 12th 2019, 12:43 |
jotpe |
_how do i fix long running tasks? ->_ Call out general elections :troll: Hope you UK guys are decide wisely :uk: :flag-eu: |
# |
Dec 12th 2019, 12:42 |
neon1024 |
Or use a message queue |
# |
Dec 12th 2019, 12:42 |
kevin.pfeifer |
split your tasks for your background daemon into several smaller tasks so the database can respond for each small task? |
# |
Dec 12th 2019, 12:41 |
info315 |
I have a background daemon and it needs an method to reconnect to the DB... There is no other fix for this i guess |
# |
Dec 12th 2019, 12:40 |
neon1024 |
That’s the “How long is a piece of string?” question |
# |
Dec 12th 2019, 12:40 |
neon1024 |
Lots of ways, benchmark it, streamline it, chunk it, depends what it is, what it’s doing, where it’s running, and about 3.14m other variables |
# |
Dec 12th 2019, 12:39 |
info315 |
@neon1024 how do i fix long running tasks? |
# |
Dec 12th 2019, 12:38 |
ndm |
Doesn't 1 reconnect attempt happen automatically now? |
# |
Dec 12th 2019, 12:38 |
neon1024 |
Fix the script? |
# |
Dec 12th 2019, 12:35 |
info315 |
Is there a CakePHP 4 way to reconnect to the database to avoid mysql has von away issues for long running console scripts like i did in cake2? ``` // Avoid "MySQL server has gone away" $this->Cake->Systemsetting->getDatasource()->reconnect();``` |
# |
Dec 12th 2019, 10:47 |
boydbuenodemesquita |
I'm running in situations sometimes where my migrations fail halfway through. Stranding the database in a situation where migrate and rollback are both error. So I was checking for ways to reduce the change of that happening, so checking the queries after the migration will not solve that. Although I'm not sure if seeing the queries will actually help with anything. :P |
# |
Dec 12th 2019, 10:44 |
steinkel |
@boydbuenodemesquita poor man's dry-run would be: take a db-dump, enable query debug, run migrations, restore dump :slightly_smiling_face: |
# |
Dec 12th 2019, 10:35 |
boydbuenodemesquita |
Thanks for the help! |
# |
Dec 12th 2019, 10:33 |
boydbuenodemesquita |
Ah, might be that the current version doesn't support it. :( |
# |
Dec 12th 2019, 10:33 |
neon1024 |
Use `-h` to see options for any shell command 8) |
# |
Dec 12th 2019, 10:33 |
neon1024 |
Paydirt! |
# |
Dec 12th 2019, 10:33 |
neon1024 |
`-x, --dry-run Dump queries to standard output instead of executing it` |
# |
Dec 12th 2019, 10:33 |
neon1024 |
`$ bin/cake migrations migrate -h` |
# |
Dec 12th 2019, 10:33 |
neon1024 |
Teach a man to fish |
# |
Dec 12th 2019, 10:32 |
neon1024 |
Isn’t there a `--dryrun` option? |
# |
Dec 12th 2019, 10:30 |
boydbuenodemesquita |
Can anyone tell me if there is a way to dry-run migrations using the CakePHP CLI, instead of Phinx? |
# |
Dec 12th 2019, 09:29 |
javier.villanueva |
hi all |
# |
Dec 12th 2019, 09:04 |
neon1024 |
Morning everyone |
# |
Dec 12th 2019, 08:02 |
jotpe |
Morning! |
# |
Dec 12th 2019, 05:40 |
jpramirez |
And got my first review: https://github.com/FriendsOfCake/awesome-cakephp/pull/333 |
# |
Dec 12th 2019, 00:42 |
jpramirez |
Pull requested |
# |
Dec 12th 2019, 00:33 |
dev.cyrusjayson |
good morning |
# |
Dec 12th 2019, 00:33 |
dev.cyrusjayson |
thanks marco |
# |
Dec 11th 2019, 22:20 |
jpramirez |
Thanks, I will! |
# |
Dec 11th 2019, 22:15 |
voycey |
Submit this to awesome-cakephp :ok_hand: |
# |
Dec 11th 2019, 22:12 |
storkovo |
@jpramirez nicely done! |
# |
Dec 11th 2019, 21:49 |
slackebot2 |
https://github.com/pabloelcolombiano/cake-dm Fell free to try it and to contribute! Happy baking, Juan-Pablo |
# |
Dec 11th 2019, 21:49 |
slackebot2 |
framework. But I could not find anything really convincing. So I started implementing something for our CakePHP app. And it turned out that the way Cake is built, we could pretty easily split the MVC structure into mini MVC structures. At once, we started understanding our code again. I wanted to share my experience on that in a package. If you have or expect having an ever growing app, this could be of interest to you: |
# |
Dec 11th 2019, 21:49 |
jpramirez |
Hi channel, here is a little announcement, a kind of support hint for monster apps. Cake makes you build fast and grow solid. But over the years, my company's app has become too big and too rigid. The problem would have occurred with any framework. We postponed again and again, but at some point it had become impossible, we had to rethink our architecture. I searched for domain driven design approaches for CakePHP, or any other |
# |
Dec 11th 2019, 20:24 |
japerlman |
Thank you! |
# |
Dec 11th 2019, 20:24 |
japerlman |
Ok, thanks. That makes sense, it still isn't 100% clear but I'm sure I can figure it out from that page you linked. |
# |
Dec 11th 2019, 20:20 |
ndm |
To the memory, it's non-persistent runtime configuration. It can be persisted by using `Configure::store()` https://book.cakephp.org/3/en/development/configuration.html#storing-runtime-configuration |