-
Notifications
You must be signed in to change notification settings - Fork 277
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
Add nodes dynamically to an AppScale deployment #163
Conversation
…ks in their place
…test cases, and fixed tests accordingly
…exec, and fixed unit tests for adding nodes dynamically
…wing NotImplementedError on add_nodes for cloud deployments for now
…tested in ec2 with appserver
@@ -966,6 +966,103 @@ def remove_role(old_role, secret) | |||
end | |||
|
|||
|
|||
def start_roles_on_nodes(ips_hash, secret) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please document all new functions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would suggest putting this additional code in a new class since djinn.rb is already really large.
The code currently does not work to correctly add new appengine nodes due to rabbitmq not coming up properly. |
…ey are the same location and the latter is more readable
@@ -653,7 +653,7 @@ def stop_app(app_name, secret) | |||
|
|||
# Contact the soap server and remove the application | |||
if (@app_names.include?(app_name) and !my_node.is_appengine?) or @nodes.length == 1 | |||
ip = HelperFunctions.read_file("#{APPSCALE_HOME}/.appscale/masters") | |||
ip = HelperFunctions.read_file("/etc/appscale/masters") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please move constant strings to global constants.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And also for the other string constants below where you see fit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
…nued in case of failures
…to it accordingly
…we can later get the location dynamically
…s location from a file written by the AppController, and extracted code to write /etc/hosts to a function so that we can invoke it when we add nodes
…ile written by the AppController, instead of assuming it runs locally
As noted in the related tools diff (AppScale/appscale-tools#52), this refactoring enables 'appengine' to be the only role running by not hardcoding in the location of the RabbitMQ server as localhost or the AppLoadBalancer's location as localhost. Also updated the AppController to update /etc/hosts when nodes are added (else old nodes won't get an updated /etc/hosts). |
…les when accessed via an external thread
Conflicts: AppController/djinn.rb AppController/lib/helperfunctions.rb
… for nginx accordingly
Everything demo'ed fine with the exception of this issue: #245 |
Add nodes dynamically to an AppScale deployment
Receives requests from the appscale-tools and dynamically adds nodes to an already running AppScale deployment. Relies on appscale-add-instances (AppScale/appscale-tools#52).
To test, try following the documentation (https://github.com/AppScale/appscale/wiki/Adding-Machines-to-an-AppScale-Deployment) and verifying that it works. That document adds two nodes to an existing four node deployment in VirtualBox.