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

Resource virtual network support #20

Merged
merged 12 commits into from
May 2, 2023

Conversation

chrismarget-j
Copy link
Collaborator

@chrismarget-j chrismarget-j commented May 2, 2023

This PR introduces changes needed to support Virtual Network objects in Terraform.

!!!! Breaking Change !!!!
QEQuery is now an interface. The original object, which fulfills the interface has been renamed PathQuery.

!!!! Breaking Change !!!!
The SetContext() is method is no longer part of the former QEQuery object nor any implementations of the new `QEQuery interface.

!!!! Breaking Change !!!!
The QEQuery.Do() method now takes a context (it's no longer "set" in advance, as noted above).

There are new two implementations of the QEQuery interface: PathQuery, which is the old QEQuery object, and MatchQuery, which supports the logical AND of multiple queries using the Apstra Query Engine's match syntax.

Down the road I'd like to deprecate the Client.NewQuery() method because now QEQuery objects don't necessarily need client and blueprintId elements populated (these are handled by the parent query in the match case. This PR introduces the SetBlueprint() and SetClient() methods with that in mind (previously those elements were set in by NewQuery() with no way of reaching them.

Finally, this PR introduces some VirtualNetwork iota helper functions which follow the usual pattern.

@chrismarget-j chrismarget-j requested a review from rajagopalans May 2, 2023 15:30
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.

2 participants