Remove the ready consumer from our ready 'lists'

@param consumerKey - handle to the ready consumer
@param bSelector - consumer has a selector or not
356846
@Override
    public void removeReadyConsumer(JSConsumerKey consumerKey, boolean bSelector)
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(tc, "removeReadyConsumer",
                        new Object[] { consumerKey, Boolean.valueOf(bSelector) });

        if (consumerKey == null)
        {
            SIErrorException e =
                            new SIErrorException(
                                            nls.getFormattedMessage(
                                                                    "INTERNAL_MESSAGING_ERROR_CWSIP0001",
                                                                    new Object[] {
                                                                                  "com.ibm.ws.sib.processor.impl.ConsumerDispatcher",
                                                                                  "1:1684:1.280.5.25" },
                                                                    null));

            FFDCFilter.processException(
                                        e,
                                        "com.ibm.ws.sib.processor.impl.ConsumerDispatcher.removeReadyConsumer",
                                        "1:1690:1.280.5.25",
                                        this);

            SibTr.exception(tc, e);

            SibTr.error(tc, "INTERNAL_MESSAGING_ERROR_CWSIP0001",
                        new Object[] {
                                      "com.ibm.ws.sib.processor.impl.ConsumerDispatcher",
                                      "1:1698:1.280.5.25" });

            if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
                SibTr.exit(tc, "removeReadyConsumer", e);

            throw e;
        }

        if (consumerKey.getForwardScanning())
        {
            //remove the consumer point from the FS ready list
            ((SimpleEntry) consumerKey).remove();
        }
        else
        {
            if (bSelector)
            {
                //decrement the specific ready consumer counter
                specificReadyConsumerCount--;

                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                    SibTr.debug(tc, "sepcificReadyConsumerCount:" + specificReadyConsumerCount);
            }
            else
            {
                //remove the consumer point from the ready list
                ((SimpleEntry) consumerKey).remove();
            }
        }

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(tc, "removeReadyConsumer");
    }
614761
public void attachMessage(ConsumableKey consumerKey)
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
    {
      SibTr.entry(tc, "attachMessage", msgAttachedMember);
      SibTr.exit(tc, "attachMessage", consumerKey);
    }
    if(msgAttachedMember == null)
      msgAttachedMember = consumerKey;
    else
    {
      // We already have a message attached
      if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.exit(tc, "attachMessage", "SIErrorException");
        throw new SIErrorException(
          nls.getFormattedMessage(
            "INTERNAL_MESSAGING_ERROR_CWSIP0001",
            new Object[] {
              "com.ibm.ws.sib.processor.impl.LocalQPConsumerKeyGroup",
              "1:1027:1.6.1.14" },
            null));
    }
  }
