5. Classic Style
• Update Dol for ever new global object
• Dol is shared possibly by apps
• Urr is shared possibly by apps
• Deployment is difficult
• Locked files causes issues
• Undoing your updates is difficult
• No partitioning across app sub-systems
28. The Benefits
• Easy to deploy: Copy & Paste
• UAR Based on Standard Zip technology
• Easy to do/undo changes
• Run Straight from UARs
• Application Partitioning
29. Compatibility
• Uniface is still installed in classical style
• Usys Directory contains both styles
• IDF flags /dis /ins /dol /urr still work
• $search_descriptor & $search_object are
ignored in “resources_only” mode
• Urr’s & Dol’s are new the format from
Uniface 9.3
• No migration issues: just recompile your
complete app (Uniface 9.3 upwards)
How to Move to Standard Deployment
What ASN settings are needed
What is needed for Development and what for Deployment
I will tell you about the Uniface Resource Manager command line utility
And the Compatibility issues
Let’s start with this illustration . This is the classical style of the Uniface 9 development repository as it comes out of the box.
This illustration shows how information flows from entities in the Development Repository to corresponding database entities in the Runtime Repository, and to files in the runtime environment.
Point out:
You see your Development repository your Runtime repository and your runtime Files
Entity and component descriptors (signatures) are in
ULANA—take occurrences from the table ULANA.DICT. (local)
USYSANA—take occurrences from the table USYSANA.TEXT. (global)
Global objects can be compiled to the Repository (UOBJ.TEXT) and then moved to uobj.dol, or they can be compiled to resource files on the file system.
The order of reading this information can set in your idf.asn in the setting section by:
URR => $SEARCH_DESCRIPTOR
DOL => $SEARCH_OBJECT
DOL:
contains compiled global objects needed by Uniface at run time.
usys.dol contains the global objects needed by Uniface itself
uobj.dol contains the application-specific objects.
URR
udesc.urr = Entity descriptors for your local application models.
uana.urr = Entity descriptors for globally available application models.
For deployment, objects need to be copied into UAR files. There is no need to update uobj.dol every time you add a new global object.
Storing global objects in this way makes it easier to distribute applications in a modular fashion, because global objects can be grouped into different archive files, instead of all global objects ending up in a single DOL file.
This is an Uniface schematic picture of the classical runtime environment as you use to.
So if you run the IDF with the delivered asn file settings you get dols & urrs
Because of compatibility IDF is delivered in the classic style.
The classic style has some disadvantages:
You have to update your DOL for every new of changed global object.
Another issue can be locking, because your DOL and URR can be shared over different apps. (clients)
And if you have rollout your app changes, it is not easy to undo this changes!
And the last point is that there is no partitioning possible of what you deploy. In the classic way the output of the idf is just a batch of objects.
Which makes it all so difficult.
Goals: New Style deployment:
Simplify the distribution
Make updates easier
And that it is possible to partitioning to application
The new runtime environment will be different. And will be call the standardized style.
The new style also delivers the Uniface Objects. ALL objects are delivered as files in a fixed directory structure.
component definition and the global object are delivered as files. Therefore in the new style you do not see dol & urr files.
If you compile in the new style, nothing will be hold in the Repository/DBMS.
keep in mind that this fixed structure may not be changed. Done for performance to quickly find the needed objects. And to avoid name clashes.
From your Uniface resource directory you can create Uniface Runtime Archives. The directory Structure is compressed and Called UAR’s
The UAR is not a private implementations file-structures. It is based on a ZIP standard technology
Deployment utility UARs is not new in Uniface but in 9.3 it is changed! These do not have to be unpacked. You can run your apps directly from an archive file.
You can run your application from a single UAR or subdivided as you wish.
So you can “Partitioning’ your application
For the standard deployment you need to add some settings.
$Resources_output is the setting which switch the output of the compiler to the new style.
Compiler output straight into a UAR
Very handy if you already build your applications by script. (patches)
I will use an Uniface Tree sample
/all => show old output
RESOURCES_OUTPUTUniface_Resource_Directory
RESOURCES_OUTPUTutree.uar
What about the runtime
You can run directly from an archive (you do not have to unpack the UAR)
What todo for the runtime: Just add the UARs in the ASN file
So, No object in the dictionary, all in the directory structure. No UOBJ.TEXT or ULANA.DICT or USYSANA.TEXT
No components are read from /components or /usys
What do you have todo to set op the standardized environment. (NEW style)
What I do is always set the default settings in the usys.asn
Explain the picture:
[resources] contains ALL information you need on runtime.
Read from top down
So, No object in the dictionary, all in the directory structure. No UOBJ.TEXT or ULANA.DICT or USYSANA.TEXT
What do you have todo to set op the standardized environment. (NEW style)
Explain the picture:
[resources] contains ALL information you need on runtime.
Read from top down
So, No object in the dictionary, all in the directory structure. No UOBJ.TEXT or ULANA.DICT or USYSANA.TEXT
Change of [resources] in asn. Next time a servers starts it will run with the new UARs.
Create / deploy a New version
We will update with something like common
For compatibility reasons we will deliver Uniface still in the old style. This will change in Uniface version 10
add Uniface_Resource_Directory to the [RESOURCES] section
Emphasize that when removing, it means certain asn file lines no-longer have any effect.
Add your own files into an UAR
$tcp examples..
For the runtime: You will see here 4 different settings
With this switch you decide to run in old or new style OR a mixture
ONLY NEW => the runtime will only run UARs
Excluded => the runtime will only run in classic style (urr & dol) on UAR will be read. Via [FILES]
MIX MODE => order new/old
After this slide, add the details about the dev environment
URM is a command line deployment utility
It is to maintain UARs or to get information about their contents
It runs on all Uniface Client/Server platforms
Like WinZip
Based on ASN files
D:\build\uniface9\w2k\common\bin> urm copy ..\..\project\Uniface_Resource_Direc
tory/*/* mytest.uar:/*/* -aft=20110502
Or use aft=today option
What is in it for you:
Let see step by step
Deploy is just copy and past. A FIX needed, change ONLY that particular UAR
You don't have to unpack the new UARs
Changing the asn will automatically pick up the new uar. Change asn of a running server the next time it uses your fix
You can decision what an archive contain. UAR can be used to PARTIONING your application. Can be done component based. UARs are totally flexible in storing all your Uniface objects
It will be very clear what is running at the customer side, Just ask which UARs are running
Standard technology you can used WinZip (open source: Zlib)
If do decide not to use this new style of deployment.
You can use everything as before. But you have to recompile all your sources!!!
If you still want to use the old DOL and URR files it is still possible.
The needed component for old and new style can be found in the /usys directory
Keep in mind that if you running in RESOURCE_ONLY that these $search_settings are not used
Old format can NOT run under 9.3