Pearl1594 commented on code in PR #13543:
URL: https://github.com/apache/cloudstack/pull/13543#discussion_r3553064963
##########
api/src/main/java/org/apache/cloudstack/api/command/admin/vpc/CreateVPCOfferingCmd.java:
##########
@@ -92,10 +92,15 @@ public class CreateVPCOfferingCmd extends
BaseAsyncCreateCmd {
@Parameter(name = ApiConstants.SERVICE_CAPABILITY_LIST, type =
CommandType.MAP, description = "Desired service capabilities as part of VPC
offering", since = "4.4")
private Map<String, List<String>> serviceCapabilityList;
- @Parameter(name = ApiConstants.INTERNET_PROTOCOL,
- type = CommandType.STRING,
- description = "The internet protocol of the offering. Options are
IPv4 and dualstack. Default is IPv4. dualstack will create an offering that
supports both IPv4 and IPv6",
- since = "4.17.0")
+ @Parameter(
+ name = ApiConstants.INTERNET_PROTOCOL,
+ type = CommandType.STRING,
+ description = "The internet protocol of the offering. Options are IPv4
and dualstack. Default is IPv4. dualstack will create an offering that supports
both IPv4 and IPv6",
+ since = "4.17.0",
+ allowedValues = {
+ "IPv4",
+ "dualstack"
+ })
Review Comment:
I wonder if it's possible to point to existing enums - so that, in future if
the list changes i.e, the enum, this will always stay in sync. With the
hard-coded approach there's a risk of these values going state. It's a good
first approach, but worth checking the feasibility of pointing to existing enums
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]