Skip to content

Commit

Permalink
Merge pull request #22179 from jmartisk/main-issue-22158
Browse files Browse the repository at this point in the history
Don't attempt to index empty transformed classes
jmartisk authored Dec 14, 2021
2 parents bdeff8b + 358305c commit 5430201
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -199,10 +199,12 @@ void buildExecutionService(
Map<String, byte[]> modifiedClases = graphQLIndexBuildItem.getModifiedClases();

for (Map.Entry<String, byte[]> kv : modifiedClases.entrySet()) {
try (ByteArrayInputStream bais = new ByteArrayInputStream(kv.getValue())) {
indexer.index(bais);
} catch (IOException ex) {
LOG.warn("Could not index [" + kv.getKey() + "] - " + ex.getMessage());
if (kv.getKey() != null && kv.getValue() != null) {
try (ByteArrayInputStream bais = new ByteArrayInputStream(kv.getValue())) {
indexer.index(bais);
} catch (IOException ex) {
LOG.warn("Could not index [" + kv.getKey() + "] - " + ex.getMessage());
}
}
}

0 comments on commit 5430201

Please sign in to comment.