Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 257 for lockF2 (0.09 sec)

  1. cmd/lock-rest-client_test.go

    	// Attempt all calls.
    	_, err = lkClient.RLock(context.Background(), dsync.LockArgs{})
    	if err == nil {
    		t.Fatal("Expected for Rlock to fail")
    	}
    
    	_, err = lkClient.Lock(context.Background(), dsync.LockArgs{})
    	if err == nil {
    		t.Fatal("Expected for Lock to fail")
    	}
    
    	_, err = lkClient.RUnlock(context.Background(), dsync.LockArgs{})
    	if err == nil {
    		t.Fatal("Expected for RUnlock to fail")
    	}
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Jul 29 18:10:04 UTC 2024
    - 2K bytes
    - Viewed (0)
  2. internal/lock/lock_test.go

    	}
    
    	// unlock the file
    	if err = l.Close(); err != nil {
    		t.Fatal(err)
    	}
    
    	// try lock the unlocked file
    	dupl, err := LockedOpenFile(f.Name(), os.O_WRONLY|os.O_CREATE, 0o600)
    	if err != nil {
    		t.Errorf("err = %v, want %v", err, nil)
    	}
    
    	// blocking on locked file
    	locked := make(chan struct{}, 1)
    	go func() {
    		bl, blerr := LockedOpenFile(f.Name(), os.O_WRONLY, 0o600)
    		if blerr != nil {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Sep 19 18:05:16 UTC 2022
    - 3.6K bytes
    - Viewed (0)
  3. cmd/lock-rest-server-common.go

    // along with this program.  If not, see <http://www.gnu.org/licenses/>.
    
    package cmd
    
    import (
    	"errors"
    )
    
    var (
    	errLockConflict       = errors.New("lock conflict")
    	errLockNotInitialized = errors.New("lock not initialized")
    	errLockNotFound       = errors.New("lock not found")
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue Nov 21 01:09:35 UTC 2023
    - 973 bytes
    - Viewed (0)
  4. src/main/java/jcifs/internal/smb2/lock/Smb2LockRequest.java

        private byte[] fileId;
        private final Smb2Lock[] locks;
    
    
        /**
         * @param config
         * @param fileId
         * @param locks
         */
        public Smb2LockRequest ( Configuration config, byte[] fileId, Smb2Lock[] locks ) {
            super(config, SMB2_LOCK);
            this.fileId = fileId;
            this.locks = locks;
        }
    
    
        /**
         * {@inheritDoc}
         *
    Registered: Sun Nov 03 00:10:13 UTC 2024
    - Last Modified: Sun Jul 01 13:12:10 UTC 2018
    - 3.4K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/util/concurrent/TestThread.java

     * method equivalent to {@link
     * java.util.concurrent.locks.ReentrantLock#hasWaiters(java.util.concurrent.locks.Condition)},
     * except that the method parameter must accept whatever condition-like object is passed into {@code
     * callAndAssertWaits} by the test.
     *
     * @param <L> the type of the lock-like object to be used
     * @author Justin T. Sampson
     */
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 22:10:29 UTC 2024
    - 10.7K bytes
    - Viewed (0)
  6. internal/dsync/drwmutex_test.go

    	}
    	// fmt.Println("Write lock failed due to timeout")
    	return
    }
    
    func TestSimpleWriteLockAcquired(t *testing.T) {
    	locked := testSimpleWriteLock(t, 10*testDrwMutexAcquireTimeout)
    
    	expected := true
    	if locked != expected {
    		t.Errorf("TestSimpleWriteLockAcquired(): \nexpected %#v\ngot      %#v", expected, locked)
    	}
    }
    
    func TestSimpleWriteLockTimedOut(t *testing.T) {
    	locked := testSimpleWriteLock(t, testDrwMutexAcquireTimeout)
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sat Dec 24 03:49:07 UTC 2022
    - 9.7K bytes
    - Viewed (0)
  7. internal/ringbuffer/ring_buffer.go

    	go func() {
    		select {
    		case <-ctx.Done():
    			r.CloseWithError(ctx.Err())
    		}
    	}()
    	return r
    }
    
    func (r *RingBuffer) setErr(err error, locked bool) error {
    	if !locked {
    		r.mu.Lock()
    		defer r.mu.Unlock()
    	}
    	if r.err != nil && r.err != io.EOF {
    		return r.err
    	}
    
    	switch err {
    	// Internal errors are transient
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed May 15 00:11:04 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  8. docs/contribute/concurrency.md

    ### Locks
    
    We have 3 different things that we synchronize on.
    
    #### Http2Connection
    
    This lock guards internal state of each connection. This lock is never held for blocking operations. That means that we acquire the lock, read or write a few fields and release the lock. No I/O and no application-layer callbacks.
    
    #### Http2Stream
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Feb 06 16:35:36 UTC 2022
    - 7K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/util/concurrent/StripedTest.java

            }
          };
    
      private static final Supplier<Lock> LOCK_SUPPLER =
          new Supplier<Lock>() {
            @Override
            public Lock get() {
              return new ReentrantLock();
            }
          };
    
      private static final Supplier<Lock> FAIR_LOCK_SUPPLER =
          new Supplier<Lock>() {
            @Override
            public Lock get() {
              return new ReentrantLock(true);
            }
          };
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Jun 26 12:58:35 UTC 2024
    - 8.4K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/util/concurrent/StripedTest.java

            }
          };
    
      private static final Supplier<Lock> LOCK_SUPPLER =
          new Supplier<Lock>() {
            @Override
            public Lock get() {
              return new ReentrantLock();
            }
          };
    
      private static final Supplier<Lock> FAIR_LOCK_SUPPLER =
          new Supplier<Lock>() {
            @Override
            public Lock get() {
              return new ReentrantLock(true);
            }
          };
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Jun 26 12:58:35 UTC 2024
    - 8.4K bytes
    - Viewed (0)
Back to top