Becker Maxime
FileUpload multi-node
I have set up a FilamentPHP v2 & v3 application on a multi-node Docker architecture without shared volumes between the containers. For file uploads, I am using S3, as my containers do not have persistent local volumes. However, I am encountering an issue: files are not always uploaded correctly. This problem becomes more frequent as I add more nodes to the cluster.
This behavior seems to be related to how file uploads are handled in a multi-node environment, since everything works fine when I only use a single node. Here are my assumptions based on my observations:
1. Initial upload: When a user uploads a file, it might be temporarily stored on the node that received the request.
2. Multi-node issue: In a multi-node setup, the server that receives the file and temporarily stores it may be different from the one that handles the final operation, such as saving it to S3. If each node has its own isolated local storage, this could explain why the file upload occasionally fails, especially when multiple nodes are involved.
To try to resolve this issue, I configured Traefik with sticky sessions, so that each user is consistently directed to the same node for their requests. Unfortunately, this doesn’t seem to completely fix the problem, or there may be an issue with my Traefik configuration.
Do you have any advice or solutions for effectively handling file uploads in a multi-node Docker environment, especially with setups like this? Any suggestions would be appreciated.
Here is the code:
2 replies
Action update a component
Is it possible to update a component after an action?
example :
EditRecord.php getHeaderActions(): Resource.php form(): I'd like my buttons to appear when I update my selection without having to reload the page. Is this possible?
EditRecord.php getHeaderActions(): Resource.php form(): I'd like my buttons to appear when I update my selection without having to reload the page. Is this possible?
2 replies
Repeater pivot
Hi, I'm having a problem with the repeater.
My problem: I've created a pivot table but I don't understand why it doesn't go into the pivot table but into the artist table, so it creates a new artist for me every time I add it, when my aim is for it to register only in my pivot table.
7 replies
Error configure.php
I'd like to create a filament plugin, I've retrieved the "Filament Plugin Skeleton" template, but I get an error when I type php./configure.php
PHP Parse error: syntax error, unexpected '=>' (T_DOUBLE_ARROW) in /home/beckerm/Projects/customers-management/configure.php on line 139
13 replies