Configure the Cache Settings for the Historian Tags

About this task

The Analysis application supports the caching and refreshing of the cached Historian tags after certain time interval. You configure the duration of the saved cached Historian tags in the mes-dataservice-prod.properties and processanalyzer-app-service.properties files of the mes-dataservice and processanalyzer-app-service microservices for the Analysis application. After the set duration, the Historian tags are cached again.

Procedure

  1. Based on your type of installation, perform one of the below:
    • Enterprise Installation: In the directory <buildpath>/PlantApplicationsDocker/plantapps-web-docker/mnt/configfiles/mes-dataservice/prod/<version>/, access the mes-dataservice-prod.properties file by using a text editor.
    • Standard Installation: In the directory <Installation-directory>\PlantApplicationsWebClient\config-repo\mes-dataservice\prod\<version>, access the mes-dataservice-prod.properties file by using a text editor. Where:
  2. Enter the properties and their details as described in the following table.
    PropertyDescription
    historianTagMaxCacheSizeEnter the maximum cache size in KB. The default value is 50000.

    Example: historianTagMaxCacheSize=50000

    historianTagCacheTimeOutEnter the duration in the format duration<timeformat> after which the cached Historian tags are cleared by the mes-dataservice-impl microservice. Where: <timeformat> is h, m, or s to indicate time in hours, minutes, or seconds, respectively. The default value is 6h.

    Example: historianTagCacheTimeOut=6h

    scheduler.tagcaching.secondsEnter the duration in seconds after which the Historian tags are cached again by the mes-dataservice-impl microservice. The default value is 21600.

    Example: scheduler.tagcaching.seconds=21600

    Note: The value you enter for the historianTagCacheTimeOut and scheduler.tagcaching.seconds properties must of the same duration you enter for the tagVariableCacheTimeOut property in the processanalyzer-service-impl microservice.
  3. Save the changes to your file.
  4. Based on your type of installation, perform one of the below:
    • Enterprise Installation: In the directory <buildpath>/PlantApplicationsDocker/plantapps-web-docker/mnt/configfiles/processanalyzer-app-service/prod/<version>/, access the processanalyzer-app-service.properties file by using a text editor.
    • Standard Installation: In the directory <Installation-directory>\PlantApplicationsWebClient\config-repo\processanalyzer-app-service\prod\<version>, access the processanalyzer-app-service.properties file by using a text editor. Where:
  5. For the tagVariableCacheTimeOut property, enter the duration in the format duration<timeformat> after which the tags are cached again. Where: <timeformat> is h, m, or s to indicate time in hours, minutes, or seconds, respectively. The default value is 6h. Example: tagVariableCacheTimeOut=6h
    Note: The value you enter for the tagVariableCacheTimeOut property must be of the same duration you enter for the historianTagCacheTimeOut and scheduler.tagcaching.seconds properties in the mes-dataservice-impl microservice.
  6. Save the changes to your file.
  7. Restart the mes-dataservice and processanalyzer-app-serviceservices.

Results

The cached tags are refreshed after the duration you set in the mes-dataservice-prod.properties and processanalyzer-app-service.properties files of the mes-dataservice and processanalyzer-app-service microservices for the Analysis application.