RepositorySystemSession session = newRepositorySystemSession();
RemoteRepository central = newCentralRepository();
//TODO add more remote repositories - especially the JBoss one
ArtifactRequest artifactRequest = new ArtifactRequest();
artifactRequest.setArtifact(artifact);
artifactRequest.addRepository(central);
ArtifactResult artifactResult;
try {
artifactResult = REPOSITORY_SYSTEM.resolveArtifact(session, artifactRequest);
} catch(ArtifactResolutionException e) {