The MSPro Boomi Collection
About
Good Practices & Patterns
Good Practices & Patterns
  • Markus' Boomi Integration
  • Implementation Patterns
    • The Cache Challenge
      • The Get-Or-Create Use-Case
      • PropCache Scripts
    • State Management
      • Example Scenario
      • State-Management in general
      • State-Management Functionality
      • Technical Solutions
        • Boomi File-System Implementation
          • saveState
          • readState & fetchStates
    • Exception Handling
      • Exception vs Error
      • Basic Rules
        • Aggregating Exceptions
      • Exception Handling Pattern
        • User-Defined Exception Messages
        • Catch Exceptions
      • The pattern in practice
        • API Error Handling
          • Single Record Strategy
            • Single Record RES
          • Many Records Strategy (Array)
            • Many Records RES
        • Pre-Condition Check
    • SQL Patterns
      • Script Header
      • General Rules
        • Check using RowCount
        • Check if record exists
        • Pagination and Sorting
        • Parameter - Best Practices
        • Use JSON as a complex parameter
    • Process Patterns
      • Process Route Implementation Pattern
      • Sub-Process or Process Route
    • DateTime
      • The Boomi datetime dilemma
      • Database and Flow
      • Groovy
      • Data Hub
      • Get Current Date
    • Groovy Script Patterns
      • Dynamic Document Properties
      • Dynamic Process Properties
      • Documents
    • Array Elements to Documents
  • MSPro Services
    • Intermediate Storage
      • Example Processes
        • Docs 01 - Update and Create
          • sub.SampleData.Invoice
        • 02 - Upsert and Get
    • Render Templates
  • Tips
Powered by GitBook
On this page
  1. Implementation Patterns
  2. The Cache Challenge

PropCache Scripts

Dynamic Document Property caching

Last updated 4 months ago

There are two scripts which implement Dynamic Document Property caching.

If you can use the Document Cache Component because you must carry over documents from one branch into another, use it! Documents keep their document properties when they are in a Document Cache.

The Dynamic Document Property Cache is not a replacement for the Document Cache. You use the Property Cache when you do not need returned documents, but you only need certain information from it, like an Id or success/failure.

To use the two Property Cache Scripts is fairly simple:

  • (1) Configure caching by setting DPP_ValuePropertyNames = "DDP_AccountId,DDP_InvoiceId" to tell the PropCache.Save script which Dynamic Document Properties should be cached.

  • (2),(3) Whenever you have got the properties call the PropCache.Save script, to add or update their values.

  • (4) When you need the cached Document Properties back call PropCache.Restore and all cached properties will be attached to the current documents

You can the use the document properties in addition to the request document to complete you response profile.

Use Property Cache