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

[Ready For Review] Virtual machine scale sets #1071

Merged
merged 25 commits into from
Sep 21, 2016
Merged

[Ready For Review] Virtual machine scale sets #1071

merged 25 commits into from
Sep 21, 2016

Conversation

anuchandy
Copy link
Member

No description provided.

@azuresdkci
Copy link
Contributor

Can one of the admins verify this patch?

@azuresdkci
Copy link
Contributor

Runtime changes detected. pull request created. CI running: Build Status

@anuchandy anuchandy changed the title [In Progress] Virtual machine scale sets [Ready For Review] Virtual machine scale sets Sep 17, 2016
* virtual machine's primary network interface in the scale set.
*
*/
interface WithSubnet {

Choose a reason for hiding this comment

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

instead of selecting the network first and then the subnet name, you could just do in in one call: see Frontend's withExistingSubnet

Copy link
Member Author

Choose a reason for hiding this comment

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

sounds good, will do

* The stage of a virtual machine scale set update containing inputs for the resource to be updated
* (via {@link WithApplicable#apply()}).
*/
interface WithApplicable extends

Choose a reason for hiding this comment

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

Not sure about WithApplicable as the naming here - i think what was meant was WithApply
But i'm also wondering why this interface is needed - i just point have optional methods return Update

Copy link
Member Author

Choose a reason for hiding this comment

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

Right, i mean WithApply.

The reason for this interface is - i want to maintain a context in the initial stages of update. i.e. during update i want show withInternal|internetFacingLoadBalancer and if user choose it then give him an option to specify the backends and natpool from the load balancer.

}

@Override
public VirtualMachineScaleSetImpl disableVmAgent() {

Choose a reason for hiding this comment

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

the naming convention we generally follow for these, especially at the top level resource, is to start with 'with' to help with the disoverability. So the consistent and intuitive naming here would simply be withVmAgent()/withoutVmAgent()

}

@Override
public VirtualMachineScaleSetImpl disableAutoUpdate() {

Choose a reason for hiding this comment

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

along similar lines to the previous comment, couldn't this be simply withAutoUpdate()/withoutAutoUpdate()?

Copy link
Member Author

Choose a reason for hiding this comment

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

will fix them.

// Actions
//
/**
* @return available skus for the virtual machine scale set including the minimum and maximum vm instances

Choose a reason for hiding this comment

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

Javadoc convention: no period at the end of the @return and other such parts. Only the description uses proper casing and periods, because those are intended to be full sentences.

Copy link
Member Author

Choose a reason for hiding this comment

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

will fix all, thanks

@anuchandy
Copy link
Member Author

@martinsawicki please take a look, addressed your comments, thanks!

@hovsepm
Copy link
Contributor

hovsepm commented Sep 21, 2016

@azuresdkci retest this please

*
* @throws IOException the IO exception
*/
Map<String, Backend> primaryInternetFacingLoadBalancerBackEnds() throws IOException;

Choose a reason for hiding this comment

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

it's Backend not BackEnds

*
* @throws IOException the IO exception
*/
Map<String, Backend> primaryInternetFacingLoadBalancerBackEnds() throws IOException;

Choose a reason for hiding this comment

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

it's Backends not BackEnds

*
* @throws IOException the IO exception
*/
Map<String, Backend> primaryInternalLoadBalancerBackEnds() throws IOException;

Choose a reason for hiding this comment

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

Backends not BackEnds

}

/**
* The stage of the virtual machine scale set definition allowing to specify Sku for the virtual machines.

Choose a reason for hiding this comment

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

"specify Sku" --> "specify the SKU" (it's an acronym)

*/
interface WithSku {
/**
* Specifies sku for the virtual machines in the scale set.

Choose a reason for hiding this comment

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

"Specifies the SKU ..."

WithNetworkSubnet withSku(VirtualMachineScaleSetSkuTypes skuType);

/**
* Specifies sku for the virtual machines in the scale set.

Choose a reason for hiding this comment

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

"Specifies the SKU..."


/**
* The stage of the virtual machine scale set definition allowing to specify a public load balancer for
* the primary network interface of the scale set virtual machines.

Choose a reason for hiding this comment

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

may be cleaner to say "[...] for the primary network interfaces of the virtual machines in the scale set."

*/
interface WithPrimaryInternetFacingLoadBalancer {
/**
* Specify the public load balancer where it's backends and/or NAT pools can be assigned to the primary network

Choose a reason for hiding this comment

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

maybe better: "Specify the Internet-facing load balancer whose backends and/or NAT pools can be assigned to the primary network interfaces of the virtual machines in the scale set."

* in the scale set.
* <p>
* A primary internal load balancer associated with the primary network interfaces of the scale set
* virtual machine will be also belongs to this network

Choose a reason for hiding this comment

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

typo: "belong" not "belongs"

Network primaryNetwork() throws IOException;

/**
* @return the internet facing load balancer associated with the primary network interface of

Choose a reason for hiding this comment

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

should be "Internet-facing"

LoadBalancer primaryInternetFacingLoadBalancer() throws IOException;

/**
* @return the internet facing load balancer's backends associated with the primary network interface

Choose a reason for hiding this comment

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

"Internet-facing"

Map<String, Backend> primaryInternetFacingLoadBalancerBackEnds() throws IOException;

/**
* @return the internet facing load balancer's inbound NAT pool associated with the primary network interface

Choose a reason for hiding this comment

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

"Internet-facing".
I won't comment on these anymore -- it'd be good to just search/replace "internet facing" with "Internet-facing"

Map<String, InboundNatPool> primaryInternalLoadBalancerInboundNatPools() throws IOException;

/**
* @return the list of ids of public Ip addresses associated with the primary internet facing load balancer

Choose a reason for hiding this comment

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

"the list of IDs of the public IP addresses [...]"

List<String> primaryPublicIpAddressIds() throws IOException;

/**
* @return the url to storage containers that stores vhds of virtual machines in the scale set

Choose a reason for hiding this comment

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

"URL" and "store"

VirtualMachineScaleSetNetworkProfile networkProfile();

/**
* @return the extensions attached to the Virtual Machines in the scale set

Choose a reason for hiding this comment

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

"virtual machines" (capitalization)

/**
* Specifies sku for the virtual machines in the scale set.
*
* @param sku a sku from the list of available sizes for the virtual machines in this scale set

Choose a reason for hiding this comment

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

" a SKU". Let's just search/replace all "sku" with "SKU" in javadocs (not code)

}

/**
* The stage of the virtual machine scale set definition allowing to specify virtual network subnet for the

Choose a reason for hiding this comment

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

"the virtual network subnet"

* Specify the public load balancer where it's backends and/or NAT pools can be assigned to the primary network
* interface of the scale set virtual machines.
* <p>
* By default all the backend and inbound NAT pool of the load balancer will be associated with the primary

Choose a reason for hiding this comment

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

"backends and inbound NAT pools"

WithPrimaryInternetFacingLoadBalancerBackendOrNatPool withPrimaryInternetFacingLoadBalancer(LoadBalancer loadBalancer);

/**
* Specifies that no public load balancer needs to be associated with virtual machine scale set.

Choose a reason for hiding this comment

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

"[...] with the virtual machine scale set."


/**
* The stage of the virtual machine scale set definition allowing to specify an internal load balancer for
* the primary network interface of the scale set virtual machines.

Choose a reason for hiding this comment

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

maybe cleaner: "[...] of the virtual machines in the scale set."

*/
interface WithPrimaryInternalLoadBalancer {
/**
* Specify the internal load balancer where it's backends and/or NAT pools can be assigned to the primary network

Choose a reason for hiding this comment

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

"its" not "it's"

Copy link

@martinsawicki martinsawicki left a comment

Choose a reason for hiding this comment

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

overall, i just focused more on the Javadoc content, but it looks like it will be more efficient to just do a big Javadoc scrub across the entire SDK's API surface, as there are a number of stylistic conventions that are appropriate, so my Javadoc input is not the highest pri.

@martinsawicki martinsawicki merged commit 0b98bc5 into Azure:master Sep 21, 2016
@anuchandy anuchandy deleted the vmss-fluent2 branch February 8, 2017 23:46
jianghaolu pushed a commit to jianghaolu/azure-sdk-for-java that referenced this pull request Feb 27, 2017
merging since code review has been addressed. there are just some naming corrections (Backend not BackEnd) which we can followup up with aftet the merge, but the javadoc scrub will need to happen as a more focused effort.
jianghaolu pushed a commit to jianghaolu/azure-sdk-for-java that referenced this pull request Feb 27, 2017
merging since code review has been addressed. there are just some naming corrections (Backend not BackEnd) which we can followup up with aftet the merge, but the javadoc scrub will need to happen as a more focused effort.
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.

5 participants