Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7278945
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T22:56:51+00:00 2026-05-28T22:56:51+00:00

I have created grails application and uploaded it in heroku. If I use ‘heroku

  • 0

I have created grails application and uploaded it in heroku.
If I use ‘heroku scale web=1’ everything looks OK. But if I run ‘heroku scale web=2’, some static resources disappear.
From logs I can figure out, that all static resources from web.2 dyno are missing. But this dyno is started without any errors.

How can I resolve this problem?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T22:56:52+00:00Added an answer on May 28, 2026 at 10:56 pm

    https://github.com/grails-plugins/grails-resources/pull/11

    According to the owner of the resources plugin, Marc Palmer, they’re ignoring a check for old references to static resources.

    So, this manifests itself as a load balancing issue that you would have on any system if you’re not using sticky load balancing (which is the case with Heroku). Here’s what’s happening in the Heroku case:

    1. Request comes into someapp.com
    2. index.gsp is served from app server 1, web.1
      index.gsp contains
    3. The resources plugin generates a mapping from /static/js/resource.js to /js/resource.js on web.1
    4. The client makes a request for /static/js/resource.js
    5. The request is routed to a different app server, web.2
    6. /static/js/resource.js has not been mapped on web.2 and 404s

    From my research, the best practice is to declare your resources in a resources file.

    See the following:

    http://grails-plugins.github.com/grails-resources/guide/3.%20Declaring%20resources.html

    This will tell the app server at boot time that a resource exists up front, avoiding the adhoc loading process.

    For example, as in my previous email, a MyResources.groovy would look like:

    modules = { 
      application { 
        resource url:'js/application.js' 
        resource url:'js/ui.geo_autocomplete.js' 
      } 
    }
    

    So, you can use either of the two methods — explicitly specify resources, or use adhoc loading (add the following to your Config.groovy: )

    grails.resources.adhoc.includes = [] 
    grails.resources.adhoc.excludes = ["*"]
    

    It essentially disables adhoc resource processing.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created a new grails project and run it, but I can't see
I have a grails application using hibernate .Under grails 1.3.7 everything works properly, but
I have created one service in my grails application. in that service 25 methods
I have a Grails application I created a Gregorian Calendar GMT date. The time
I have a gae application (created via GRAILS) which loaded up fine, though my
In my Grails application, I run some batch processes asynchronously, and would like the
I'm learning to use Grails and have run into a situation I don't understand
I have a grails application on my local machine and I have created a
I have an example Grails application (from Grails in Action) that was created a
i use webflow in a my grails application, i have 2 tables with relation

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.