Skip to content

Commit

Permalink
Fixes #1292
Browse files Browse the repository at this point in the history
  • Loading branch information
jfarcand committed Sep 17, 2013
1 parent e889466 commit 2f79a15
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
8 changes: 8 additions & 0 deletions modules/cpr/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,14 @@
<version>${jbossaswebsockets-version}</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>org.jboss</groupId>
<artifactId>jboss-vfs</artifactId>
<version>3.1.0.Final</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>org.atmosphere</groupId>
<artifactId>atmosphere-compat-jbossweb</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ private void scanForAnnotation(AtmosphereFramework f) {
// JBoss|vfs with APR issue, or any strange containers may fail. This is a hack for them.
// https://github.com/Atmosphere/atmosphere/issues/1292
if (!coreAnnotationsFound.get()) {
logger.warn("Unable to detect annotations. Application may to deploy.");
for (Class a : coreAnnotations) {
try {
handler.handleProcessor(loadClass(getClass(), a.getName()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
import java.util.Enumeration;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;

Expand Down Expand Up @@ -294,9 +295,14 @@ public final void detect(final String... packageNames) throws IOException {
if (idx > -1) {
jarPath = jarPath.substring(0, idx + 4);
final File jarFile = new File(jarPath);
if (jarFile.isFile()) {
if (jarFile.isFile() && jarFile.exists()) {
files.add(jarFile);
if (DEBUG) print("Add jar file from VFS: '%s'", jarFile);
} else {
List<org.jboss.vfs.VirtualFile> vfs = org.jboss.vfs.VFS.getChild(dir.getPath()).getChildren();
for (org.jboss.vfs.VirtualFile f: vfs) {
files.add(f.getPhysicalFile());
}
}
}
}
Expand Down

0 comments on commit 2f79a15

Please sign in to comment.