Skip to content
This repository has been archived by the owner on Jul 25, 2020. It is now read-only.

JCLOUDS-1122: Support subnetworks definitions in Google Compute. #1006

Closed
wants to merge 1 commit into from

Conversation

nelsonjr
Copy link
Contributor

@nelsonjr nelsonjr commented Sep 7, 2016

No description provided.

Iterator<String> subnetworks = options.getSubnetworks().iterator();

URI subnetwork = subnetworks.hasNext() ? URI.create(subnetworks.next()) : null;
assert !subnetworks.hasNext() : "Error: Options should specify only one subnetwork";
Copy link
Member

Choose a reason for hiding this comment

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

Since this is an option specific to google (unlike "networks" that is in the jclouds portable interface), make it just an URI instead of a collection, to avoid unnecessary configuration issues.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I made a collection like networks because like networks it can be specified more than once.

I added the blocker to match networks behavior though, but I'll create a separate PR to remove both and bring multiple interfaces (direct or subnetworked) to the module.

@nacx
Copy link
Member

nacx commented Sep 8, 2016

Thanks @nelsonjr! This looks great. Just a couple comments apart from the inline ones:

  • Add mock tests for the methods added to the aggregated list api.
  • Add live tests for the subnetworks api and the new methods in the aggregated list api. These ones are specially important, since they warn us when things change in the provider.

@nelsonjr
Copy link
Contributor Author

@nacx: How do I configure my local machine to run the live tests? I found some documentation that alludes to adding to the m2 settings, but I do not know what that means :-) That's why I did not write the live tests (yet). I was going to do another PR with that, but if you can help me with setting that up, so I can test it, I shall do it right away.

@nacx
Copy link
Member

nacx commented Sep 23, 2016

How do I configure my local machine to run the live tests

The better options is to download your credentials as a JSON file. Once you have them, you can run all live tests as follows:

mvn clean install -Plive -Dtest.google-cloud.json-key=/path/to/your/credentials.json

Or if you want to run just one single test class:

mvn integration-test -Plive -Dtest.google-cloud.json-key=/path/to/your/credentials.json -Dtest=TheClassTestToRun

@nacx
Copy link
Member

nacx commented Sep 23, 2016

They take some time, so I'd recommend that you just run the class where you add the new tests :)

@nelsonjr
Copy link
Contributor Author

@nacx: argh!! the notifications for your reply got lost in my inbox and I did not see them. sorry for the delay! i'll get to it asap.

@utkarsh-devops
Copy link

utkarsh-devops commented May 16, 2017

We are excited to use this feature. Awaiting for its release 👍

@nacx
Copy link
Member

nacx commented May 17, 2017

@utkarsh-devops This PR has been quiet for some time. Feel free to step in and help with the remaining bits!

@nacx
Copy link
Member

nacx commented May 25, 2017

Superseded by #1106.

@nacx nacx closed this May 25, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
3 participants