Sahina Bose has posted comments on this change.
Change subject: restapi: Adding details to step as statistics
......................................................................
Patch Set 14:
(7 comments)
....................................................
File
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/AbstractStatisticalQuery.java
Line 13: import org.ovirt.engine.api.model.Value;
Line 14: import org.ovirt.engine.api.model.ValueType;
Line 15: import org.ovirt.engine.api.model.Values;
Line 16: import
org.ovirt.engine.api.restapi.resource.BaseBackendResource.BackendFailureException;
Line 17: import org.ovirt.engine.core.compat.Guid;
Happened due to the eclipse setting which formats and removes imports.
Line 18:
Line 19: /**
Line 20: * Subclasses encapsulate the subject-specific aspects of a
statistical query
Line 21: */
....................................................
File
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendStepResource.java
Line 67:
Line 68: @Override
Line 69: public StatisticsResource getStatisticsResource() {
Line 70:
Line 71: GlusterTaskStatisticalQuery query = new
GlusterTaskStatisticalQuery(new TaskQueryResolver<Guid>(), newModel(id));
Step step = get()
has the same issue with Resteasy interceptor
Line 72: return inject(new BackendStatisticsResource<Step,
GlusterVolumeTaskStatusEntity>(GlusterVolumeTaskStatusEntity.class, guid,
query));
Line 73: }
Line 74:
Line 75: public class TaskQueryResolver<T> implements IResolver<Guid,
GlusterVolumeTaskStatusEntity> {
....................................................
File
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/gluster/BackendGlusterVolumeResource.java
Line 126:
Line 127: public String getId() {
Line 128: return this.id;
Line 129: }
Line 130:
Done
....................................................
File
backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/BackendStepResourceTest.java
Line 13: import org.ovirt.engine.core.common.queries.IdQueryParameters;
Line 14: import org.ovirt.engine.core.common.queries.VdcQueryType;
Line 15:
Line 16: public class BackendStepResourceTest
Line 17: extends AbstractBackendSubResourceTest<Step,
org.ovirt.engine.core.common.job.Step, BackendStepResource> {
Done
Line 18:
Line 19:
Line 20: public BackendStepResourceTest() {
Line 21: super(new BackendStepResource(GUIDS[0].toString(), new
BackendStepsResource(GUIDS[1])));
Line 45: @Test
Line 46: public void testEnd() throws Exception {
Line 47:
setUriInfo(setUpActionExpectations(VdcActionType.EndExternalStep,
Line 48: EndExternalStepParameters.class,
Line 49: new String[] { "Id", "Status"},
Done
Line 50: new Object[] { GUIDS[0], true}, true, true));
Line 51: Action action = new Action();
Line 52: action.setSucceeded(true);
Line 53: verifyActionResponse(resource.end(action));
Line 65: setUpGetEntityExpectations(VdcQueryType.GetStepByStepId,
Line 66: IdQueryParameters.class,
Line 67: new String[] { "Id" },
Line 68: new Object[] { GUIDS[0] },
Line 69: notFound ? null : entity);
This is remnants from test case, where I was testing step returning details
when All-Content is true. Will remove.
Line 70: }
Line 71:
Line 72: @Override
Line 73: protected org.ovirt.engine.core.common.job.Step getEntity(int
index) {
....................................................
File
backend/manager/modules/restapi/types/src/main/java/org/ovirt/engine/api/restapi/types/StepMapper.java
Line 36: }
Line 37: model.setExternal(entity.isExternal());
Line 38: if (entity.getExternalSystem() != null &&
entity.getExternalSystem().getType() != null) {
Line 39:
model.setExternalType(entity.getExternalSystem().getType().name());
Line 40: }
Done
Line 41:
Line 42: return model;
Line 43: }
Line 44:
--
To view, visit http://gerrit.ovirt.org/19685
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Ia1f7559d5700823cd4ee0a28a826074d22679d23
Gerrit-PatchSet: 14
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Sahina Bose <[email protected]>
Gerrit-Reviewer: Eli Mesika <[email protected]>
Gerrit-Reviewer: Michael Pasternak <[email protected]>
Gerrit-Reviewer: Ori Liel <[email protected]>
Gerrit-Reviewer: Sahina Bose <[email protected]>
Gerrit-Reviewer: Shubhendu Tripathi <[email protected]>
Gerrit-Reviewer: Yair Zaslavsky <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches