Kbase P122653: Static 4GL generated code is not run when it is in a procedure library.
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  14/03/2007 |
|
Status: Unverified
FACT(s) (Environment):
Dynamics
SYMPTOM(s):
Static 4GL generated code is not run when it is in a procedure library.
Dynamics dynamic objects that are converted to static objects with the 4GL generator cannot be used with a procedure library.
Static 4GL generated code does not run in Dynamics session when the code is in a procedure library.
CAUSE:
This is expected behavior. The static 4GL generated code is not intended to be run via the propath, so adding the code to a procedure library and then adding the procedure library to the propath will not work.
Dynamics expects the code to be in a specific location in the <install>\src\dynamics\ry\clc\gen directory.
The progress Dynamics Administration guide states:
Typically, you deploy the source code files for generated-4GL objects to directories as specified by the object path, per object. You must deploy the r-code for these objects into the gen subdirectory of the client cache directory (typically,
OpenEdge_Install\src\dynamics\ry\clc\). Dynamics ignores the PROPATH and looks only in the client cache deployment area for any generated-4GL object r-code that it needs to execute.
FIX:
Remove the static generated 4GL code from the libraries and place it in the:
OpenEdge_Install\src\dynamics\ry\clc\gen
directory.
However, there is a way to make this work using the 'client_cache_directory' startup parameter. For example:
1. In the working directory, created a directory named "client_cache_directory".
2. Generate the appropriate programs into the directory created in step 1. This should generate the files in:
<work>\client_cache_directory\gen
3. Create a procedure library (generated.pl) in the working directory as follows:
- proenv>prolib generated.pl -create
- proenv>prolib generated.pl -add client_cache_directory\gen\afallmencw.r
4. Add the generated.pl to the PROPATH
5. Set the Session Property client_cache_directory to "client_cache_directory" (relative path to directory created in step 1).
6. Regenerate icfconfig.xml.
7. Restart development environment.
The session should now use the r-code from the procedure library on the propath. Although it is important to realize that the <work>\client_cache_directory must exist at runtime (getClientCacheDir checks for it's existence), even though it is not actually used. This directory is a relative path inside the procedure library.