The purpose of JD Edwards' JDB Database Caching is for Data Integrity/Coherency and Performance Improvement. Since cache is written to Memory (RAM) it yields better performance (avoiding round trips to database) and it is Shared Cache (read-only cache) coherency problems are easily avoided (so this may cause Dirty/Phantom Reads) for data which are requested frequently/repeatedly.
This document will briefly explain frequently asked questions from an end-user's point of view. This document explains server (as response for a certain request) and client (issuing request) based on HTML client configuration.
For cache information and troubleshooting the different scenarios, causes and resolutions for caching issues in Server Manager, refer to <Document 866662.1> - Cache Information And Troubleshooting Caching Issues In Server Manager.
Environment Cache is the cache which is initialized during E1 login or when starting JDE service(s). This concept is similar to PGA (Program Global Area), a memory region that stores the data and control information for the server processes. Some of the tables that are cached:
TABLE | TABLE NAME/DESC |
---|---|
F0009 | General Constants |
F0010 | Company Constants |
F00921 | User Display Preferences |
F4009 | Distribution/Manufacturing Constants |
F0092 | Library List - Users |
If any value for the above tables change, the change will take effect after logging off and back on to EnterpriseOne.
The list of tables defined in Business View Environment Server (F98613) are NOT pre-loaded into cache during JDE startup. EnterpriseOne reads defined tables in F98613 at startup time, opens the tables specified and caches the information about which tables to be kept in JDB Database cache. In F98613, each table has a limit of how many rows/how much memory will be stored for that table. As the applications fetch a specific row, they are added to cache; and if it exceeds its limit which will be flushed.
ONLY WHEN it meets the following conditions in a certain EnterpriseOne Business Function:
When a business function issues a JDB_FetchKeyed(), JDB checks whether that table is defined in F98613. It will first search cache for the requested record. If the row is not in cached, it fetches the row from the table and adds it to cache. One of the other JDB I/O APIs uses JDB DB cache. In Performance Viewer, a read from JDB DB cache shows up as a call to JDB_FetchKeyedCache(). In a certain batch, tables can be added to initiate database cache by calling business function B4101380 - CacheTableForUBE.
The following information will be cached by JAS. These caches will be handled by JVM in memory (RAM). For example:
Object cache will contain conventional TAMSpec information. Note that synchronization of this information is important among Central Objects, Serialized Objects and Object Cache.
Tables that are cached:
TABLE | TABLE NAME/DESC |
---|---|
F98613 | Database Caching (Table Defined from F98613) |
F98611 | Data Source Master |
F983051 | Version List (Processing Option) |
F986101 | Object Configuration Master (OCM) |
F00950 | Security Workbench Table (Runtime Security) |
These tables caching fulfill higher data integrity in general. The sequence of cached data will be identical to the sequence of primary key of tabled defined as it returns the best performance in searching data.
It varies between Tools Releases. For example, JDE makes use of KRNLSPEC.zip to cache bootstrap tables. The tables defined below are hard coded so overriding OCM will not take effect. Examples are, KRNLSPEC.zip. Refer to DD: Impact of Changing a Bootstrap Table Data Dictionary Item.
TABLE | TABLE NAME/DESC |
---|---|
F00165 | Media Objects storage |
F0092 | Library Lists - User |
F00921 | User Display Preferences |
F00922 | User Preference Tag File |
F00924 | User Install Package |
F00925 | User Access Definition |
F00926 | Anonymous User Access Table |
F0093 | Library List Control |
F0094 | Library List Master File |
F00941 | Environment Detail - One World |
F00942 | Object Path Master File |
F00945 | Release Master |
F00948 | Release/Data Source Map |
F00960 | Machine/Group Identification |
F9200 | Data Item Master |
F9202 | Data Field Display Text |
F9203 | Data Item Alpha Descriptions |
F9207 | Data Dictionary - Error Message Information |
F9210 | Data Field Specifications (OneWorld) |
F9211 | Data Dictionary - Smart Field |
F9312 | Security History |
F95921 | Role Relationship Table |
F9650 | Machine Master |
F98101 | Imaging Constants |
F983051 | Version List |
F9860 | Object Librarian Master Table |
F9861 | Object Librarian - Status Detail |
F986101 | Object Configuration Master |
F98611 | Data Source Master |
F986111 | Job Number Master File |
F98613 | Business View Environmental Server (Database Caching) |
F9862 | Object Librarian - Function Detail |
F9863 | Object Librarian - Object Relationships |
F9865 | Form Information File |
F98710 | Table Header |
F98711 | Table Columns |
F98712 | Primary Index Header |
F98713 | Primary Index Detail |
F98720 | Business View Specfication |
F98740 | Event Rules - Link Table |
F98741 | Event Rules - Specification Table |
F98743 | Data Structure Templates |
F98745 | Smart Field Named Mappings |
F98750 | Forms Design Aid Text Information |
F98751 | Forms Design Aid Specification Info |
F98752 | Forms Design Aid/Software Versions Repository Header Info |
F98753 | Forms Design Aid/Software Versions Repository Detail Info |
F98760 | Report Design Aid Text Information |
F98761 | Report Design Aid Specification Info |
F98762 | JDEBLC - Behavior Information |
F9885 | Install Package Header |
F9887 | Install Package Build History |
F9888 | Merge Log |
F9889 | Deployment Location Master |
F98891 | Deployment Location Path Code |
F98950 | User Override Table |
F98DRENV | Data Replication Environment Mapping Table |
F98DRPUB | Data Replication Publisher |
F98DRSUB | Data Replication Subscribers |
F98OWSEC | OneWorld Security |
Yes. Ideally you can define your own cache but we discourage you from adding it because it may cause other issues. One possible reason is that the JDE API will determine whether to read the cache table or physical table so this has to work with the actual C code available in executing a certain transaction. As we have discussed earlier, the purpose of caching is not only to have better performance but also to maintain higher consistency across the system.
The different caches are as follows:
P98613 (Work With Database Caching) application will list all tables cached within your own environment because the tables defined can vary between EnterpriseOne versions and Tools Releases. Below is a basic list of tables where data are cached.
Table | Table Name/Description | Others |
---|---|---|
F0004 | User Defined Code Types | Database Cache & Service Cache |
F0005 | User Defined Codes | Database Cache & Service Cache |
F0006 | Cost Center Master | |
F0007 | Work Day Calendar | |
F0008 | Date Fiscal Patterns | |
F0010 | Company Constants | Database Cache & Service Cache * In Xe and ERP8, this table is not a member of Database Cache |
F0010T | Company Constants Tag Table | Can be added for Dynamic Cache (9.1 Update 2 and above) |
F0012 | Automatic Accounting Instructions Mater | |
F0013 | Currency Codes | Database Cache & Service Cache |
F0014 | Payment Terms | |
F00141 | Advanced Payment Terms | Can be added for Dynamic Cache (9.1 Update 2 and above) |
F00144 | Installment Payment Terms | |
F0015 | Currency Exchange Rates | |
F0022 | Tax Rules | |
F0025 | Ledger Type Master File | Database Cache & Service Cache |
F0026 | Job Cost Constants | |
F01138 | AB Data Permission List Definitions | |
F069016 | Payroll Tax Area Profile | |
F069036 | Payroll Transaction Cross Reference | |
F069056 | Establishment Constant File | |
F069086 | Payroll Corporate Tax Identification | |
F069096 | Payroll General Constants | |
F069106 | Union Benefits Master | |
F069116 | Payroll Transaction Constants | |
F069226 | Unemployment Insurance Rates | |
F07901 | Pre-Payroll DBA Calculation Control Table | |
F08040 | HR History Constants | |
F0901 | Account Master | |
F1200 | Fixed Asset Constants | Can be added for dynamic cache (9.1 Update 2 and above) |
F1609 | Cost Management Constants | |
F1690 | Enables Tables by Application | |
F17001 | Service Warranty Constants Table | |
F1724 | Service Contract Coverage | |
F1725 | Service Contract Services | |
F1752 | Case Types | |
F1753 | Case Priority | |
F1790 | Product Family/Model Master | |
F1793 | S/WM Line Type Constants | |
F3009 | Job Ship Manufacturing Constants | |
F3009T | Manufacturing Constants Tag File | Can be added for dynamic cache (9.1 Update 2 and above) |
F40039 | Document Type Master | |
F40070 | Preference Master File | |
F40073 | Preference Hierarchy File | |
F4008 | Tax Areas | |
F4009 | Distribution/Manufacturing Constants | |
F40095 | Default Locations/Printers | |
F4009T1 | Distribution/Manufacturing Constant Tag Table | Added for Taxed Unit Price (9.0 and above) |
F40203 | Order Activity Rules | |
F40205 | Line Type Control Constants File | |
F4070 | Price Adjustment Schedule | |
F4071 | Price Adjustment Type | |
F4095 | Distribution/Manufacturing - AAI Values | |
F41001 | Inventory Constants | |
F41002 | Item Units of Measure Conversion Factors | |
F41003 | Unit of Measure standard conversion | |
F46L001 | License Plate Numbering Constants | |
F48091 | Billing System Constants | |
F49002 | Transportation Constants | Can be added for dynamic cache (9.1 Update 2 and above) |
F49003 | Load Type Constants | Can be added for dynamic cache (9.1 Update 2 and above) |
F49004 | Mode of Transport Constants | Can be added for dynamic cache (9.1 Update 2 and above) |
F4950 | Routing Entries | Can be added for dynamic cache (9.1 Update 2 and above) |
F4953 | Routing Hierarchy | Can be added for dynamic cache (9.1 Update 2 and above) |
F4973 | Rate Structure Definition | Can be added for dynamic cache (9.1 Update 2 and above) |
F4978 | Charge Code Definitions | Can be added for dynamic cache (9.1 Update 2 and above) |
F7306 | Quantum Sales and Use Tax Constants | |
F90CA000 | CRM_Constants Table | Can be added for dynamic cache (9.1 Update 2 and above) |
F95922 | Permission List Relationship Table | |
F99410 | OneWorld System Control File | * Not Server Map |
FF30L011 | Line Design Control Parameters | |
FF30L012 | Kanban Control Parameters | |
FF34S003 | DFM Planning Parameters |
Table | Table Name/Description | Others |
---|---|---|
F0004 | User Defined Code Types | & Database Cache |
F0005 | User Defined Codes | & Database Cache |
F0005D | User Defined Codes - Alternative Language | Only Service Cache (Not Database Cache) |
F0010 | Company Constants | & Database Cache |
F0013 | Currency Codes | & Database Cache |
F0025 | Ledger Type Master File | & Database Cache |
F0092 | Library List - User | Only Service Cache (Not Database Cache) |
F00941 | Environment Detail - OneWorld | Only Service Cache (Not Database Cache) |
F0111 | Address Book - Who's Who | Only Service Cache (Not Database Cache) |
F9500001 | CFR Configuration Table | Only Service Cache (Not Database Cache) |
F95921 | Role Relationship Table | Only Service Cache (Not Database Cache) |
F9861 | Object Librarian - Status Detail | Only Service Cache (Not Database Cache) |
Refer to <Document 650630.1> E1: FDA: Tables Cached by JDBJ (8.95 and higher) and also the list below of the detailed definition:
* abfullname
* bootstrap
* cfrconfig
* company
* currency
* datadictionary
* ledgertype
* ocm
* omw
* packagelookup
* pathcode
* role
* security
* serviceobj
* setid
* spec
* tablelookup
* udc
Refreshing/resetting/flushing cache can be vary, for example:
Update: EnterpriseOne Tools Release 9.1.2 and above - Two additional options are available to reset database table cache:
IMPORTANT for E1 9.1 Update 2 onwards: If you are EnterpriseOne Application Release 9.1 Update 2 onwards, new feature which can delete Database Table Cache automatically in your updating/deleting a certain table record through Pre-Configured applications. For detail information refer to <Document 1617534.1> E1: ENV: Resetting Database Table Cache Using a Pre-Configured Application and P986116D.
If JDE BSFN is to read cache, JDE API JDB_FetchKeyed will be issued from a certain BSFN. For Tools Releases 8.97 and above, additional information can be found in our Server Manager Guides on Caching:
Transactional Cache can be updated or manipulated through BSFNs; however Database cache which is shared cache can only be inserted and deleted. Deletion\flush takes place when starting or bouncing JDE Service(s) or by clicking the button 'Reset Cache' in Work with Server Jobs (WSJ) or when database cache reaches the defined maximum value of Memory or Rows.
This action is not recommended. As stated above the purpose of database caching is to maintain high integrity and performance for constant tables which are to be requested frequently. Across EnterpriseOne, table F0008 will be accessed numerous times. In removing F0008 from F98613 a certain routine has to take round trip to logic server to DB server so there can be some performance impact especially in running long running UBEs. Most of cases, F0008 is subset of F0010 so it is not proper to remove it from list.
There can be a few methods to determine this. First; in a long running report, the performance gain may be significant (Ex: run R3482/R3483 with caching on and without caching on). An alternative way to determine is by analyzing the JDEDEBUG.LOG (Call Object kernel log) which may have the behavior described below:
From the above example, it does not make a connection to DB den60srvs because database cache will return a value immediate after JDE API JDB_FetchKeyed(). You may flush database cache in case you need to debug what is actual query issued as it is shown '1st request' above.
To enable cache manager tracing, change the following setting in server JDE.ini file
[DEBUG]
CMTrace=1
Note:
Yes. As stated above, database cache sits in a shared memory area per data source that you have defined so it should not affect cache (private memory) created during transactions . Steps to get certain table information are:
If database cache is flushed in the middle of a transaction, it will do step 5.
Some examples are:
No. it is not possible to implement this as JDE borrows Database technology to perform this. So if a certain table is huge in size, (and it is optional) do not turn on caching as this may cause 'Memory Allocation Failure' errors. If a certain table is defined for caching through UBE, then it is just ready to be cached supposing that same records may be requested multiple times in a routine. To have some example of standard EnterpriseOne UBEs refer to <Document 1420774.1> E1: 40: Database Cache in Distribution and Manufacturing
No. Due to the nature of subsystem UBEs, these run continuously and by default. So changes to UDC values will not be picked up until EnterpriseOne services are restarted, or the subsystem UBE is stopped and restarted. Refer section "When is the JDB Database Cache Used?" which explains why it performs dirty read.
Notes:
It is defined at COMMON_POOL which sits in the Shared Memory area and this is accessed globally and should not be updated.
Since EnterpriseOne follows the Distributed Environment in industry, other types of caches used depends on these possible questions:
Note that certain caches can be categorized in more than 2 cache types depending on Time and Space.
The Table F0010 is cached for both JAS (Client) and Logic Server (Server). We may call it Service Cache and Database Caching respectively. In general:
To determine this observe the BSFN which gives the error. If the error comes from BSFNs the error may appear as "Record Invalid" or "Fetch From table failed" depending on the application you are running. This is usually caused by Service Cache in Server.
If the error is issued by other BSFNs, Database caching may have a problem. The error can vary like this example: Current Period Number may be computed wrongly. Some examples may be:
Example of error:
For this example, Service Cache in JAS is having problem after changing period number in P0010. As we can see in the error detail, issue is detected by business method RetrieveCompanyCurrencyCode.java. For further detail, refer to <Document 1090584.1> E1: BSFN: Frequently Asked Questions on Business Functions/Methods Running on JAS. So to minimize this type of errors, reset Service Cache in JAS and Database cache in your Logic Server.
Whenever there is any issue with table F0010, try to capture the JASDEBUG.LOG from the JAS Server and JDEDEBUG.LOG from the Logic Server. To handle data for both database level and presentation level, some BSFNs will be running in JAS while others run on the logic server though by default, The DEFAULT BSFN is mapped to Server for J* Environments through OCM mapping. Some BSFNs run in Local (JAS) which can be found defined in LocalLogicCatalogLocalLogicCatalog.xml (OAS: OAS:
\\JASMachineName\E1Release\system\OC4J\j2ee\home\applications\webclient.ear\webclient\WEB-INF\classes)
Refer to <Document 1090584.1> E1: BSFN: Frequently Asked Questions on Business Functions Running on JAS.
With Tools Release 8.97 and 8.98 there are two different object caches, one is in UserOverride and the other is in RuntimeCache. Please note that when deploying a package or submitting version spec, object cache (RDASPEC) will get flushed and created. Running a UBE, the UBE Kernel will create a temporary file to hold runtime cache (DataSelection and DataSequence information) and at the end of the transaction these files are removed.
Custom applications that write to F0006 and F0901 which are listed in P98613, do not show newly updated data after an insert/update. If these tables are removed from P98613, the new/updated data shows. Is there any impact to these tables (Ex: data integrity) if they are removed from P98613?
If these tables are being updated frequently (inserts/updates, etc.), then caching these tables is not recommended; which would mean deleting these tables from P98613. If these tables are not updated frequently, resetting the database cache after any changes to these tables would be required.
Tables are cached only when select operation are performed. For example, when an insert or update to these tables is done, it will not cache at the same time. To reflect changes in cache, a reset/refresh cache is required.
The Enterprise/Logic server JDE.LOG log is full of thousands of lines the same message:
JDB9900999999 - System cache is full
What does this message mean and how can it be eliminated?
The error with "System cache is full" does not mean that it is from the JDE kernel or "system" code. The error can come from any jdeCache usage, from Apps, BSFNs, and Tools code. Any call to jdeCacheAdd() or JDECM_CacheAdd(), could result in a code path to the error. The following are some issues that can cause this message in the log. Note: Some of the causes listed below do not have a direct solution.
Scenario 1:
The error could happen if the nTotalMemoryUsed starts at size zero, and the very first usage comes in with a negative nDataSize. However, there is a test for nDataSize <= 0, which should log a different error.
Scenario 2:
The error could happen if the actual cache memory usage became larger than 2147483647, at which point the nTotalMemoryUsed would become a negative number. However, it would likely be a large negative number, and would not trigger the error until it was increased enough to be larger than -1000. The error could be created by having nDataSize of (2147483647 minus {1, or 2, or 3, ... through 499}). Adding the second record should trigger the error.
Scenario 3:
It can be caused if the previous cache memory was deleted (such as RBTREE_Delete()), and the nNodeDataSize was too large, or the function was called too many times, resulting in a negative nTotalMemoryUsed. This might happen if the nDataSize was not consistent, and data was added using different sizes, and that resulted in incorrect sizes being subtracted as records were dropped.
Scenario 4:
A memory overwrite, from somewhere else, could write over nTotalMemoryUsed , and change it to a small negative number.
The function JDECM_GetMemoryStats() can be called to get nTotalMemoryUsed size.
CMTRACE can be turned on, to track if there was a negative data size or negative total memory. The functions jdeCacheAdd() or JDECM_CacheAdd() will call JCACH_CacheAddInt(), which will display "JDECM_SUCCESS: Add rec size:%d Total mem:%d Total recs:%d", where "rec size" is the nDataSize being added and the "Total mem" is the nTotalMemoryUsed.
For this type of message, contact Oracle Global Support for further assistance.
The error could happen if the nTotalMemoryUsed starts at size zero, and the very first usage comes in with a negative nDataSize. However, there is a test for nDataSize <= 0, which should log a different error.
This instruction can be applied as follows:
Note that Step 1 and 2 is only for situations where Oracle Development has delivered a customer specific fix
JSP (JavaServer Pages) Cache is the compiled version of JSP files. When JSP gets compiled by Apache Jserv, it gets internally gets converted into a .java file (servlet) and then that .java file gets compiled into a .class file. To optimize runtime performance, it may be required to clear JAS cache.
In OAS:
In WebLogic:
For Weblogic server under the domain/servers folder go to each server folder. Delete the folders named like "tmp", cache. (Take a backup of the folders before deleting)
Ex: user_projects\domains\<yourdomain>\servers\\tmp
Yes. You can reset/delete/flush both caches to read information from database again. Since it required additional round trip to database for data defined it may cause slower performance till relevant data puts into memory. For call object kernel users, you need to log off/on EnterpriseOne to have a new process gets assigned to your user ID with flushed cache.
JDEDB_RESULT JDB_ClearTableDBCache(HUSER hUser, NID szTable); This API allows you clear out the F98613 cache for a particular table.
Bug 10702589 - CLEAR SINGLE DB TABLE CACHE - SAR: 3438041