[jboss-jira] [JBoss JIRA] (WFCORE-493) Automatically index static modules as required
Tomasz Adamski (JIRA)
issues at jboss.org
Fri Jan 16 14:32:49 EST 2015
[ https://issues.jboss.org/browse/WFCORE-493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13033276#comment-13033276 ]
Tomasz Adamski edited comment on WFCORE-493 at 1/16/15 2:32 PM:
----------------------------------------------------------------
Added a function to CompositeIndexProcessor which calculates index on the fly, when it is not attached by module creator:
{code}
private Index calculateModuleIndex(final Module module) throws ModuleLoadException, IOException {
final Indexer indexer = new Indexer();
final PathFilter filter = PathFilters.getDefaultImportFilter();
Iterator<Resource> iterator = module.iterateResources(filter);
while (iterator.hasNext()) {
Resource resource = iterator.next();
indexer.index(resource.openStream());
}
return indexer.complete();
}
{code}
TODO:
* if index was attached, but was calculated using previous jandex version it should be recalculated (waiting for jandex api update)
* disscuss wheter indexes should be cached
was (Author: tomekadamski):
Added a function to CompositeIndexProcessor which calculates index on the fly, when it is not attached by module creator:
{code}
private Index calculateModuleIndex(final Module module) throws ModuleLoadException, IOException {
final Indexer indexer = new Indexer();
final PathFilter filter = PathFilters.getDefaultImportFilter();
Iterator<Resource> iterator = module.iterateResources(filter);
while (iterator.hasNext()) {
Resource resource = iterator.next();
indexer.index(resource.openStream());
}
return indexer.complete();
}
{code}
> Automatically index static modules as required
> ----------------------------------------------
>
> Key: WFCORE-493
> URL: https://issues.jboss.org/browse/WFCORE-493
> Project: WildFly Core
> Issue Type: Feature Request
> Components: Server
> Reporter: Stuart Douglas
> Assignee: Tomasz Adamski
>
> If a static module has an annotation import it should be automatically indexed
--
This message was sent by Atlassian JIRA
(v6.3.11#6341)
More information about the jboss-jira
mailing list