Tabnine Logo
Segment.getId
Code IndexAdd Tabnine to your IDE (free)

How to use
getId
method
in
org.apache.druid.segment.Segment

Best Java code snippets using org.apache.druid.segment.Segment.getId (Showing top 6 results out of 315)

origin: apache/incubator-druid

@Override
public SegmentId getId()
{
 return !isClosed() ? baseSegment.getId() : null;
}
origin: apache/incubator-druid

 @Override
 protected boolean onAdvance(int phase, int registeredParties)
 {
  Preconditions.checkState(registeredParties == 0);
  // Ensure that onAdvance() doesn't throw exception, otherwise termination won't happen
  try {
   baseSegment.close();
  }
  catch (Exception e) {
   try {
    log.error(e, "Exception while closing segment[%s]", baseSegment.getId());
   }
   catch (Exception e2) {
    // ignore
   }
  }
  // Always terminate.
  return true;
 }
};
origin: apache/incubator-druid

public void swapSegment(@Nullable Segment newSegment)
{
 while (true) {
  ReferenceCountingSegment currentSegment = adapter.get();
  if (currentSegment == null && newSegment == null) {
   return;
  }
  if (currentSegment != null && newSegment != null &&
    !newSegment.getId().equals(currentSegment.getId())) {
   // Sanity check: identifier should not change
   throw new ISE(
     "WTF?! Cannot swap identifier[%s] -> [%s]!",
     currentSegment.getId(),
     newSegment.getId()
   );
  }
  if (currentSegment == newSegment) {
   throw new ISE("Cannot swap to the same segment");
  }
  ReferenceCountingSegment newReferenceCountingSegment =
    newSegment != null ? new ReferenceCountingSegment(newSegment) : null;
  if (adapter.compareAndSet(currentSegment, newReferenceCountingSegment)) {
   if (currentSegment != null) {
    currentSegment.close();
   }
   index = null;
   return;
  }
 }
}
origin: apache/incubator-druid

Preconditions.checkArgument(intervals.size() == 1, "Can only handle a single interval, got[%s]", intervals);
final SegmentId segmentId = segment.getId();
origin: apache/incubator-druid

Collections.singletonList(
  new SegmentAnalysis(
    segment.getId().toString(),
    retIntervals,
    columns,
origin: apache/incubator-druid

final String segmentId = segment.getId().withInterval(intervals.get(0)).toString();
org.apache.druid.segmentSegmentgetId

Popular methods of Segment

  • getDataInterval
  • asQueryableIndex
  • getIdentifier
  • as
    Request an implementation of a particular interface. If the passed-in interface is QueryableIndex or
  • asStorageAdapter
  • close

Popular in Java

  • Making http post requests using okhttp
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • getApplicationContext (Context)
  • getSupportFragmentManager (FragmentActivity)
  • FileInputStream (java.io)
    An input stream that reads bytes from a file. File file = ...finally if (in != null) in.clos
  • Thread (java.lang)
    A thread is a thread of execution in a program. The Java Virtual Machine allows an application to ha
  • BigInteger (java.math)
    An immutable arbitrary-precision signed integer.FAST CRYPTOGRAPHY This implementation is efficient f
  • Proxy (java.net)
    This class represents proxy server settings. A created instance of Proxy stores a type and an addres
  • SocketTimeoutException (java.net)
    This exception is thrown when a timeout expired on a socket read or accept operation.
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • Best IntelliJ plugins
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