Michael Pasternak has posted comments on this change.

Change subject: engine: throw http 400 if validation fails
......................................................................


Patch Set 2: I would prefer that you didn't submit this

(2 inline comments)

....................................................
File backend/manager/modules/restapi/types/pom.xml
Line 61: 
Line 62:    <dependency>
Line 63:      <groupId>org.jboss.resteasy</groupId>
Line 64:      <artifactId>resteasy-jaxrs</artifactId>
Line 65:      <version>2.3.2.Final</version>
this will create circular dependency
Line 66:    </dependency>
Line 67:   </dependencies>


....................................................
File 
backend/manager/modules/restapi/types/src/main/java/org/ovirt/engine/api/restapi/types/VmMapper.java
Line 966: 
Line 967:     static VCpuPin stringToVCpupin(final String strCpu) {
Line 968:         final String[] strPin = strCpu.split("#");
Line 969:         if (strPin.length != 2) {
Line 970:             throw new BadRequestException("Bad format: " + strCpu);
instead of throwing BadRequestException (REQUEST is not relevant in this 
context),
please continue throwing ilegalargument exception, but handle it in JAXRS as we 
do in asGuid() method.
Line 971:         }
Line 972:         final VCpuPin pin = new VCpuPin();
Line 973:         try {
Line 974:             pin.setVcpu(Integer.parseInt(strPin[0]));


--
To view, visit http://gerrit.ovirt.org/10838
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Id709ee3e1f4b4dffffadf316f222a9b2c751f1d8
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Laszlo Hornyak <[email protected]>
Gerrit-Reviewer: Laszlo Hornyak <[email protected]>
Gerrit-Reviewer: Michael Pasternak <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to