/** {@inheritDoc} */
  public Tree<InstallArtifact> createInstallTree(
      ArtifactSpecification specification, String scopeName) throws DeploymentException {
    String type = specification.getType();
    String name = specification.getName();
    VersionRange versionRange = specification.getVersionRange();
    RepositoryAwareArtifactDescriptor artifactDescriptor =
        this.repository.get(type, name, versionRange);
    if (artifactDescriptor == null) {
      this.eventLogger.log(
          DeployerLogEvents.ARTIFACT_NOT_FOUND,
          type,
          name,
          versionRange,
          this.repository.getName());
      throw new DeploymentException(
          type + " '" + name + "' version '" + versionRange + "' not found");
    }

    URI artifactURI = artifactDescriptor.getUri();

    ArtifactIdentity identity =
        new ArtifactIdentity(type, name, artifactDescriptor.getVersion(), scopeName);
    identity = ArtifactIdentityScoper.scopeArtifactIdentity(identity);

    ArtifactStorage artifactStorage =
        this.artifactStorageFactory.create(new File(artifactURI), identity);

    Tree<InstallArtifact> installArtifactTree =
        constructInstallArtifactTree(
            identity,
            specification.getProperties(),
            artifactStorage,
            artifactDescriptor.getRepositoryName());
    return installArtifactTree;
  }