Examples of AbstractKernelRunnable


Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

      /*
       * Check service version.
       */
      transactionScheduler.runTask(
    new AbstractKernelRunnable("CheckServiceVersion") {
        public void run() {
      checkServiceVersion(
          VERSION_KEY, MAJOR_VERSION, MINOR_VERSION);
        } },  taskOwner);

View Full Code Here

Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

    private void notifyNodeListeners(final Node node) {

  for (NodeListener listener : nodeListeners.keySet()) {
      final NodeListener nodeListener = listener;
      taskScheduler.scheduleTask(
    new AbstractKernelRunnable("NotifyNodeListeners") {
        public void run() {
      if (!shuttingDown() &&
                            isLocalNodeAliveNonTransactional())
      {
          if (node.isAlive()) {
View Full Code Here

Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

      final RecoveryListener recoveryListener = listener;
      final RecoveryCompleteFuture future =
    new RecoveryCompleteFutureImpl(node, listener);
      futureQueue.add(future);
      taskScheduler.scheduleTask(
    new AbstractKernelRunnable("NotifyRecoveryListeners") {
        public void run() {
      try {
          if (!shuttingDown() &&
        isLocalNodeAliveNonTransactional())
          {
View Full Code Here

Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

      final long coord = coordNodeId;
      final ChannelServiceImpl channelService =
    ChannelServiceImpl.getChannelService();
      final BigInteger channelRefId = eventQueue.getChannelRefId();
      channelService.getTaskService().scheduleNonDurableTask(
          new AbstractKernelRunnable("SendServiceEventQueue") {
      public void run() {
          channelService.runIoTask(
       new IoRunnable() {
        public void run() throws IOException {
            coordinator.serviceEventQueue(channelRefId);
View Full Code Here

Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

  /*
   * Check service version.
   */
  transactionScheduler.runTask(
      new AbstractKernelRunnable("CheckServiceVersion") {
    public void run() {
        checkServiceVersion(
      VERSION_KEY, MAJOR_VERSION, MINOR_VERSION);
    } },  taskOwner);
 
View Full Code Here

Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

  // Mark all nodes failed and notify all clients (except local one)
  // of failure.
  final Collection<NodeImpl> failedNodes = aliveNodes.values();
  try {
      transactionScheduler.runTask(
        new AbstractKernelRunnable("MarkAllNodesFailed") {
    public void run() {
        for (NodeImpl node : failedNodes) {
      node.setFailed(dataService, null);
        }
    } }, taskOwner);
View Full Code Here

Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

            }
           
      // Persist node
      try {
    transactionScheduler.runTask(
      new AbstractKernelRunnable("StoreNewNode") {
        public void run() {
      node.putNode(dataService);
        } }, taskOwner);
      } catch (Exception e) {
                aliveNodes.remove(nodeId);
View Full Code Here

Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

      try {
    // TBD: should the node be removed if the current
    // backup ID for the node with the given node ID
    // is not the given backup ID?
    transactionScheduler.runTask(
      new AbstractKernelRunnable("RemoveRecoveredNode") {
        public void run() {
      NodeImpl.removeNode(dataService,  nodeId);
        } }, taskOwner);
      } catch (Exception e) {
    logger.logThrow(
View Full Code Here

Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

   * Persists node and backup status updates in data service.
   */
  private void assignBackup(final NodeImpl node, final NodeImpl backup) {
      try {
    transactionScheduler.runTask(
        new AbstractKernelRunnable("SetNodeFailed") {
      public void run() {
          node.setFailed(dataService, backup);
          if (backup != null) {
        backup.addPrimary(dataService, node.getId());
          }
View Full Code Here

Examples of com.sun.sgs.impl.util.AbstractKernelRunnable

    // Management support
    private NodeInfo[] getAllNodeInfo() {
        final Set<NodeInfo> nodes = new HashSet<NodeInfo>();
        try {
            transactionScheduler.runTask(
                new AbstractKernelRunnable("GetNodeInfo") {
                    public void run() {
                        Iterator<Node> iter = NodeImpl.getNodes(dataService);
                        while (iter.hasNext()) {
                            NodeImpl node = (NodeImpl) iter.next();
                            nodes.add(node.getNodeInfo());
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.