code: public synchronized Channel getRunningChannel(String inputChannelName, Chain chain) {
          if (inputChannelName == null || chain == null) {
              return null;
          }
  
          Channel channel = null;
          // Ensure the chain is running.
          if (null != this.chainRunningMap.get(chain.getName())) {
              ChannelData[] channels = chain.getChannelsData();
              for (int index = 0; index < channels.length; index++) {
                  if (channels[index].getExternalName().equals(inputChannelName)) {
                      channel = chain.getChannels()[index];
                      break;
                  }
              }
          }
          return channel;
      }
docs: Fetch the input channel from the runtime.
  
  @param inputChannelName
  of the (parent) channel requested.
  @param chain
  in which channel is running.
  @return Channel requested, or null if not found.