cancel
Showing results for 
Search instead for 
Did you mean: 

data-sap-ui-appCacheBuster - 404 NOT FOUND - REQUESTED RESOURCE OUTDATED

santhu_gowdaz
Active Contributor
0 Kudos
2,979

Hi All,

          I added data-sap-ui-appCacheBuster="./" in my application to avoid cache clear problem.But i'm getting below error.

404 NOT FOUND - REQUESTED RESOURCE OUTDATED

If i remove appcachebuster then application is working fine. And also other Applications deployed under VPN connections are working.But i deployed BSP application in Client system directly. UI5 lib and View is loaded successsfully(with 304-not modified). But the controller file gives error mention above.

I tried to executed SE38 (No luck )-

/ui5/update_cachebuster

/ui5/reset_cachebuster

Please help me.

Accepted Solutions (1)

Accepted Solutions (1)

former_member182372
Active Contributor
0 Kudos

what is 404 for? for sap-ui-cachebuster-info.json?

santhu_gowdaz
Active Contributor
0 Kudos

Sorry for the incomplete explanation.

i created the application in standard and deployed in my local server. After that we moved TR request to client system and i done extension for this application(bec the standard application should work in my server and as well as changes should do in client requirements).so i added this CacheBuster in extension application and deployed in client machine.

And yes sap-ui-cachebuster-info.json is loading successfully and the index.html, component.js, and view.xml also loading with 304. But view.controller gives above mentioned error. so i could not see the   viewCustom.xml or viewCustom.controller in network tab

former_member182372
Active Contributor
0 Kudos

what's the value for view.controller in sap-ui-cachebuster-info.json? and what is the URI for that? can you access it directly instead of cached version (someting like ~20150712034639~ in path)

santhu_gowdaz
Active Contributor
0 Kudos

yes i can access that controller with out cache path.

And there is no value for view.controller in sap-ui-cachebuster-info.json but have value for viewcustom.controller.And also i checked other working Application have same thing cachebuster-info.json.

