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

Fixes #3650, #11600 - Compute Resource availability_zones, flavors, security_groups API v2 endpoints #2657

Closed

Conversation

kairel
Copy link
Contributor

@kairel kairel commented Sep 1, 2015

ref #3650 and ref#11600

@theforeman-bot
Copy link
Member

There were the following issues with the commit message:

  • b97c0b2 must be in the format fixes #redmine_number - brief description.

If you don't have a ticket number, please create an issue in Redmine, selecting the appropriate project.

More guidelines are available on the Foreman wiki.


This message was auto-generated by Foreman's prprocessor

@@ -0,0 +1,5 @@
collection @available_availability_zones, root_object: false

node :name do |s|
Copy link
Member

Choose a reason for hiding this comment

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

Nitpick, there must exist more descriptive name than 's' 😄

@dLobatog
Copy link
Member

dLobatog commented Sep 1, 2015

[test] this triggers our Jenkins job

@@ -96,6 +96,7 @@ def teardown
assert_response :not_found
end


Copy link
Member

Choose a reason for hiding this comment

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

Remove this extra line and the other one in line 126, they'll likely cause Rubocop to fail

@dLobatog
Copy link
Member

dLobatog commented Sep 1, 2015

Hi @kairel ! Thanks for your patch, it's highly appreciated. Also thanks for the putting the work to write the tests for it, it's close to merge IMO, there are a few minor issues I've commented inline.

If you think your commit is fixing #3650 and #11600, reference it as "Fixes #3650, #11600" on your commit. We use the word 'refs' only when there are more than one commit fixing the same issue. Sorry it's a bit confusing!

I'm on the fence about the available_ prefixed to all fog methods here. I'd argue the 'available' part is something we can assume, but I understand why you added it (because it's everywhere already). If others, @isratrade, @ohadlevy, @domcleal are OK with it, I'd say let's drop the prefix for all new methods like these ones & drop it everywhere for API v3.

Thanks again, let us know on #theforeman-dev on Freenode IRC if you have any questions!

@dLobatog dLobatog changed the title ref #3650 adding list values compute resources Fixes #3650, 11600 - Compute Resource availability_zones, flavors, security_groups API v2 endpoints Sep 1, 2015
@theforeman-bot
Copy link
Member

There were the following issues with the commit message:

  • b97c0b2 must be in the format fixes #redmine_number - brief description.
  • fe22540 must be in the format fixes #redmine_number - brief description.

If you don't have a ticket number, please create an issue in Redmine, selecting the appropriate project.

More guidelines are available on the Foreman wiki.


This message was auto-generated by Foreman's prprocessor

@dLobatog
Copy link
Member

dLobatog commented Sep 1, 2015

[test]

@dLobatog
Copy link
Member

dLobatog commented Sep 2, 2015

@kairel There are a few tests failing & rubocop. Could you take a look at them and update the PR? To see what failed you can just click on Details on the PR status box.

Also we normally take changes in one commit, so if you could git rebase HEAD~2 your branch that'd help. Thanks again!

@@ -71,6 +71,18 @@ def flavors
client.flavors
end

def available_availability_zones
Copy link
Member

Choose a reason for hiding this comment

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

To avoid making these kind of wrappers, you can write at the beginning of the file, bellow the other delegate:

    delegate :security_groups, :flavors, :zones, :to => :self, :prefix => 'available'

available_availability_zones is a bit redundant plus we call them zones on Foreman to be more generic

@theforeman-bot
Copy link
Member

There were the following issues with the commit message:

  • 38e5e8c must be in the format fixes #redmine_number - brief description.

If you don't have a ticket number, please create an issue in Redmine, selecting the appropriate project.

More guidelines are available on the Foreman wiki.


This message was auto-generated by Foreman's prprocessor

@dLobatog
Copy link
Member

dLobatog commented Sep 3, 2015

[test] - this allows our Jenkins CI to pick up this PR and test it

@theforeman-bot
Copy link
Member

There were the following issues with the commit message:

  • e31b90f must be in the format fixes #redmine_number - brief description.

If you don't have a ticket number, please create an issue in Redmine, selecting the appropriate project.

More guidelines are available on the Foreman wiki.


This message was auto-generated by Foreman's prprocessor

@kairel
Copy link
Contributor Author

kairel commented Sep 4, 2015

i must be something for test ?

@domcleal
Copy link
Contributor

domcleal commented Sep 4, 2015

Sorry! [test] will re-run it since the change.

@kairel
Copy link
Contributor Author

kairel commented Sep 7, 2015

Hi,

All checks have passed, i need to change something ?

@domcleal
Copy link
Contributor

domcleal commented Sep 7, 2015

It's waiting on a review at the moment, but all the bot is saying that the commit message isn't quite right - there's a missing "#" before the second ticket number.

@kairel kairel changed the title Fixes #3650, 11600 - Compute Resource availability_zones, flavors, security_groups API v2 endpoints Fixes #3650, #11600 - Compute Resource availability_zones, flavors, security_groups API v2 endpoints Sep 7, 2015
@@ -199,6 +199,10 @@ def supports_update?
false
end

def available_availability_zones
Copy link
Member

Choose a reason for hiding this comment

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

I think you forgot to rename this to available_zones

@dLobatog
Copy link
Member

Nice job @kairel ! 2 very minor things and we're done:

  • The commit title lacks a second # before 11600, it should contain fixes #3650, #11600
  • See inline comment on compute_resource, there's still a method available_availability_zones

Thank you!

@theforeman-bot
Copy link
Member

There were the following issues with the commit message:

  • f5b2e2e must be in the format fixes #redmine_number - brief description.

If you don't have a ticket number, please create an issue in Redmine, selecting the appropriate project.

More guidelines are available on the Foreman wiki.


This message was auto-generated by Foreman's prprocessor

@dLobatog
Copy link
Member

[test]

@dLobatog
Copy link
Member

Merged as 45c1a85, thanks @kairel!

@dLobatog dLobatog closed this Sep 11, 2015
This pull request was closed.
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