use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class ArqUnsecuredManagementInterfaceTest method createDeployment.
@Deployment(testable = false)
public static Archive createDeployment() {
JARArchive deployment = ShrinkWrap.create(JARArchive.class, "myapp.jar");
deployment.add(EmptyAsset.INSTANCE, "nothing");
return deployment;
}
use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class ManagementArquillianTest method createDeployment.
@Deployment(testable = false)
public static Archive createDeployment() {
JARArchive deployment = ShrinkWrap.create(JARArchive.class);
deployment.add(EmptyAsset.INSTANCE, "nothing");
return deployment;
}
use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class OpenApiAnnotationScanner method indexArchive.
/**
* Indexes the given archive.
* @param config
* @param indexer
* @param archive
*/
@SuppressWarnings("unchecked")
private static void indexArchive(OpenApiConfig config, Indexer indexer, Archive archive) {
Map<ArchivePath, Node> c = archive.getContent();
try {
for (Map.Entry<ArchivePath, Node> each : c.entrySet()) {
ArchivePath archivePath = each.getKey();
if (archivePath.get().endsWith(OpenApiConstants.CLASS_SUFFIX) && acceptClassForScanning(config, archivePath.get())) {
try (InputStream contentStream = each.getValue().getAsset().openStream()) {
LOG.debugv("Indexing asset: {0} from archive: {1}", archivePath.get(), archive.getName());
indexer.index(contentStream);
}
continue;
}
if (archivePath.get().endsWith(OpenApiConstants.JAR_SUFFIX) && acceptJarForScanning(config, archivePath.get())) {
try (InputStream contentStream = each.getValue().getAsset().openStream()) {
JARArchive jarArchive = ShrinkWrap.create(JARArchive.class, archivePath.get()).as(ZipImporter.class).importFrom(contentStream).as(JARArchive.class);
indexArchive(config, indexer, jarArchive);
}
continue;
}
}
} catch (IOException e) {
throw new RuntimeException(e);
}
}
use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class ArqTopologyJGroupsTest method createDeployment.
@Deployment
public static Archive createDeployment() {
JARArchive deployment = ShrinkWrap.create(JARArchive.class);
deployment.add(EmptyAsset.INSTANCE, "nothing");
deployment.addPackage(Assertions.class.getPackage());
return deployment;
}
use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class ArqTopologyOpenShiftTest method createDeployment.
@Deployment
public static Archive createDeployment() {
JARArchive deployment = ShrinkWrap.create(JARArchive.class);
deployment.add(EmptyAsset.INSTANCE, "nothing");
deployment.addPackage(Assertions.class.getPackage());
return deployment;
}
Aggregations