Package eu.stratosphere.nephele.execution.librarycache

Examples of eu.stratosphere.nephele.execution.librarycache.LibraryCacheProfileResponse



  @Override
  public LibraryCacheProfileResponse getLibraryCacheProfile(LibraryCacheProfileRequest request) throws IOException {

    LibraryCacheProfileResponse response = new LibraryCacheProfileResponse(request);
    String[] requiredLibraries = request.getRequiredLibraries();

    for (int i = 0; i < requiredLibraries.length; i++) {
      if (LibraryCacheManager.contains(requiredLibraries[i]) == null) {
        response.setCached(i, false);
      } else {
        response.setCached(i, true);
      }
    }

    return response;
  }
View Full Code Here


    LibraryCacheProfileRequest request = new LibraryCacheProfileRequest();
    request.setRequiredLibraries(requiredLibraries);

    // Send the request
    LibraryCacheProfileResponse response = null;
    response = getTaskManagerProxy().getLibraryCacheProfile(request);

    // Check response and transfer libraries if necessary
    for (int k = 0; k < requiredLibraries.length; k++) {
      if (!response.isCached(k)) {
        LibraryCacheUpdate update = new LibraryCacheUpdate(requiredLibraries[k]);
        getTaskManagerProxy().updateLibraryCache(update);
      }
    }
  }
View Full Code Here

TOP

Related Classes of eu.stratosphere.nephele.execution.librarycache.LibraryCacheProfileResponse

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.