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

make console depend on all graphds #128

Closed
wants to merge 1 commit into from

Conversation

wey-gu
Copy link
Contributor

@wey-gu wey-gu commented Aug 26, 2022

close: #126

credit goes to @imrefazekas

@wey-gu
Copy link
Contributor Author

wey-gu commented Aug 26, 2022

As observed by @imrefazekas it took some time for the cluster to be ready to receive the console call, this change helped fix it.

@HarrisChu
Copy link
Contributor

why this? console just connect to FIRST graph, no need to wait other graphds.
prefer a loop like: https://github.com/vesoft-inc/nebula-python/blob/master/tests/docker-compose.yaml

@HarrisChu
Copy link
Contributor

        for i in `seq 1 60`;do
          var=`nebula-console -addr graphd0 -port 9669 -u root -p nebula -e 'ADD HOSTS "172.28.2.1":9779,"172.28.2.2":9779,"172.28.2.3":9779;'`;
          if [[ $$? == 0 ]];then
            break;
          fi;
          sleep 1;
          echo "retry to add hosts.";
        done && tail -f /dev/null;

@wey-gu
Copy link
Contributor Author

wey-gu commented Oct 20, 2022

        for i in `seq 1 60`;do
          var=`nebula-console -addr graphd0 -port 9669 -u root -p nebula -e 'ADD HOSTS "172.28.2.1":9779,"172.28.2.2":9779,"172.28.2.3":9779;'`;
          if [[ $$? == 0 ]];then
            break;
          fi;
          sleep 1;
          echo "retry to add hosts.";
        done && tail -f /dev/null;

This is better, I'll close this, could you port your implementation here?

@wey-gu wey-gu closed this Oct 20, 2022
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.

Console exists right away - conn issue
2 participants