1315737
public void removeCache(Object dataKey) {
		if (dataKey == null)
			return;
		try {
			for (Object o : cache.keySet()) {
				String key = (String) o;
				Object cachedValue = (Object) cache.get(key);
				if (cachedValue instanceof CacheableWrapper) {
					CacheableWrapper cw = (CacheableWrapper) cachedValue;
					if (cw.getCachedValueKey().equals(dataKey.toString()))
						removeObect(key);
				}
			}
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
465623
public synchronized void remove(Object key) {
        Object victim = null;
        if (cacheEvictionListenerSet.isEmpty() == false) {
            victim = get(key);
        }

        primaryTable.remove(key);
        secondaryTable.remove(key);
        tertiaryTable.remove(key);

        if (victim != null) {
            ArrayList<Object> evictedValues = new ArrayList<Object>();
            evictedValues.add(victim);
            for (CacheEvictionListener evictionCallback : cacheEvictionListenerSet) {
                evictionCallback.evicted(evictedValues);
            }
        }
    }
322413
def _recv_cancel(self, method_frame):
        '''
        '''
        self.logger.warning("consumer cancelled by broker: %r", method_frame)

        consumer_tag = method_frame.args.read_shortstr()

        # NOTE: per RabbitMQ spec, no-wait is always true in Basic.Cancel from
        # broker

        # Remove consumer from this basic instance
        try:
            cancel_cb = self._broker_cancel_cb_map.pop(consumer_tag)
        except KeyError:
            # Must be a race condition between user's cancel and broker's cancel
            self.logger.warning(
                '_recv_cancel: no broker-cancel-cb entry for consumer tag %r',
                consumer_tag)
        else:
            if callable(cancel_cb):
                # Purge from base class only when user supplies cancel_cb
                self._purge_consumer_by_tag(consumer_tag)

                # Notify user
                cancel_cb(consumer_tag)
901428
public function deleteConsumer ( $consumer_key, $user_id, $user_is_admin = false )
	{
		
                //
                $sql = "BEGIN SP_DELETE_CONSUMER(:P_CONSUMER_KEY, :P_USER_ID, :P_USER_IS_ADMIN, :P_RESULT); END;";

                // parse sql
                $stmt = oci_parse($this->conn, $sql) or die ('Can not parse query');

                // Bind In and Out Variables
                oci_bind_by_name($stmt, ':P_CONSUMER_KEY', $consumer_key, 255);
                oci_bind_by_name($stmt, ':P_USER_ID', $user_id, 40);
                oci_bind_by_name($stmt, ':P_USER_IS_ADMIN', $user_is_admin, 40);
                oci_bind_by_name($stmt, ':P_RESULT', $result, 20);               

                //Execute the statement
                oci_execute($stmt);
                //
        }
935428
void removeConsumerSession(ConsumerSessionImpl consumer)
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(tc, "removeConsumerSession", consumer);

        synchronized (_consumers)
        {
            _consumers.remove(consumer);
        }

        _messageProcessor.removeConsumer(consumer);

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(tc, "removeConsumerSession");
    }
80453
@Override
	protected final void onConsumerClose()
    {
    	super.onConsumerClose();
    	
    	// Unregister the consumer from the associated destination
    	unregister();
    	
    	try
    	{
    		engine.getDeliveryAsyncTaskManager().cancelTask(wakeUpAsyncTask);
    	}
    	catch (JMSException e)
    	{
    		ErrorTools.log(e, log);
    	}
    }
672422
synchronized void remove(ConsumerSessionImpl consumer)
  {
    if (tc.isEntryEnabled())
      SibTr.entry(tc, "remove", consumer );
      
    _consumers.remove(new Long(consumer.getIdInternal()));
    
    if (tc.isEntryEnabled())
      SibTr.exit(tc, "remove");    
  }
904863
@SuppressWarnings("unchecked")
    public void forEach(final EntryConsumer<V> consumer)
    {
        for (int i = 0, size = values.length; i < size; i++)
        {
            final Object value = values[i];
            if (null != value)
            {
                final long compoundKey = keys[i];
                final int keyPartA = (int)(compoundKey >>> 32);
                final int keyPartB = (int)(compoundKey & 0xFFFF_FFFFL);

                consumer.accept(keyPartA, keyPartB, (V)value);
            }
        }
    }
961125
public void removeConsumerListForExpression(
    String topicExpression,
    boolean selector,
    boolean isWildcarded)
  {
    if (tc.isEntryEnabled()) 
      SibTr.entry(tc, 
                  "removeConsumerListForExpression", 
                  new Object[]{topicExpression, 
                               new Boolean(selector),
                               new Boolean(isWildcarded)});

    if(selector)
    {
      if(isWildcarded)
      {
        // Selector and wildcarded
        ArrayList consumerList = (ArrayList)_wildcardSelectorSubs.remove(topicExpression);
        if(consumerList == null)
        {
          // Couldn't find the consumerlist. This means we have an internal 
          // inconsistency in our tables, so throw an SIErrorException
          
          // Build the message for the Exception
          if (tc.isEntryEnabled()) 
            SibTr.exit(tc, "removeConsumerListForExpression", topicExpression);
      
          SibTr.error(tc, "INTERNAL_MESSAGING_ERROR_CWSIP0005",
            new Object[] {
              "com.ibm.ws.sib.processor.matching.SubscriptionRegistrar",
              "1:265:1.5",
              topicExpression });  
          throw new SIErrorException(
            nls.getFormattedMessage(
              "INTERNAL_MESSAGING_ERROR_CWSIP0005",
              new Object[] {
                "com.ibm.ws.sib.processor.matching.SubscriptionRegistrar",
                "1:272:1.5",
                topicExpression },
              null));                       
        }                          
        // Test whether table is now empty
        if(_wildcardSelectorSubs.isEmpty())
          _areWildcardSelectorSubs = false;
      }
      else
      {
        // Selector but not wildcarded
        ArrayList consumerList = (ArrayList)_exactSelectorSubs.remove(topicExpression);
        if(consumerList == null)
        {
          // Couldn't find the consumerlist. This means we have an internal 
          // inconsistency in our tables, so throw an SIErrorException
        
          // Build the message for the Exception
          if (tc.isEntryEnabled()) 
            SibTr.exit(tc, "removeConsumerListForExpression", topicExpression);
      
          SibTr.error(tc, "INTERNAL_MESSAGING_ERROR_CWSIP0005",
            new Object[] {
              "com.ibm.ws.sib.processor.matching.SubscriptionRegistrar",
              "1:296:1.5",
              topicExpression });  
          throw new SIErrorException(
            nls.getFormattedMessage(
              "INTERNAL_MESSAGING_ERROR_CWSIP0005",
              new Object[] {
                "com.ibm.ws.sib.processor.matching.SubscriptionRegistrar",
                "1:303:1.5",
                topicExpression },
              null));                       
        }                  
        // Test whether table is now empty
        if(_exactSelectorSubs.isEmpty())
          _areExactSelectorSubs = false;
      }
    }
    else
    {
      // No Selector expression
      if(isWildcarded)
      {
        // No selector and wildcarded
        ArrayList consumerList = (ArrayList)_wildcardNonSelectorSubs.remove(topicExpression);
        if(consumerList == null)
        {
          // Couldn't find the consumerlist. This means we have an internal 
          // inconsistency in our tables, so throw an SIErrorException
        
          // Build the message for the Exception
          if (tc.isEntryEnabled()) 
            SibTr.exit(tc, "removeConsumerListForExpression", topicExpression);
      
          SibTr.error(tc, "INTERNAL_MESSAGING_ERROR_CWSIP0005",
            new Object[] {
              "com.ibm.ws.sib.processor.matching.SubscriptionRegistrar",
              "1:331:1.5",
              topicExpression });  
          throw new SIErrorException(
            nls.getFormattedMessage(
              "INTERNAL_MESSAGING_ERROR_CWSIP0005",
              new Object[] {
                "com.ibm.ws.sib.processor.matching.SubscriptionRegistrar",
                "1:338:1.5",
                topicExpression },
              null));                       
        }                       
        // Test whether table is now empty
        if(_wildcardNonSelectorSubs.isEmpty())
          _areWildcardNonSelectorSubs = false;        
      }
      else
      {
        // No selector and not wildcarded
        ArrayList consumerList = (ArrayList)_exactNonSelectorSubs.remove(topicExpression);
        if(consumerList == null)
        {
          // Couldn't find the consumerlist. This means we have an internal 
          // inconsistency in our tables, so throw an SIErrorException
        
          // Build the message for the Exception
          if (tc.isEntryEnabled()) 
            SibTr.exit(tc, "removeConsumerListForExpression", topicExpression);
      
          SibTr.error(tc, "INTERNAL_MESSAGING_ERROR_CWSIP0005",
            new Object[] {
              "com.ibm.ws.sib.processor.matching.SubscriptionRegistrar",
              "1:362:1.5",
              topicExpression });  
          throw new SIErrorException(
            nls.getFormattedMessage(
              "INTERNAL_MESSAGING_ERROR_CWSIP0005",
              new Object[] {
                "com.ibm.ws.sib.processor.matching.SubscriptionRegistrar",
                "1:369:1.5",
                topicExpression },
              null));                       
        }                            
        // Test whether table is now empty
        if(_exactNonSelectorSubs.isEmpty())
          _areExactNonSelectorSubs = false;        
      }      
    }           
    if (tc.isEntryEnabled()) SibTr.exit(tc, "removeConsumerListForExpression");
  }
202867
public boolean removeReference(K key, ServiceReference<V> reference) {
        if (key == null || reference == null)
            return false;
        ConcurrentServiceReferenceElement<V> element = new ConcurrentServiceReferenceElement<V>(referenceName, reference);
        return elementMap.remove(key, element);
    }
1033207
public void removeConsumerPointMatchTarget(DispatchableKey consumerPointData)
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.entry(tc, "removeConsumerPointMatchTarget", consumerPointData);

    // Remove the consumer point from the matchspace
    try
    {
      removeTarget(consumerPointData);
    }
    catch (MatchingException e)
    {
      // FFDC
      FFDCFilter.processException(
        e,
        "com.ibm.ws.sib.processor.matching.MessageProcessorMatching.removeConsumerPointMatchTarget",
        "1:840:1.117.1.11",
        this);

      SibTr.exception(tc, e);

      if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
        SibTr.exit(tc, "removeConsumerPointMatchTarget", "SICoreException");

      SibTr.error(tc, "INTERNAL_MESSAGING_ERROR_CWSIP0002",
      new Object[] {
        "com.ibm.ws.sib.processor.matching.MessageProcessorMatching",
        "1:851:1.117.1.11",
        e });

      throw new SIErrorException(
        nls.getFormattedMessage(
          "INTERNAL_MESSAGING_ERROR_CWSIP0002",
          new Object[] {
            "com.ibm.ws.sib.processor.matching.MessageProcessorMatching",
            "1:859:1.117.1.11",
            e },
          null),
        e);
    }

    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.exit(tc, "removeConsumerPointMatchTarget");
  }
