Search in sources :

Example 1 with AppAttempt

use of com.microsoft.azure.hdinsight.sdk.rest.yarn.rm.AppAttempt in project azure-tools-for-java by Microsoft.

the class SparkBatchRemoteDebugJobScenario method checkGetCurrentYarnAppAttemptResult.

@Then("^getting current Yarn App attempt should be '(.+)'$")
public void checkGetCurrentYarnAppAttemptResult(String appAttemptIdExpect) {
    URI mockConnUri = URI.create(httpServerMock.completeUrl("/"));
    when(debugJobMock.getConnectUri()).thenReturn(mockConnUri);
    doReturn(mockConnUri.resolve("/yarnui/ws/v1/cluster/apps/")).when(debugJobMock).getYarnNMConnectUri();
    AppAttempt appAttempt = debugJobMock.getSparkJobYarnCurrentAppAttempt().toBlocking().first();
    assertEquals(appAttemptIdExpect, appAttempt.getAppAttemptId());
}
Also used : URI(java.net.URI) AppAttempt(com.microsoft.azure.hdinsight.sdk.rest.yarn.rm.AppAttempt) Then(cucumber.api.java.en.Then)

Aggregations

AppAttempt (com.microsoft.azure.hdinsight.sdk.rest.yarn.rm.AppAttempt)1 Then (cucumber.api.java.en.Then)1 URI (java.net.URI)1