Package org.apache.vinci.transport

Examples of org.apache.vinci.transport.VinciFrame.fadd()


      BaseClient client = null;
      // make sure we got a valid connection to VNS
      if (vnsConnection != null && vnsConnection.isOpen()) {
        // Set up VNS query
        VinciFrame queryFrame = new VinciFrame();
        queryFrame.fadd("vinci:COMMAND", "getlist");
        queryFrame.fadd("PREFIX", aVinciServiceName);
        // System.out.println("Query Frame:::"+queryFrame.toXML());
        // Query the VNS
        VinciFrame response = (VinciFrame) vnsConnection.sendAndReceive(queryFrame);
        ArrayList serviceFrames = response.fget("SERVICE");
View Full Code Here


      // make sure we got a valid connection to VNS
      if (vnsConnection != null && vnsConnection.isOpen()) {
        // Set up VNS query
        VinciFrame queryFrame = new VinciFrame();
        queryFrame.fadd("vinci:COMMAND", "getlist");
        queryFrame.fadd("PREFIX", aVinciServiceName);
        // System.out.println("Query Frame:::"+queryFrame.toXML());
        // Query the VNS
        VinciFrame response = (VinciFrame) vnsConnection.sendAndReceive(queryFrame);
        ArrayList serviceFrames = response.fget("SERVICE");
        // Each service is returned in its own SERVICE frame. So cycle through those now
View Full Code Here

  // Methods to perform service lookup
  public ServiceInfo[] lookup(String name, int level, String host, String instance, String ws) {
    VinciFrame req = new VinciFrame();

    req.fadd("vinci:COMMAND", VNSConstants.RESOLVE_COMMAND).fadd("SERVICE", name).fadd("LEVEL",
            level).fadd("HOST", host).fadd("INSTANCE", instance).fadd("WORKSPACE", ws);

    System.out.println(req.toXML());
    VinciFrame resp = (VinciFrame) transmit(req);
View Full Code Here

  }

  // Method to perform service resolve
  public ServiceInfo resolve(String name, String host, String ip, String ws, int level, int inst) {
    VinciFrame req = new VinciFrame();
    req.fadd("vinci:COMMAND", VNSConstants.RESOLVE_COMMAND).fadd("SERVICE", name);
    smFrameAdd(req, "HOST", host);
    smFrameAdd(req, "IP", ip);
    smFrameAdd(req, "WORKSPACE", ws);
    req.fadd("LEVEL", level);
    if (inst > 0) {
View Full Code Here

    VinciFrame req = new VinciFrame();
    req.fadd("vinci:COMMAND", VNSConstants.RESOLVE_COMMAND).fadd("SERVICE", name);
    smFrameAdd(req, "HOST", host);
    smFrameAdd(req, "IP", ip);
    smFrameAdd(req, "WORKSPACE", ws);
    req.fadd("LEVEL", level);
    if (inst > 0) {
      req.fadd("INSTANCE", inst);
    }

    VinciFrame resp = (VinciFrame) transmit(req);
View Full Code Here

    smFrameAdd(req, "HOST", host);
    smFrameAdd(req, "IP", ip);
    smFrameAdd(req, "WORKSPACE", ws);
    req.fadd("LEVEL", level);
    if (inst > 0) {
      req.fadd("INSTANCE", inst);
    }

    VinciFrame resp = (VinciFrame) transmit(req);

    checkError(resp);
View Full Code Here

  }

  // Method to get the list of services that are registered
  public ServiceInterface[] getList(String prefix, String level) {
    VinciFrame req = new VinciFrame();
    req.fadd("vinci:COMMAND", VNS.dirCmdGetList);
    req.fadd("LEVEL", level);
    smartAdd(req, "PREFIX", prefix);

    VinciFrame resp = (VinciFrame) transmit(req);
View Full Code Here

  // Method to get the list of services that are registered
  public ServiceInterface[] getList(String prefix, String level) {
    VinciFrame req = new VinciFrame();
    req.fadd("vinci:COMMAND", VNS.dirCmdGetList);
    req.fadd("LEVEL", level);
    smartAdd(req, "PREFIX", prefix);

    VinciFrame resp = (VinciFrame) transmit(req);

    checkError(resp);
View Full Code Here

  }

  // Method to get the registered service names
  public String[] getNames(String prefix, String level) {
    VinciFrame req = new VinciFrame();
    req.fadd("vinci:COMMAND", VNS.dirCmdGetNames);
    req.fadd("LEVEL", level);
    smartAdd(req, "PREFIX", prefix);

    VinciFrame resp = (VinciFrame) transmit(req);
View Full Code Here

  // Method to get the registered service names
  public String[] getNames(String prefix, String level) {
    VinciFrame req = new VinciFrame();
    req.fadd("vinci:COMMAND", VNS.dirCmdGetNames);
    req.fadd("LEVEL", level);
    smartAdd(req, "PREFIX", prefix);

    VinciFrame resp = (VinciFrame) transmit(req);

    checkError(resp);
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.