You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by "Claude Brisson (JIRA)" <ji...@apache.org> on 2019/03/03 13:00:00 UTC

[jira] [Assigned] (VELOCITY-851) refreshResource does not add resource to cache when using multiple resource loaders

     [ https://issues.apache.org/jira/browse/VELOCITY-851?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Claude Brisson reassigned VELOCITY-851:
---------------------------------------

    Assignee: Claude Brisson

> refreshResource does not add resource to cache when using multiple resource loaders
> -----------------------------------------------------------------------------------
>
>                 Key: VELOCITY-851
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-851
>             Project: Velocity
>          Issue Type: Bug
>          Components: Engine
>    Affects Versions: 1.7
>            Reporter: Earle Nietzel
>            Assignee: Claude Brisson
>            Priority: Major
>
> The issue is seen when you have multiple resource loaders configured and and template can be loaded by a higher priority resource loader.
> The resource is loaded by loadResource but it is never added to the globalCache (see ResourceManagerImpl.java).
> For example if (see ResourceLoader.java):
> modificationCheckInterval = 60
> isCachingOn = true 
> When a change is detected by a higher priority resource loader it is loaded correctly the next time resource.requiresChecking() is true but it is never added to the globalCache or the existing entry in the cache is not evicted this causes the next request to use the resource from the cache which contains the template from a lower priority resource loader.
> The expected result would be that the higher priority template is added to the globalCache and is used in subsequent requests.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org
For additional commands, e-mail: dev-help@velocity.apache.org