Extension application only gives this error but direct applications working properly.And also same extension application deployed through VPN connection also working.(I'm in client place- can deployed application directly with out VPN connection as well as my colleges deployed same application working properly under VPN connection).


As a solution we deployed application under VPN connection(I download and its working fine) But if i add appCacheBuster and deployed getting same error.


Need to know why this type of strange.


former_member182372
Active Contributor
0 Kudos

Ok, let me summarize

the original app has data-sap-ui-appCacheBuster="./" in a bootstrap

the extension app:

has data-sap-ui-appCacheBuster="./" in a bootstrap

complains about view.controller

in sap-ui-cachebuster-info.json of extension app it has viewcustom.controller but not view.controller

BTW do you call

sap.ui.core.AppCacheBuster.register("/sap/bc/my/other/component"); for original application inside the extension?

santhu_gowdaz
Active Contributor
0 Kudos

Above you mentioned line i added in Component.js.

Now cachebuster-info.json is showing parent application path. component/sap-ui-cachebuster-info.json?sap-ui-language=EN (not extension application path or Cache path) 404 Not Found error.

And Parent Component.js,view.xml and viewcontroller are loading without Cache path but its showing 304 not modified. And with Cache Path viewCustom.xml is loading 304 successfully But viewCustom.controller Gives 404 NOT FOUND - REQUESTED RESOURCE OUTDATED error.

former_member182372
Active Contributor
0 Kudos

try to run

sap.ui.core.AppCacheBuster.register("");


for both, original and extension apps, inside the extension app

santhu_gowdaz
Active Contributor
0 Kudos

2 sap-ui-cachebuster-info.json loading parent and extension path both 404 error.

former_member182372
Active Contributor
0 Kudos

404 for viewcustom AND view?

do you call jQuery.sap.registerModulePath for original in extension?

former_member182372
Active Contributor
0 Kudos

what really matters is the content of both sap-ui-cachebuster-info.json for original and extension, first make sure they have corrscponding entries

santhu_gowdaz
Active Contributor
0 Kudos

yes parent view and controller loading. extension view is loading but extension controller gives 404 error.

santhu_gowdaz
Active Contributor
0 Kudos

Sorry i removed component from extension path.

sap.ui.core.AppCacheBuster.register("/sap/bc/my/other");

Now sap-ui-cachebuster-info.json for extension loading properly and i checked date for extension view and controller in sap-ui-cachebuster-info.json file. Its same with Cache(date) path but Extension view loading and extension controller not(404 NOT FOUND - REQUESTED RESOURCE OUTDATED).

former_member182372
Active Contributor
0 Kudos

magic....

Extension's sap-ui-cachebuster-info.json has entry for controller but when accessed using ~yyyyMMddHHmmss~ prefix it gives 404.


is that ~yyyyMMddHHmmss~ for controller same as in sap-ui-cachebuster-info.json?


and when accessing extension controller directl it works fine?


And you tried to invalidate the cache?


Do you use Component-preload?


mylsat idea is to Try to redeploy just extension controller.

santhu_gowdaz
Active Contributor
0 Kudos

Extension's sap-ui-cachebuster-info.json has entry for controller but when accessed using ~yyyyMMddHHmmss~ prefix it gives 404.

A: Yes

is that ~yyyyMMddHHmmss~ for controller same as in sap-ui-cachebuster-info.json?

A: Yes

and when accessing extension controller directl it works fine?

A: Yes

And you tried to invalidate the cache?

A: GW as well as browser cache clear.

Do you use Component-preload?

A: No

mylast idea is to Try to redeploy just extension controller.

A: I redeployed it.if i remove appCache from index.html, application working fine. But if i add that line extension view is loading and the controller cache date is showing old date(It should show today date right?).


former_member182372
Active Contributor
0 Kudos

>> and the controller cache date is showing old date(It should show today date right?).


Once you redeploy it should set that date to current (or by invalidating the cach)


try


As an alternative you can trigger the reset for a specific SAPUI5 application from the browser using the URL "<application base path>/resetcachebuster".



as from Testing the SAPUI5 Application on an ABAP Server - User Interface Add-On for SAP NetWeaver - SAP Lib...

former_member182372
Active Contributor
0 Kudos

so did you try <application base path>/resetcachebuster?

santhu_gowdaz
Active Contributor
0 Kudos

I noticed this is because of folder structure in BSP application,

As of now i deleted that BSP application and redeployed it so its working fine.

Below Images shows 1.Strange 2 webcontent files / 2.Normal Application(SE38) / 3.Deployed from Eclipse directly. 

1.Actually i deployed my application manually using t-code "SE38". And after that using share option from eclipse i shared that project and deployed(that's the reason its contains all the files 2 times).

2. Using SE38 webcontent deployed working fine.

3. Using Eclipse share i deployed directly from eclipse working fine.

How i can handle 1st type of applications. and why this type of strange folder structure in BSP application?

former_member182372
Active Contributor
0 Kudos

by default Eclipse creates a web project when sapui5 project is created, that means - Web-Content folder. if project is creted from web ide it creates the content in root folder, so sometime this can case a confusion.

santhu_gowdaz
Active Contributor
0 Kudos

Then how i can solve this issue of type 1. need to delete that BSP application and Re-Deploy?.

And also in future manually deployed  using SE38 need to deploy manually, same way as well as Eclipse Share project?

But we moved some application from Quality to Development server. so please tell me the solution.

former_member182372
Active Contributor
0 Kudos

when you use a programm (se38) to upload the project check what`s in folder/archive. It should have all the content (xml, js) under WebContent folder so it will be compatable with eclipse

former_member182372
Active Contributor
0 Kudos

seems like that guy works on the same problem

santhu_gowdaz
Active Contributor
0 Kudos

It contains all the files but folder structure is different from SE38 and Eclipse share option,

Need to follow 1 option "GLOBALLY".?

former_member182372
Active Contributor
0 Kudos

i dont really know how to control the structure, just try to stick to consistent enviroment for all developers working on the project (use eclipse). there is a UI5RepositoryPathMapping.xml where the mapping between file in project structure mapped to the pathes (how they accessed from browser), that`s the only place where i can think you can control where files are.

santhu_gowdaz
Active Contributor
0 Kudos

Thank you so much for your suggestions.

Answers (1)

Answers (1)

Nicolas_Alech
Product and Topic Expert
Product and Topic Expert

Dear all,

this comes massively late, but maybe it can help some others running into the same issue.

If you find in your console the message saying: "Requested Resource Outdated", there is an easy way to reset the cache buster from the browser directly.

Copy the url from the error message (the one which is outdated), remove the last part (something .js most of the time) and add at the end of the URL: resetcachebuster.

It will give you: https://myhost:myport/sap/bc/ui5/<application>/<path>/resetcachebuster

It will take a moment and you should receive a message saying:

The application index has been updated for SAPUI5 repository 'XXXXXXXXXXX'.

Hope it might help some of you.

0 Kudos

Hi Nicolas,

It worked for me, Thanks

kevindupreez
Discoverer

Hi Nicolas,

It worked for me as well.

Thanks a lot.