原子性使得这两个操作——从储蓄帐户减钱和向支票帐户加钱——被当作单个事务处理。
Atomicity enables the two operations—the subtraction from the savings account and the addition to the checking account—to be treated as a single transaction.
有一种普遍的观点是,如果只是要读一个对象的字段,不需要请求加锁,尤其是在JLS保证了32位读操作的原子性的情况下,它更是如此。
It is a commonly held belief that you do not need to acquire a lock to simply read an object's fields, especially since the JLS guarantees that 32-bit reads will be atomic.
低级(lower - level)技巧涉及在体系结构中尽可能低的层启动事务,同时仍然能够更新操作的原子性和隔离。
The lower-level technique involves starting the transaction at the lowest possible layer in the architecture while still being able to maintain atomicity and isolation of the update operations.
应用推荐