Examples of ConsumerInfo


Examples of org.apache.activemq.command.ConsumerInfo

        }
        return rc;
    }

    private ConsumerInfo createInactiveConsumerInfo(SubscriptionInfo info) {
        ConsumerInfo rc = new ConsumerInfo();
        rc.setSelector(info.getSelector());
        rc.setSubscriptionName(info.getSubscriptionName());
        rc.setDestination(info.getSubscribedDestination());
        rc.setConsumerId(createConsumerId());
        return rc;
    }
View Full Code Here

Examples of org.apache.airavata.wsmg.broker.ConsumerInfo

        // throw new IllegalArgumentException();
        // }
        this.localTopicString = topic;
        this.xpathString = xpath;
        this.isWsrmPolicy = wsrmEnabled;
        consumerInfo = new ConsumerInfo(consumerRef.getAddress(), type, useNotify, false);

    }
View Full Code Here

Examples of org.apache.shindig.gadgets.oauth.OAuthStore.ConsumerInfo

      // This is plain old signed fetch.
      accessorBuilder.setParameterLocation(AccessorInfo.OAuthParamLocation.URI_QUERY);
    }

    // What consumer key/secret should we use?
    ConsumerInfo consumer;
    try {
      consumer = store.getConsumerKeyAndSecret(
          securityToken, arguments.getServiceName(), provider);
      accessorBuilder.setConsumer(consumer);
    } catch (GadgetException e) {
View Full Code Here

Examples of org.apache.shindig.gadgets.oauth.OAuthStore.ConsumerInfo

  @Test
  public void testInit() throws Exception {
    FakeGadgetToken t = new FakeGadgetToken();
    t.setAppUrl("http://localhost:8080/gadgets/files/samplecontainer/examples/oauth.xml");
    OAuthServiceProvider provider = new OAuthServiceProvider("req", "authorize", "access");
    ConsumerInfo consumerInfo = store.getConsumerKeyAndSecret(t, "", provider);
    OAuthConsumer consumer = consumerInfo.getConsumer();
    assertEquals("gadgetConsumer", consumer.consumerKey);
    assertEquals("gadgetSecret", consumer.consumerSecret);
    assertEquals("HMAC-SHA1", consumer.getProperty("oauth_signature_method"));
    assertEquals(provider, consumer.serviceProvider);
    assertNull(consumerInfo.getKeyName());
    assertEquals("default callback", consumerInfo.getCallbackUrl());

    t.setAppUrl("http://rsagadget/test.xml");
    consumerInfo = store.getConsumerKeyAndSecret(t, "", provider);
    consumer = consumerInfo.getConsumer();
    assertEquals("rsaconsumer", consumer.consumerKey);
    assertNull(consumer.consumerSecret);
    assertEquals("RSA-SHA1", consumer.getProperty("oauth_signature_method"));
    assertEquals(provider, consumer.serviceProvider);
    assertEquals("rsaprivate", consumer.getProperty(RSA_SHA1.PRIVATE_KEY));
    assertNull(consumerInfo.getKeyName());
    assertEquals("callback", consumerInfo.getCallbackUrl());
  }
View Full Code Here

Examples of org.apache.shindig.gadgets.oauth.OAuthStore.ConsumerInfo

  }

  @Test
  public void testGetAndSetAndRemoveToken() {
    FakeGadgetToken t = new FakeGadgetToken();
    ConsumerInfo consumer = new ConsumerInfo(null, null, null);
    t.setAppUrl("http://localhost:8080/gadgets/files/samplecontainer/examples/oauth.xml");
    t.setViewerId("viewer-one");
    assertNull(store.getTokenInfo(t, consumer, "", ""));

    TokenInfo info = new TokenInfo("token", "secret", null, 0);
View Full Code Here

Examples of org.codehaus.activemq.message.ConsumerInfo

     */
    public ConnectionConsumer createConnectionConsumer(Destination destination, String messageSelector,
                                                       ServerSessionPool sessionPool, int maxMessages) throws JMSException {
        checkClosed();
        ensureClientIDInitialised();
        ConsumerInfo info = new ConsumerInfo();
        info.setId(this.packetIdGenerator.generateId());
        info.setConsumerId(consumerIdGenerator.generateId());
        info.setDestination(ActiveMQMessageTransformation.transformDestination(destination));
        info.setSelector(messageSelector);
        return new ActiveMQConnectionConsumer(this, sessionPool, info, maxMessages);
    }
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.