org.jboss.byteman.agent.submit.Submit Java Examples

The following examples show how to use org.jboss.byteman.agent.submit.Submit. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: PackStepdefs.java    From servicecomb-pack with Apache License 2.0 6 votes vote down vote up
@After
public void cleanUp() {
  LOG.info("Cleaning up services");
  for (String address : addresses) {
    given()
        .when()
        .delete(System.getProperty(address) + "/bookings")
        .then()
        .statusCode(is(200));
  }

  given()
      .when()
      .delete(alphaClusterAddress.getMasterAddress() + "/saga/events")
      .then()
      .statusCode(is(200));

  for (Submit bm : submits.values()) {
    try {
      bm.deleteAllRules();
    } catch (Exception e) {
      LOG.warn("Fail to delete the byteman rules " + e);
    }
  }
}
 
Example #2
Source File: PackStepdefs.java    From servicecomb-pack with Apache License 2.0 6 votes vote down vote up
@After
public void cleanUp() {
  LOG.info("Cleaning up services");
  for (String address : addresses) {
    given()
        .when()
        .delete(System.getProperty(address) + "/bookings")
        .then()
        .statusCode(is(200));
  }

  given()
      .when()
      .delete(System.getProperty(ALPHA_REST_ADDRESS) + "/saga/events")
      .then()
      .statusCode(is(200));

  for (Submit bm : submits.values()) {
    try {
      bm.deleteAllRules();
    } catch (Exception e) {
      LOG.warn("Fail to delete the byteman rules " + e);
    }
  }
}
 
Example #3
Source File: PackStepdefs.java    From servicecomb-pack with Apache License 2.0 6 votes vote down vote up
@After
public void cleanUp() {
  LOG.info("Cleaning up services");
  for (String address : addresses) {
    given()
        .when()
        .delete(System.getProperty(address) + "/bookings")
        .then()
        .statusCode(is(200));
  }

  given()
      .when()
      .delete(System.getProperty(ALPHA_REST_ADDRESS) + "/saga/events")
      .then()
      .statusCode(is(200));

  for (Submit bm : submits.values()) {
    try {
      bm.deleteAllRules();
    } catch (Exception e) {
      LOG.warn("Fail to delete the byteman rules " + e);
    }
  }
}
 
Example #4
Source File: PackStepdefs.java    From servicecomb-pack with Apache License 2.0 6 votes vote down vote up
@After
public void cleanUp() {
  LOG.info("Cleaning up services");
  for (String address : addresses) {
    given()
        .when()
        .delete(System.getProperty(address) + "/bookings")
        .then()
        .statusCode(is(200));
  }

  given()
      .when()
      .delete(System.getProperty(ALPHA_REST_ADDRESS) + "/test/saga/akka/events")
      .then()
      .statusCode(is(200));

  for (Submit bm : submits.values()) {
    try {
      bm.deleteAllRules();
    } catch (Exception e) {
      LOG.warn("Fail to delete the byteman rules " + e);
    }
  }
}
 
Example #5
Source File: PackStepdefs.java    From servicecomb-pack with Apache License 2.0 6 votes vote down vote up
@After
public void cleanUp() {
  LOG.info("Cleaning up services");
  for (String address : addresses) {
    given()
        .when()
        .delete(System.getProperty(address) + "/bookings")
        .then()
        .statusCode(is(200));
  }

  given()
      .when()
      .delete(System.getProperty(ALPHA_REST_ADDRESS) + "/saga/events")
      .then()
      .statusCode(is(200));

  for (Submit bm : submits.values()) {
    try {
      bm.deleteAllRules();
    } catch (Exception e) {
      LOG.warn("Fail to delete the byteman rules " + e);
    }
  }
}
 
Example #6
Source File: PackStepdefs.java    From servicecomb-pack with Apache License 2.0 6 votes vote down vote up
@After
public void cleanUp() {
  LOG.info("Cleaning up services");
  for (String address : addresses) {
    given()
        .when()
        .delete(System.getProperty(address) + "/bookings")
        .then()
        .statusCode(is(200));
  }

  given()
      .when()
      .delete(System.getProperty(ALPHA_REST_ADDRESS) + "/saga/events")
      .then()
      .statusCode(is(200));

  for (Submit bm : submits.values()) {
    try {
      bm.deleteAllRules();
    } catch (Exception e) {
      LOG.warn("Fail to delete the byteman rules " + e);
    }
  }
}
 
Example #7
Source File: StepDefSupport.java    From servicecomb-pack with Apache License 2.0 5 votes vote down vote up
protected Submit getBytemanSubmit(String service) {
  if (submits.containsKey(service)) {
    return submits.get(service);
  } else {
    String address = System.getProperty("byteman.address");
    String port = System.getProperty(service.toLowerCase() + ".byteman.port");
    Submit bm = new Submit(address, Integer.parseInt(port));
    submits.put(service, bm);
    return bm;
  }
}
 
Example #8
Source File: PackStepdefs.java    From servicecomb-pack with Apache License 2.0 5 votes vote down vote up
private Submit getBytemanSubmit(String service) {
  if (submits.containsKey(service)) {
    return submits.get(service);
  } else {
    String address = System.getProperty("byteman.address");
    String port = System.getProperty(service.toLowerCase() + ".byteman.port");
    Submit bm = new Submit(address, Integer.parseInt(port));
    submits.put(service, bm);
    return bm;
  }
}