We store a lot of data locally, as Shared Objects. This reduces the burden on the server and SQL Server. For the first time, though, some data schema changed, which means locally cached data now fails to load, and therefore throws an error. This was easily fixed, with try/catch.
// let's not assume the data is in good condition...
// if it's corrupted or the schema's been changed
// then we throw an error.
try {
cache[cacheName]
= SharedObject.getLocal(cacheName);
}
catch( err:Error ) {
... flag this data to be re-fetched ...
}
Problem solved.
No comments:
Post a Comment