This Question is Possibly Answered

1 "correct" answer available (8 pts) 15 "helpful" answers available (5 pts)
3 Replies Last post: Jan 19, 2010 4:38 AM by Deng Tian  
alchimiste Level 2 17 posts since
Feb 26, 2009
Currently Being Moderated

Jan 18, 2010 1:50 AM

About reloding a package

I use the dynamic package and manifest imports, as Curl Help says...

 

let manifest:ComponentManifest =
    {with-file-caching-style FileCachingStyle.resynchronize do
        {import-manifest
            manifest-url,
            check-out-of-date? = true
        }
    }

 

let package:Package =
    {with-file-caching-style FileCachingStyle.resynchronize do
        {import-package
            package-selector,
            manifest = manifest
        }
    }

 

But one problem has occured : it cannot reload the imported packge.

 

Something strange is that if a manifest.mcurl file size is changed, the package can be reloaded.

 

I don't know what is wrong ...

Deng Tian Level 6 56 posts since
Oct 17, 2007
Currently Being Moderated
1. Jan 18, 2010 3:55 AM in response to: alchimiste
Re: About reloding a package

Maybe you have missed something when reading the documentation, here is the text around the sample codes from documentation:

 

The import-package syntax does not have a comparable option to the import-manifest function's check-out-of-date? keyword, and there is no direct way to force synchronization of individual imported packages. However, since packages depend on the identify of their default manifest (see get-default-manifest), changing the manifest containing the location of the package and using that to import the package should result in a newly synchronized version of the package

 

This explains why changing manifest file could help you reloading your package .

 

I think there is another informal way to help reloading package files:

 

add some codes before import-package like:

{do

    {with-file-caching-style FileCachingStyle.resynchronize do

        {read-from {url "path-to-your-package-file"}}

    }

}

I believe this will reload your package file for sure. Add more lines if you need to reload more that one file like the above.

Deng Tian Level 6 56 posts since
Oct 17, 2007
Currently Being Moderated
3. Jan 19, 2010 4:38 AM in response to: alchimiste
Re: About reloding a package

I haven't yet fully understood what's your real problem is, becuase there are many factors that could affect your result.

 

The special way I wrote above is to ensure that the file will be re-downloaded from web server, instead of the one that has once been cached in browser cache on Windows, and this is usually not needed if you configured your settings related with resynchronization correctly for your Curl applet, including settings in your source codes and settings in Curl Control Panel on your client RTE.

 

Did you try with settings like the following in your applet ?

 

   {applet
    resync-as-of = {utc-date-time  "2003-10-11"}
  }

More Like This

  • Retrieving data ...