Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple Beanstalk Hosts #4

Open
teamhoodin opened this issue Mar 3, 2017 · 1 comment
Open

Multiple Beanstalk Hosts #4

teamhoodin opened this issue Mar 3, 2017 · 1 comment

Comments

@teamhoodin
Copy link

Hello, and thanks for the nice package!

We're running a slightly bigger project with a centralised admin system and 3 different Beanstalk hosts. Is there a way to use the admin ui for all 3 of these within the admin system we have, ie for it to talk to 3 hosts simultaneously?

Also, is there (going to be) a way to view/delete the contents of an entire tube?

Thanks!

@ksassnowski
Copy link
Collaborator

ksassnowski commented Mar 3, 2017

Right now the project only supports a single host (https://github.com/Dionera/laravel-beanstalkd-admin-ui/blob/master/src/BeanstalkdUIServiceProvider.php#L21). Talking to all three hosts simultaneously could be a bit difficult to achieve (as in, having the stats for all hosts on a single dashboard). However, I think that adding another menu item to select from the configured hosts and only displaying the stats for that host shouldn't be too hard. I don't know when I will be able to get to it, so pull requests are always welcome :)

Here's roughly what would have to change:

  • Instead of passing in the host and port into the Pheanstalkd instance in the Service Provider , it would have to get built dynamically depending on which host is selected.
  • So maybe instead of having just a host and port option in the config, add an array hosts that consists of the connection data for all existing hosts.
  • Add some mechanism to tell the Repository which host to query. Either by creating some sort of factory and building it in the controller, or by providing an extra host parameter that references one of the configured hosts in the config.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant