Tabnine Logo
ThreadLocalDirectory.update
Code IndexAdd Tabnine to your IDE (free)

How to use
update
method
in
com.yahoo.concurrent.ThreadLocalDirectory

Best Java code snippets using com.yahoo.concurrent.ThreadLocalDirectory.update (Showing top 3 results out of 315)

origin: com.yahoo.vespa/vespajlib

/**
 * Input data from a producer thread.
 *
 * @param x
 *            the data to insert
 */
public void update(SAMPLE x) {
  update(x, getOrCreateLocal());
}
origin: com.yahoo.vespa/simplemetrics

/**
 * Update a metric. This API is not intended for clients for the
 * simplemetrics API, declare a Counter or a Gauge using
 * {@link #declareCounter(String)}, {@link #declareCounter(String, Point)},
 * {@link #declareGauge(String)}, or {@link #declareGauge(String, Point)}
 * instead.
 *
 * @param s
 *            a single simple containing all meta data necessary to update a
 *            metric
 */
public void update(Sample s) {
  // pass around the receiver instead of histogram settings to avoid reading any volatile if unnecessary
  s.setReceiver(this);
  metricsCollection.update(s);
}
origin: com.yahoo.vespa/container-search

@Override
public Result search(Query query, Execution execution) {
  Result r;
  long when = query.getStartTime() / 1000L;
  Hit meta = null;
  directory.update(when);
  if (useMetaHit) {
    if (query.properties().getBoolean(propertyName, false)) {
      List<QueryRatePerSecond> l = merge(directory.fetch());
      Tuple2<Integer, Double> maxAndMean = maxAndMean(l);
      meta = new QpsHit(maxAndMean.first, maxAndMean.second);
    }
  }
  r = execution.search(query);
  if (meta != null) {
    r.hits().add(meta);
  }
  return r;
}
com.yahoo.concurrentThreadLocalDirectoryupdate

Javadoc

Input data from a producer thread.

Popular methods of ThreadLocalDirectory

  • <init>
  • fetch
    Fetch the current set of sampled data, and reset state of all thread local instances. The producer t
  • getOrCreateLocal
  • put

Popular in Java

  • Updating database using SQL prepared statement
  • scheduleAtFixedRate (Timer)
  • runOnUiThread (Activity)
  • getSupportFragmentManager (FragmentActivity)
  • Table (com.google.common.collect)
    A collection that associates an ordered pair of keys, called a row key and a column key, with a sing
  • PrintWriter (java.io)
    Wraps either an existing OutputStream or an existing Writerand provides convenience methods for prin
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • LinkedHashMap (java.util)
    LinkedHashMap is an implementation of Map that guarantees iteration order. All optional operations a
  • Properties (java.util)
    A Properties object is a Hashtable where the keys and values must be Strings. Each property can have
  • JLabel (javax.swing)
  • 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