Tabnine Logo
Contended
Code IndexAdd Tabnine to your IDE (free)

How to use
Contended
in
sun.misc

Best Java code snippets using sun.misc.Contended (Showing top 20 results out of 315)

Tip from Codota:

Notice
Guided by Codota

Some sun.misc internal APIs are deprectaed in JDK 9 and will be encapsulated or removed in a future release.

origin: ehcache/ehcache3

 /**
  * A padded cell for distributing counts.  Adapted from LongAdder
  * and Striped64.  See their internal docs for explanation.
  */
 @sun.misc.Contended
static final class CounterCell {
   volatile long value;
   CounterCell(long x) { value = x; }
 }
origin: bluestreak01/questdb

/**
 * A padded cell for distributing counts.  Adapted from LongAdder
 * and Striped64.  See their internal docs for explanation.
 */
@sun.misc.Contended
static final class CounterCell {
  final long value;
  CounterCell(long x) {
    value = x;
  }
}
origin: org.ehcache/ehcache

 /**
  * A padded cell for distributing counts.  Adapted from LongAdder
  * and Striped64.  See their internal docs for explanation.
  */
 @sun.misc.Contended
static final class CounterCell {
   volatile long value;
   CounterCell(long x) { value = x; }
 }
origin: org.jboss.eap/wildfly-client-all

@Contended
abstract static class QNode {
  // in 9, use VarHandle
  private static final AtomicReferenceFieldUpdater<QNode, QNode> nextUpdater = AtomicReferenceFieldUpdater.newUpdater(QNode.class, QNode.class, "next");
  @SuppressWarnings("unused")
  private volatile QNode next;
  QNode(final QNode next) {
    this.next = next;
  }
  boolean compareAndSetNext(QNode expect, QNode update) {
    return nextUpdater.compareAndSet(this, expect, update);
  }
  QNode getNext() {
    return nextUpdater.get(this);
  }
  QNode getAndSetNext(final QNode node) {
    return nextUpdater.getAndSet(this, node);
  }
}
origin: org.jboss.eap/wildfly-client-all

@Contended
static final class TaskNode extends QNode {
  volatile Runnable task;
  TaskNode(final Runnable task) {
    // we always start task nodes with a {@code null} next
    super(null);
    this.task = task;
  }
  Runnable getAndClearTask() {
    try {
      return task;
    } finally {
      this.task = null;
    }
  }
}
origin: arteam/100-Java-Concurrency-questions

public class ContentedPoint {

  @Contended
  private long x;

  private long y;

  public ContentedPoint(long x, long y) {
    this.x = x;
    this.y = y;
  }

  public long getX() {
    return x;
  }

  public void setX(long x) {
    this.x = x;
  }

  public long getY() {
    return y;
  }

  public void setY(long y) {
    this.y = y;
  }
}

origin: org.jboss.eap/wildfly-client-all

@Contended
static final class TerminateWaiterNode extends QNode {
  private volatile Thread thread;
  TerminateWaiterNode(final Thread thread) {
    // always start with a {@code null} next
    super(null);
    this.thread = thread;
  }
  Thread getAndClearThread() {
    // doesn't have to be particularly atomic
    try {
      return thread;
    } finally {
      thread = null;
    }
  }
  TerminateWaiterNode getNext() {
    return (TerminateWaiterNode) super.getNext();
  }
}
origin: org.jboss.eap/wildfly-client-all

@Contended
static final class PoolThreadNode extends QNode {
  private final Thread thread;
  @SuppressWarnings("unused")
  private volatile Runnable task;
  private static final AtomicReferenceFieldUpdater<PoolThreadNode, Runnable> taskUpdater = AtomicReferenceFieldUpdater.newUpdater(PoolThreadNode.class, Runnable.class, "task");
  PoolThreadNode(final PoolThreadNode next, final Thread thread) {
    super(next);
    this.thread = thread;
    task = WAITING;
  }
  Thread getThread() {
    return thread;
  }
  boolean compareAndSetTask(final Runnable expect, final Runnable update) {
    return taskUpdater.compareAndSet(this, expect, update);
  }
  Runnable getTask() {
    return taskUpdater.get(this);
  }
  PoolThreadNode getNext() {
    return (PoolThreadNode) super.getNext();
  }
}
origin: io.kamon/kamon-core

@sun.misc.Contended static final class Cell {
  volatile long value;
  Cell(long x) { value = x; }
origin: io.kamon/kamon-core_2.12

@sun.misc.Contended static final class Cell {
  volatile long value;
  Cell(long x) { value = x; }
origin: apache/tajo

private static class RadixSortContext {
 @Contended UnSafeTuple[] in;
 @Contended UnSafeTuple[] out;
 @Contended final int[] keys;
origin: zolyfarkas/spf4j

@Contended
private volatile LogConfigConsumer cfgConsumer;
origin: arnohaase/a-foundation

@Contended
class SharedQueueBlockPushBlockPopImpl implements ASharedQueue {
  long p1, p2, p3, p4, p5, p6, p7;
origin: arnohaase/a-foundation

@Contended
class SharedQueueNonBlockingImpl implements ASharedQueue {
  long p1, p2, p3, p4, p5, p6, p7;
origin: dmart28/reveno

@Contended
private long time = 0L;
public long time() {
@Contended
private boolean skipViews = false;
public boolean isSkipViews() {
@Contended
private long systemFlag = 0L;
public long systemFlag() {
@Contended
private long transactionId; 
public long transactionId() {
@Contended
private CompletableFuture future;
public CompletableFuture future() {
@Contended
private boolean hasResult;
public boolean hasResult() {
@Contended
private Object commandResult;
public Object commandResult() {
@Contended
origin: arnohaase/a-foundation

@Contended
class LocalQueue {
  long p1, p2, p3, p4, p5, p6, p7;
origin: arnohaase/a-foundation

@Contended
class SharedQueueNonblockPushBlockPopImpl implements ASharedQueue {
  long p1, p2, p3, p4, p5, p6, p7;
origin: eclipse-ee4j/jersey

@sun.misc.Contended
private static final class BufferedSubscription<T>
    implements Flow.Subscription, ForkJoinPool.ManagedBlocker {
origin: arnohaase/a-foundation

@Contended
class WorkerThread extends Thread {
  long a1, a2, a3, a4, a5, a6, a7;
origin: arnohaase/a-foundation

@Contended
public class AThreadPoolImpl implements AThreadPoolWithAdmin {
  private static final int MAX_NUM_PRODUCER_AFFINITIES = 10_000;
sun.miscContended

Most used methods

  • <init>

Popular in Java

  • Reactive rest calls using spring rest template
  • requestLocationUpdates (LocationManager)
  • getSharedPreferences (Context)
  • startActivity (Activity)
  • GridBagLayout (java.awt)
    The GridBagLayout class is a flexible layout manager that aligns components vertically and horizonta
  • ConnectException (java.net)
    A ConnectException is thrown if a connection cannot be established to a remote host on a specific po
  • Path (java.nio.file)
  • ThreadPoolExecutor (java.util.concurrent)
    An ExecutorService that executes each submitted task using one of possibly several pooled threads, n
  • LogFactory (org.apache.commons.logging)
    Factory for creating Log instances, with discovery and configuration features similar to that employ
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Top plugins for WebStorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now