150595
public void removeKeyGroup(LocalQPConsumerKeyGroup keyGroup)
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.entry(tc, "removeKeyGroup", keyGroup);

    // Take the lock to prevent another thread from trying to add a member to
    // the group while we're removing it
    synchronized(_baseDestHandler.getReadyConsumerPointLock())
    {
      // Need to find the correct object to remove.
      Iterator keys = keyGroups.keySet().iterator();
      while (keys.hasNext())
      {
        Object key = keys.next();
        if (keyGroups.get(key).equals(keyGroup))
          keys.remove();
      }
    }

    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.exit(tc, "removeKeyGroup");
  }
844486
public void setConsumer(org.apache.kafka.clients.consumer.KafkaConsumer<Object, Object> consumer) {
        this.consumer = consumer;
    }
1035622
@Override
    public void deregisterConsumerSetMonitor(
                                             ConsumerSetChangeCallback callback)
                    throws SINotPossibleInCurrentConfigurationException
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(
                        tc,
                        "deregisterConsumerSetMonitor",
                        new Object[] { callback });

        _messageProcessor.
                        getMessageProcessorMatching().
                        deregisterConsumerSetMonitor(this, callback);

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(tc, "deregisterConsumerSetMonitor");
    }
547204
public void removeTarget(Object key) throws MatchingException
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.entry(tc,
                  "removeTarget",
                  new Object[]{key});
    // Remove from the HashMap, with synch, there may be other accessors
    synchronized(_targets)
    {
      Target targ = (Target) _targets.get(key);
      if (targ == null)
        throw new MatchingException();
      for (int i = 0; i < targ.targets.length; i++)
        _matchSpace.removeTarget(targ.expr[i], targ.targets[i]);

      // Now remove the Target from the cache
      _targets.remove(key);

      // Remove from the Monitor state, with synch, there may be other accessors
      if(targ.targets.length > 0) // Defect 417084, check targets is non-empty
      {
        if(targ.targets[0] instanceof MonitoredConsumer)
          _consumerMonitoring.removeConsumer((MonitoredConsumer)targ.targets[0]);
      }
    }
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.exit(tc, "removeTarget");
  }