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

Amp cluster management #519

Merged
merged 1 commit into from
Dec 19, 2016
Merged

Amp cluster management #519

merged 1 commit into from
Dec 19, 2016

Conversation

freignat91
Copy link
Contributor

@freignat91 freignat91 commented Dec 2, 2016

Related to #512

For the ones granted, here is a video to explain more in details the PR features
https://drive.google.com/a/axway.com/file/d/0B3HdJx5HHXGcUzR1ZVRSMGVURVk/view?usp=sharing

see also the discussion on the topic "Short demo on amp cluster features" on Mobilize

to test locally:
make install
./shrink.sh local
ampadm pf pull --local -v
ampadm pf start --local -v

ampadm pf monitor (on another console)
ampadm node ls
ampadm node count
ampadm pf stop

to test on Amazon amp cluster after having used the Nicolas's amp-bootstrap installation:
On the manager execute:
ampadm cluster start --tag cluster
(it use a predefined amp:cluster image for PR need, but after merge and image appelerator/amp:latest built and pulled no need of the option "--tag cluster")
That's all on manager.

on your laptop client machine execute:
ampadm --server [managerAddress]:31315 node ls (to see the nodes status)
ampadm --server [managerAddress]:31315 node purge --container --image (if needed)
ampadm --server [managerAddress]:31315 pf pull -v (all amp images are pulled on all nodes)
ampadm --server [managerAddress]:31315 pf start -v
ampadm --server [managerAddress]:31315 pf monitor (on another console)

[managerAdresse] can be an aws load-balancer address

For now the previous amp pf commands stay available, waiting for decision about amp/amp-cluster cli integration or not.

-ampadm --server [managerAddress]:31315 pf pull -v

Copy link
Contributor

@generalhenry generalhenry left a comment

Choose a reason for hiding this comment

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

Docker: 1.13.0-rc2

freshly restored to factory defaults

docker swarm init
make install
./shrink.sh local
amp-cluster pf start --local -v

Result:

Service cluster-agent starting
Service cluster-server starting
Cluster services started
Connection to cluster server error: grpc: timed out when dialing

Reason:

my ~/.amp.yaml contains a normal serverAddress entry

The server address configuration needs to be independently set

//Execute commad
cmd, _, err := RootCmd.Find(os.Args[1:])
if err != nil {
g.printfc(colError, "Arg error: %v\n", err)
Copy link
Contributor

Choose a reason for hiding this comment

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

The pattern of g.printfc(colError, errorDescription, err); os.exit(1) is common enough make a g.fatalc(errorDescription, err) method

Copy link
Contributor Author

@freignat91 freignat91 Dec 5, 2016

Choose a reason for hiding this comment

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

yes, why not. I prefer explicit Exit command, than hidden one, but to be aligned with Go style, it's ok.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

follow = true
}
if follow {
fmt.Println("\033[2J\033[0;0H")
Copy link
Contributor

Choose a reason for hiding this comment

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

These printlns are both arcane and used a number of places maybe a g.followStart(follow bool) and g.followLn(follow bool)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

import "google/api/annotations.proto";

service ClusterServerService {
rpc GetClientStream (stream ClientMes) returns (stream ClientMes) {}
Copy link
Contributor

Choose a reason for hiding this comment

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

grpc-gw annotations would be nice

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes sure, but first get agreement on the cli verbs/structure and inclusion or not in amp cli.

@freignat91
Copy link
Contributor Author

freignat91 commented Dec 5, 2016

About server address configuration, i was waiting the decisions to merge or not the cluster-cli into amp-cli or cluster-server into amplifier to finalize the configuration (see the discussion topic "Short demo on amp cluster features" on Mobilize), but in the meantime i can make it separated yes.
Done: added ClusterServerAddress item in configuration

@freignat91 freignat91 force-pushed the infra-swarm-client-server branch 10 times, most recently from 7194405 to f1c929f Compare December 6, 2016 16:40
@freignat91 freignat91 force-pushed the infra-swarm-client-server branch from 1d0f21d to 587dd56 Compare December 8, 2016 15:05
@ndegory ndegory force-pushed the infra-swarm-client-server branch from 587dd56 to 715185a Compare December 8, 2016 17:44
@freignat91 freignat91 force-pushed the infra-swarm-client-server branch 2 times, most recently from a878678 to 9949323 Compare December 9, 2016 13:16
@ndegory ndegory added this to the 0.4.0 milestone Dec 9, 2016
@bquenin bquenin force-pushed the infra-swarm-client-server branch from 9949323 to 4954fc8 Compare December 9, 2016 19:24
@freignat91 freignat91 force-pushed the infra-swarm-client-server branch 3 times, most recently from b91b920 to bebdb41 Compare December 19, 2016 10:29
* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)
@freignat91 freignat91 force-pushed the infra-swarm-client-server branch from 9e3fcad to 0b6c1bd Compare December 19, 2016 10:34
@subfuzion subfuzion changed the base branch from master to v0.5.0-rc1 December 19, 2016 16:03
@subfuzion
Copy link
Contributor

@freignat91 @ndegory It's taken a while for me to review, but excellent work. Thank you for this contribution. 👍

I'm merging this into v0.5.0-rc1 for now for additional evaluation.

@subfuzion subfuzion merged commit 611458d into v0.5.0-rc1 Dec 19, 2016
@ndegory ndegory modified the milestones: 0.5.0, 0.4.0 Dec 19, 2016
subfuzion pushed a commit that referenced this pull request Dec 19, 2016
* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)
subfuzion added a commit that referenced this pull request Dec 30, 2016
* commit server,agents,clients, AMP Bootstrap and fixes reports (#519)

* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)

* serverless prototype (#539)

* Amp cleanup (#603)

* Fix for issues #547,#561,#565

* minor cleanup

* commit server,agents,clients, AMP Bootstrap and fixes reports (#519)

* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)

* serverless prototype (#539)

* Amp version more useful info
@bquenin bquenin deleted the infra-swarm-client-server branch January 3, 2017 15:34
generalhenry pushed a commit that referenced this pull request Jan 6, 2017
* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)
generalhenry pushed a commit that referenced this pull request Jan 6, 2017
* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)
generalhenry added a commit that referenced this pull request Jan 11, 2017
* commit server,agents,clients, AMP Bootstrap and fixes reports (#519)

* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)

* serverless prototype (#539)

* commit server,agents,clients, AMP Bootstrap and fixes reports (#519)

* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)

* Revert "Amp version command - more useful info" (#611)

* Add functions to the ui (#605)

* KV ui (#606)

* Add functions to the ui

* add kv to ui

* bump version to 0.6.0-dev

* Added amp help command (#652)

* Included Long message in help command output

* remerge version
bquenin pushed a commit that referenced this pull request Jan 12, 2017
* commit server,agents,clients, AMP Bootstrap and fixes reports (#519)

* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)

* serverless prototype (#539)

* commit server,agents,clients, AMP Bootstrap and fixes reports (#519)

* add bootstrap feature to AMP cluster CLI (#306)

* update vendors (huge diff)

* Revert "Amp version command - more useful info" (#611)

* Add functions to the ui (#605)

* KV ui (#606)

* Add functions to the ui

* add kv to ui

* bump version to 0.6.0-dev

* Added amp help command (#652)

* Included Long message in help command output

* remerge version
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.

5 participants