Package org.xmlBlaster.client.key

Examples of org.xmlBlaster.client.key.GetKey


   /** JMX **/
   public String[] invokeGet(String url, String qos) throws Exception {
      qos = checkQueryKeyQos(url, qos);
      try {
         GetKey gk = new GetKey(glob, url);
         MsgUnit[] msgs = get(gk, new GetQos(glob, glob.getQueryQosFactory().readObject(qos)));
         if (msgs == null) return new String[0];
         if (msgs == null || msgs.length < 1) {
            return new String[] { "get('"+url+"') did not match any topic" };
         }
View Full Code Here


            throw e;
         }
      }
      else {
         String oid = "__cmd:" + cmd;
         GetKey getKey = new GetKey(glob, oid);
         GetQos getQos = new GetQos(glob);
         try {
            MsgUnit[] msgs = get(getKey, getQos);
            if (log.isLoggable(Level.FINE)) log.fine(getLogId()+"Send '" + cmd + " ', got array of size " + msgs.length);
            if (msgs.length == 0)
View Full Code Here

            }

            {
               log.info("Hit a key to get '" + oid + "'");
               try { System.in.read(); } catch(java.io.IOException e) {}
               GetKey gk = new GetKey(glob, oid);
               GetQos gq = new GetQos(glob);
               MsgUnit[] msgs = xmlBlasterAccess.get(gk, gq);
               log.info("Successfully got message from xmlBlaster, msg=" + msgs[0].toXml());
            }

            int numGetCached = 4;
            xmlBlasterAccess.createSynchronousCache(100);
            for (int i=0; i<numGetCached; i++) {
               log.info("Hit a key to getCached '" + oid + "' #"+i+"/"+numGetCached);
               try { System.in.read(); } catch(java.io.IOException e) {}
               GetKey gk = new GetKey(glob, oid);
               GetQos gq = new GetQos(glob);
               MsgUnit[] msgs = xmlBlasterAccess.getCached(gk, gq);
               log.info("Successfully got message from xmlBlaster, msg=" + msgs[0].toXml());
            }
View Full Code Here

      else if (node.isOfClass(ContextNode.SUBJECT_MARKER_TAG) && node.getChild(ContextNode.SESSION_MARKER_TAG, null) != null)
            oid = "__cmd:"+oid+"/?callbackQueueEntries"; // "__cmd:client/joe/session/1/?callbackQueueEntries";
      else if (node.isOfClass(ContextNode.SUBJECT_MARKER_TAG))
            oid = "__cmd:"+oid+"/?subjectQueueEntries"; // "__cmd:client/joe/?subjectQueueEntries"

      GetKey getKey = new GetKey(glob, oid);
      String qos = "<qos>" +
                   "<querySpec type='QueueQuery'>" +
                   "maxEntries="+maxEntries+"&amp;maxSize=-1&amp;consumable="+consumable+"&amp;waitingDelay="+timeout+
                   "</querySpec>" +
                   "</qos>";
View Full Code Here

            ClientProperty[] props = otherSessionInfo.getRemotePropertyArr();
            GetReturnQosServer retQos = new GetReturnQosServer(glob, null, null);
            for (int i=0; i<props.length; i++)
               retQos.getData().getClientProperties().put(props[i].getName(), props[i]);
            MsgUnit[] msgUnitArr = new MsgUnit[1];
            GetKey gk = new GetKey(glob, xmlKey.getOid());
            msgUnitArr[0] = new MsgUnit(gk.getData(), new byte[0], retQos.getData());
            return msgUnitArr;
          }

         if (xmlKey.isAdministrative()) {
            if (!glob.supportAdministrative())
View Full Code Here

TOP

Related Classes of org.xmlBlaster.client.key.GetKey

Copyright © 2018 www.massapicom. 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.