[uWSGI] Flat file caching in subdirectories

Roberto De Ioris roberto at unbit.it
Tue Jul 12 10:21:20 CEST 2016


> On Tue, 12 Jul 2016 09:22:01 +0200
> "Roberto De Ioris" <roberto at unbit.it> wrote:
>
> Hi Roberto
>
>> Hi, i think some file is missing from the uwsgi-router-isfreshfile
>> repository
>
> Ah, I did not expect a reply that quickly ;)
> Ok, just pushed the code for "uwsgi-router-isfreshfile".
>
>> > - The intended modifier/parameter to set the file's age is still a bit
>> of
>> > a mystery
>>
>>
>> what about using xattr ?
>>
>> https://github.com/unbit/uwsgi-docs/blob/master/Changelog-1.9.9.rst#the-xattr-plugin
>>
>> https://github.com/unbit/uwsgi/blob/master/plugins/xattr/xattr.c
>
> Forgive my thick head at the moment ... but it seems with "xattr" I can
> access a file's attributes and use it as a variable inside the routing
> system ... but what I am searching for is a way to pass in a parameter to
>

oh, ok, check how the 'ishigher' conditional is implemented:

https://github.com/unbit/uwsgi/blob/master/core/routing.c#L1559

basically the code checks for ';' and split it in two buffers. The second
one will be your age.

-- 
Roberto De Ioris
http://unbit.com


More information about the uWSGI mailing list