airavata-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (Jira)" <j...@apache.org>
Subject [jira] [Commented] (AIRAVATA-3273) webpack-stats.json not getting cached
Date Mon, 18 Nov 2019 21:53:00 GMT

    [ https://issues.apache.org/jira/browse/AIRAVATA-3273?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16976915#comment-16976915
] 

ASF subversion and git services commented on AIRAVATA-3273:
-----------------------------------------------------------

Commit 6e216453be11f2d659d8948997b58c51f4bf6d76 in airavata's branch refs/heads/master from
Marcus Christie
[ https://gitbox.apache.org/repos/asf?p=airavata.git;h=6e21645 ]

AIRAVATA-3273 Defer copying wsgi.py since it triggers restart


> webpack-stats.json not getting cached
> -------------------------------------
>
>                 Key: AIRAVATA-3273
>                 URL: https://issues.apache.org/jira/browse/AIRAVATA-3273
>             Project: Airavata
>          Issue Type: Bug
>          Components: Django Portal
>            Reporter: Marcus Christie
>            Assignee: Marcus Christie
>            Priority: Major
>
> By default, [django-webpack-loader caches webpack-stats.json|https://github.com/owais/django-webpack-loader#cache]
when DEBUG is false, but
> - it only does this on demand, so if there have no requests to the workspace app, it
won't have cached [the WORKSPACE webpack loader config|https://github.com/apache/airavata-django-portal/blob/master/django_airavata/settings.py#L328]
> - currently the Ansible deployment configures mod_wsgi to start two Django processes,
so even in the portal has seen a request for a Django app and cached that webpack loader config,
that would only apply to the process that handled that request and the other one may not have
it cached
> This causes a problem during deployment because the webpack-stats.json file gets updated
well before {{collectstatic}} runs to copy the JS/CSS files into the static/ folder.
> Here are some ideas on how to improve this situation:
> - only have 1 Django process. That's the default, and we can increase it on a gateway
by gateway basis if we actually see the kind of load that would warrant it.
> - somehow trigger a load of the webpack loader assets on server startup so they are cached
on startup. Maybe in AppConfig.ready()



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message