Skip to content

add file change watch - #534

Open
1941198 wants to merge 3 commits into
fabiolb:masterfrom
1941198:filewatch
Open

add file change watch#534
1941198 wants to merge 3 commits into
fabiolb:masterfrom
1941198:filewatch

Conversation

@1941198

@1941198 1941198 commented Aug 16, 2018

Copy link
Copy Markdown

Dynamically monitor file changes.
registry.backend = file
registry.file.path =/down/fabio.txt
registry.file.noroutehtmlpath=/down/404.txt

/down/fabio.txt

route add web-svc /test http://192.168.1.222:8082
route add web-svc /web http://192.168.1.222:8081

@CLAassistant

CLAassistant commented Aug 16, 2018

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


zjj seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@1941198

1941198 commented Aug 16, 2018

Copy link
Copy Markdown
Author

cla Already agree.
image

Comment thread registry/file/backend.go Outdated
routes, err := ioutil.ReadFile(cfg.RoutesPath)
if err != nil {
log.Println("[ERROR] Cannot read routes from ", cfg.RoutesPath)
b := &be{cfg: cfg, Interval: 2 * time.Second}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you make the Interval configurable? See https://github.com/fabiolb/fabio/blob/master/config/load.go#L161 for an example.

Please also update the website documentation at

https://github.com/fabiolb/fabio/tree/master/docs/content/ref

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

update to commited.

Comment thread registry/file/backend.go Outdated
@1941198

1941198 commented Aug 17, 2018

Copy link
Copy Markdown
Author

already updated

@scalp42

scalp42 commented Jan 6, 2021

Copy link
Copy Markdown

@1941198 any chance you can rebase against latest changes?

@magiconair or @nathanejohnson what would it take to get this merged?

@aaronhurt

Copy link
Copy Markdown
Member

This looks fairly clean and the original change points all seem to have been made. Is there anyone using this backend that can confirm operation? Are you currently using this backend @scalp42?

@scalp42

scalp42 commented Apr 30, 2021

Copy link
Copy Markdown

@leprechau we're not using this in production, we're currently running #811 that allows turning off the consistent reads.

@evandam

evandam commented Apr 30, 2021

Copy link
Copy Markdown

I'm also looking forward to seeing this push through - @1941198 could you update the branch so it can be tested/merged? @magiconair thoughts of when this might be able to ship? Thanks folks!

@aaronhurt

Copy link
Copy Markdown
Member

I'm also looking forward to seeing this push through - @1941198 could you update the branch so it can be tested/merged? @magiconair thoughts of when this might be able to ship? Thanks folks!

@evandam Frank has left the Fabio project to pursue other interests. The current owners/maintainers can be found here: https://github.com/orgs/fabiolb/people

@nathanejohnson
nathanejohnson force-pushed the master branch 2 times, most recently from a55de9d to 04f958c Compare April 11, 2022 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants