Skip to content

auto rebuild/restart server#48

Open
sihoang wants to merge 2 commits intomasterfrom
hn/bra
Open

auto rebuild/restart server#48
sihoang wants to merge 2 commits intomasterfrom
hn/bra

Conversation

@sihoang
Copy link
Member

@sihoang sihoang commented Dec 21, 2018

This is optional for those don't want manually restart server while
writing code. I haven't used it myself and would like to hear your
opnions.

I had a small script using fswatch https://github.com/WeTrustPlatform/charity-management-serv/blob/master/live_reload.sh
It works well on Mac but doesn't on my void-linux machine

@kivutar
Copy link
Contributor

kivutar commented Dec 22, 2018

I think it's nice to have. Does it work well? Can you also watch the html files in templates/ before I merge this?
Will it kill my goroutines?
I'm asking this because I often edit/save my go files while the app is busy creating or destroying nodes. If it kills the goroutines, it will let the cloud host and db in an inconsistent state.

@sihoang
Copy link
Member Author

sihoang commented Jan 2, 2019

I think the goroutines must be handled anyway in another PR. Otherwise, we won't be able to deploy newer version while app is busy.

@sihoang
Copy link
Member Author

sihoang commented Jan 2, 2019

I'll add the html's template later, don't merge yet

@kivutar
Copy link
Contributor

kivutar commented Jan 3, 2019

You're right. We have a branch for graceful shutdown now. But as the routines sometimes take 3 minutes to complete (during a VM creation) even graceful shutdown is not enough. I'm thinking about breaking VM creation in more robust and shorter steps.

@sihoang
Copy link
Member Author

sihoang commented Jan 3, 2019

agreed. The VM provision is tough. It's a tricky problem because we might end up with something like terraform which ensures the VM will be in the state you specify it to be. Let me know if you have any ideas to simplify it.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants