Examples of snapshot()


Examples of akka.persistence.SnapshotOffer.snapshot()

            if (isPersistent()) {
                numReplicated += 1;
                System.out.println(String.format("view received %s (num replicated = %d)", message, numReplicated));
            } else if (message instanceof SnapshotOffer) {
                SnapshotOffer so = (SnapshotOffer)message;
                numReplicated = (Integer)so.snapshot();
                System.out.println(String.format("view received snapshot offer %s (metadata = %s)", numReplicated, so.metadata()));
            } else if (message.equals("snap")) {
                saveSnapshot(numReplicated);
            } else {
              unhandled(message);
View Full Code Here

Examples of ariba.ui.meta.core.Context.snapshot()

        // register validation callback if necessary
        Boolean editing = (Boolean)context.propertyForKey(UIMeta.KeyEditing);
        if (editing != null && editing.booleanValue()) {
            _object = context.values().get("object");
            _contextSnapshot = context.snapshot();
            // ToDo: Need to change error manager not to add dups
            errorManager().registerFullValidationHandler(this);
        }
    }
View Full Code Here

Examples of com.espertech.esper.epl.named.NamedWindowTailViewInstance.snapshot()

                        if (preload) {
                            final boolean yesRecoveringResilient = isRecoveringResilient;
                            final FilterSpecCompiled preloadFilterSpec = namedWindowPostloadFilters[i];
                            preloadList.add(new StatementAgentInstancePreload() {
                                public void executePreload() {
                                    Collection<EventBean> snapshot = consumerView.snapshot(preloadFilterSpec, statementContext.getAnnotations());
                                    List<EventBean> eventsInWindow = new ArrayList<EventBean>(snapshot.size());
                                    ExprNodeUtility.applyFilterExpressionsIterable(snapshot, namedSpec.getFilterExpressions(), agentInstanceContext, eventsInWindow);
                                    EventBean[] newEvents = eventsInWindow.toArray(new EventBean[eventsInWindow.size()]);
                                    view.update(newEvents, null);
                                    if (!yesRecoveringResilient && joinPreloadMethod != null && !joinPreloadMethod.isPreloading() && agentInstanceContext.getEpStatementAgentInstanceHandle().getOptionalDispatchable() != null) {
View Full Code Here

Examples of com.facebook.presto.jdbc.internal.guava.cache.AbstractCache.SimpleStatsCounter.snapshot()

      SimpleStatsCounter aggregator = new SimpleStatsCounter();
      aggregator.incrementBy(localCache.globalStatsCounter);
      for (Segment<K, V> segment : localCache.segments) {
        aggregator.incrementBy(segment.statsCounter);
      }
      return aggregator.snapshot();
    }

    @Override
    public void cleanUp() {
      localCache.cleanUp();
View Full Code Here

Examples of com.google.common.cache.AbstractCache.SimpleStatsCounter.snapshot()

      SimpleStatsCounter aggregator = new SimpleStatsCounter();
      aggregator.incrementBy(localCache.globalStatsCounter);
      for (Segment<K, V> segment : localCache.segments) {
        aggregator.incrementBy(segment.statsCounter);
      }
      return aggregator.snapshot();
    }

    @Override
    public void cleanUp() {
      localCache.cleanUp();
View Full Code Here

Examples of com.google.common.cache.AbstractCache.SimpleStatsCounter.snapshot()

      SimpleStatsCounter aggregator = new SimpleStatsCounter();
      aggregator.incrementBy(localCache.globalStatsCounter);
      for (Segment<K, V> segment : localCache.segments) {
        aggregator.incrementBy(segment.statsCounter);
      }
      return aggregator.snapshot();
    }

    @Override
    public void cleanUp() {
      localCache.cleanUp();
View Full Code Here

Examples of com.google.common.cache.AbstractCache.StatsCounter.snapshot()

    assertEquals(toInvalidate, invalidated);
  }

  public void testEmptySimpleStats() {
    StatsCounter counter = new SimpleStatsCounter();
    CacheStats stats = counter.snapshot();
    assertEquals(0, stats.requestCount());
    assertEquals(0, stats.hitCount());
    assertEquals(1.0, stats.hitRate());
    assertEquals(0, stats.missCount());
    assertEquals(0.0, stats.missRate());
View Full Code Here

Examples of com.google_voltpatches.common.cache.AbstractCache.SimpleStatsCounter.snapshot()

      SimpleStatsCounter aggregator = new SimpleStatsCounter();
      aggregator.incrementBy(localCache.globalStatsCounter);
      for (Segment<K, V> segment : localCache.segments) {
        aggregator.incrementBy(segment.statsCounter);
      }
      return aggregator.snapshot();
    }

    @Override
    public void cleanUp() {
      localCache.cleanUp();
View Full Code Here

Examples of com.hp.hpl.jena.util.MonitorGraph.snapshot()

        base.add(t3);
       
        // Test changes from empty
        List<Triple> additions = new ArrayList<>();
        List<Triple> deletions = new ArrayList<>();
        monitor.snapshot(additions, deletions);
        TestUtil.assertIteratorValues(this, additions.iterator(), new Object[] {t1, t2, t3});
        TestUtil.assertIteratorValues(this, deletions.iterator(), new Object[] {});
       
        // Make some new changes
        base.add(t4);
View Full Code Here

Examples of com.hp.hpl.jena.util.MonitorModel.snapshot()

        base.add(s3);
       
        // Test changes from empty
        List<Statement> additions = new ArrayList<>();
        List<Statement> deletions = new ArrayList<>();
        monitor.snapshot(additions, deletions);
        TestUtil.assertIteratorValues(this, additions.iterator(), new Object[] {s1, s2, s3});
        TestUtil.assertIteratorValues(this, deletions.iterator(), new Object[] {});
        listener.assertHas(new Object[] {"addList", additions, "removeList", deletions});
        listener.clear();
       
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.