Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for lockAcquired (0.16 sec)

  1. platforms/core-runtime/base-services/src/main/java/org/gradle/internal/resources/ResourceLockContainer.java

     * See the License for the specific language governing permissions and
     * limitations under the License.
     */
    
    package org.gradle.internal.resources;
    
    public interface ResourceLockContainer {
        void lockAcquired(ResourceLock lock);
    
        void lockReleased(ResourceLock lock);
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Sep 22 08:48:02 UTC 2023
    - 785 bytes
    - Viewed (0)
  2. platforms/core-runtime/base-services/src/test/groovy/org/gradle/internal/resources/AbstractTrackedResourceLockTest.groovy

            given:
            _ * coordinationService.current >> resourceLockState
    
            when:
            lock.tryLock()
    
            then:
            1 * container.lockAcquired(lock)
            1 * resourceLockState.registerLocked(lock)
    
            when:
            lock.unlock()
    
            then:
            1 * container.lockReleased(lock)
        }
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Sep 22 08:48:02 UTC 2023
    - 1.9K bytes
    - Viewed (0)
  3. platforms/core-runtime/base-services/src/main/java/org/gradle/internal/resources/AbstractTrackedResourceLock.java

            if (!isLockedByCurrentThread()) {
                if (acquireLock()) {
                    LOGGER.debug("{}: acquired lock on {}", Thread.currentThread().getName(), displayName);
                    try {
                        owner.lockAcquired(this);
                    } catch (RuntimeException e) {
                        releaseLock();
                        throw e;
                    }
                    coordinationService.getCurrent().registerLocked(this);
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Sep 22 08:48:02 UTC 2023
    - 3.2K bytes
    - Viewed (0)
  4. platforms/core-runtime/base-services/src/main/java/org/gradle/internal/resources/AbstractResourceLockRegistry.java

                if (resourceLock.isLocked()) {
                    return true;
                }
            }
            return false;
        }
    
        @Override
        public void lockAcquired(ResourceLock resourceLock) {
            ThreadLockDetails<T> lockDetails = detailsForCurrentThread();
            if (!lockDetails.mayChange) {
                throw new IllegalStateException("This thread may not acquire more locks.");
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Sep 22 08:48:02 UTC 2023
    - 4.6K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/util/concurrent/UninterruptiblesTest.java

        Stopwatch stopwatch = Stopwatch.createStarted();
        Lock lock = new ReentrantLock();
        Thread lockThread = acquireFor(lock, 5, SECONDS);
    
        boolean lockAcquired = tryLockUninterruptibly(lock, 500, MILLISECONDS);
    
        assertFalse(lockAcquired);
        assertAtLeastTimePassed(stopwatch, 500);
        assertNotInterrupted();
    
        // finish locking thread
        lockThread.interrupt();
      }
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Jun 10 16:06:39 UTC 2024
    - 31.7K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/util/concurrent/UninterruptiblesTest.java

        Stopwatch stopwatch = Stopwatch.createStarted();
        Lock lock = new ReentrantLock();
        Thread lockThread = acquireFor(lock, 5, SECONDS);
    
        boolean lockAcquired = tryLockUninterruptibly(lock, 500, MILLISECONDS);
    
        assertFalse(lockAcquired);
        assertAtLeastTimePassed(stopwatch, 500);
        assertNotInterrupted();
    
        // finish locking thread
        lockThread.interrupt();
      }
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Feb 09 22:57:07 UTC 2022
    - 30.9K bytes
    - Viewed (0)
Back to top