title: Caching file content inside ExecuteScript processor of Apache NiFi
body: <p>I have an <em>ExecuteScript</em> processor that does an XML flow file validation against schematron. I'd like the content of the schematron file to be cached somewhere rather than read from the disk for every flow file again and again.</p>
  
  <p>What is the best option for doing this? Do I need yet another script that puts the content of the schematron into <em>context.stateManager</em> or <em>PutDistributedMapCache</em> or what?</p>