Files on a computer have a last modified date in their metadata. When files are uploaded to AEM, some of that metadata is kept and put into nodes. The rest gets lost, from what it seems.
I need to modify a workflow to: extract the last modified date from the file (not the AEM last modified date), and store it in a node that does not change. How can I access this metadata value from a Workflow workItem? Is this even possible to do without writing a separate service that triggers on upload, before the file gets touched by any AEM workflows?
The "Metadata Processor" step in DAM Update Asset is likely accessing the full list of metadata from the file and selectively choosing what to keep. I need to access the same file metadata, which includes the file last modified date, and I need to store it in a node. The last modified date I'm referring to is the one that shows up if you right click -> Get Info on a file on OS X for example. Any advice on the best approach to this would be greatly appreciated.
Are these answers useful? Help other community members by marking useful answers as accepted.
Well, that would be creating a new file so I think it would update for other reasons. The Java File.lastModified method returns the same modified date that Right click -> Get Info returns on mac. Although I'm not sure if this is because its pulling it from the system somehow or off the file itself.
I doubt that a JPG contains the last modification date as metadate within itself.
You can test it: Just copy the file. If the last modification date is the same as with the original, it can be inside the file's metadate. But if the date changes the last modification date is a property of the filesystem.