Pregunta de entrevista de Coditas

Will transactional be able to commit when we are using file system? Like File has been read, operations have been done and file contents are saved in memory then can we commit the contents of file using this transactional.

Respuesta de la entrevista

Anónimo

6 jul 2025

No, @Transactional in Spring does not and cannot manage transactions on the file system. Spring's @Transactional only works with resources that support transactions, such as: Relational Databases (via JDBC or JPA) JMS (Java Messaging Service Some transactional caches (rare) Distributed transaction managers (like JTA/XA)