nus-yam/ex-repair huggingface dataset:
Program: 7251
Project: 7251
Buggy source:
public GenerateCLIDocsTable(final CLIConfig cliConfig) throws URISyntaxException, IOException {
  Injector injector=Guice.createInjector(new AbstractModule(){
    @Override protected void configure(){
      bind(PrintStream.class).toInstance(System.out);
      bind(String.class).annotatedWith(Names.named(CLIMain.NAME_URI)).toInstance("String_Node_Str");
      bind(Boolean.class).annotatedWith(Names.named(CLIMain.NAME_VERIFY_SSL)).toInstance(false);
      bind(Boolean.class).annotatedWith(Names.named(CLIMain.NAME_DEBUG)).toInstance(true);
      bind(Boolean.class).annotatedWith(Names.named(CLIMain.NAME_AUTOCONNECT)).toInstance(true);
      bind(CLIConfig.class).toInstance(cliConfig);
      bind(ClientConfig.class).toInstance(cliConfig.getClientConfig());
      bind(CConfiguration.class).toInstance(CConfiguration.create());
      bind(TableRenderer.class).to(CsvTableRenderer.class);
    }
  }
);
  this.printDocsCommand=new GenerateCLIDocsTableCommand(injector.getInstance(DefaultCommands.class));
}

Fixed version (ground truth):
public GenerateCLIDocsTable(final CLIConfig cliConfig) throws URISyntaxException, IOException {
  Injector injector=Guice.createInjector(new AbstractModule(){
    @Override protected void configure(){
      bind(CConfiguration.class).toInstance(CConfiguration.create());
      bind(LaunchOptions.class).toInstance(LaunchOptions.DEFAULT);
      bind(PrintStream.class).toInstance(System.out);
      bind(CLIConfig.class).toInstance(cliConfig);
      bind(ClientConfig.class).toInstance(cliConfig.getClientConfig());
      bind(TableRenderer.class).toInstance(new CsvTableRenderer());
    }
  }
);
  this.printDocsCommand=new GenerateCLIDocsTableCommand(injector.getInstance(DefaultCommands.class));
}
Program: 7252
Project: 7252
Buggy source:
@Override protected void configure(){
  bind(PrintStream.class).toInstance(System.out);
  bind(String.class).annotatedWith(Names.named(CLIMain.NAME_URI)).toInstance("String_Node_Str");
  bind(Boolean.class).annotatedWith(Names.named(CLIMain.NAME_VERIFY_SSL)).toInstance(false);
  bind(Boolean.class).annotatedWith(Names.named(CLIMain.NAME_DEBUG)).toInstance(true);
  bind(Boolean.class).annotatedWith(Names.named(CLIMain.NAME_AUTOCONNECT)).toInstance(true);
  bind(CLIConfig.class).toInstance(cliConfig);
  bind(ClientConfig.class).toInstance(cliConfig.getClientConfig());
  bind(CConfiguration.class).toInstance(CConfiguration.create());
  bind(TableRenderer.class).to(CsvTableRenderer.class);
}

Fixed version (ground truth):
@Override protected void configure(){
  bind(CConfiguration.class).toInstance(CConfiguration.create());
  bind(LaunchOptions.class).toInstance(LaunchOptions.DEFAULT);
  bind(PrintStream.class).toInstance(System.out);
  bind(CLIConfig.class).toInstance(cliConfig);
  bind(ClientConfig.class).toInstance(cliConfig.getClientConfig());
  bind(TableRenderer.class).toInstance(new CsvTableRenderer());
}
Program: 7254
Project: 7254
Buggy source:
@Override public boolean handleException(PrintStream output,Exception e,int timesRetried){
  if (e instanceof SSLHandshakeException) {
    output.printf("String_Node_Str",CLIConfig.PROP_VERIFY_SSL_CERT);
  }
 else   if (e instanceof InvalidCommandException) {
    InvalidCommandException ex=(InvalidCommandException)e;
    output.printf("String_Node_Str",ex.getInput());
  }
 else {
    output.println("String_Node_Str" + e.getMessage());
  }
  if (options.isDebug()) {
    e.printStackTrace(output);
  }
  return false;
}

Fixed version (ground truth):
@Override public boolean handleException(PrintStream output,Exception e,int timesRetried){
  if (e instanceof SSLHandshakeException) {
    output.printf("String_Node_Str",VERIFY_SSL_OPTION.getLongOpt());
  }
 else   if (e instanceof InvalidCommandException) {
    InvalidCommandException ex=(InvalidCommandException)e;
    output.printf("String_Node_Str",ex.getInput());
  }
 else {
    output.println("String_Node_Str" + e.getMessage());
  }
  if (options.isDebug()) {
    e.printStackTrace(output);
  }
  return false;
}
Program: 7256
Project: 7256
Buggy source:
@Test public void testDataset() throws Exception {
  String datasetName=PREFIX + "String_Node_Str";
  DatasetTypeClient datasetTypeClient=new DatasetTypeClient(cliConfig.getClientConfig());
  DatasetTypeMeta datasetType=datasetTypeClient.list().get(0);
  testCommandOutputContains(cli,"String_Node_Str" + datasetType.getName() + "String_Node_Str"+ datasetName,"String_Node_Str");
  testCommandOutputContains(cli,"String_Node_Str",FakeDataset.class.getSimpleName());
  NamespaceClient namespaceClient=new NamespaceClient(cliConfig.getClientConfig());
  namespaceClient.create(new NamespaceMeta.Builder().setId("String_Node_Str").build());
  cliConfig.setCurrentNamespace("String_Node_Str");
  testCommandOutputNotContains(cli,"String_Node_Str",FakeDataset.class.getSimpleName());
  testCommandOutputContains(cli,"String_Node_Str" + datasetType.getName() + "String_Node_Str"+ datasetName,"String_Node_Str" + datasetType.getName() + "String_Node_Str");
  testCommandOutputContains(cli,"String_Node_Str","String_Node_Str");
  try {
    testCommandOutputContains(cli,"String_Node_Str" + datasetName,"String_Node_Str");
  }
  finally {
    testCommandOutputContains(cli,"String_Node_Str" + datasetName,"String_Node_Str");
  }
}

Fixed version (ground truth):
@Test public void testDataset() throws Exception {
  String datasetName=PREFIX + "String_Node_Str";
  DatasetTypeClient datasetTypeClient=new DatasetTypeClient(cliConfig.getClientConfig());
  DatasetTypeMeta datasetType=datasetTypeClient.list().get(0);
  testCommandOutputContains(cli,"String_Node_Str" + datasetType.getName() + "String_Node_Str"+ datasetName,"String_Node_Str");
  testCommandOutputContains(cli,"String_Node_Str",FakeDataset.class.getSimpleName());
  NamespaceClient namespaceClient=new NamespaceClient(cliConfig.getClientConfig());
  Id.Namespace barspace=Id.Namespace.from("String_Node_Str");
  namespaceClient.create(new NamespaceMeta.Builder().setId(barspace).build());
  cliConfig.setCurrentNamespace(barspace);
  testCommandOutputNotContains(cli,"String_Node_Str",FakeDataset.class.getSimpleName());
  testCommandOutputContains(cli,"String_Node_Str" + datasetType.getName() + "String_Node_Str"+ datasetName,"String_Node_Str" + datasetType.getName() + "String_Node_Str");
  testCommandOutputContains(cli,"String_Node_Str","String_Node_Str");
  try {
    testCommandOutputContains(cli,"String_Node_Str" + datasetName,"String_Node_Str");
  }
  finally {
    testCommandOutputContains(cli,"String_Node_Str" + datasetName,"String_Node_Str");
  }
}
Program: 7257
Project: 7257
Buggy source:
@BeforeClass public static void setUpClass() throws Exception {
  if (START_LOCAL_STANDALONE) {
    File adapterDir=TMP_FOLDER.newFolder("String_Node_Str");
    configuration=CConfiguration.create();
    configuration.set(Constants.AppFabric.ADAPTER_DIR,adapterDir.getAbsolutePath());
    setupAdapters(adapterDir);
    StandaloneTestBase.setUpClass();
  }
  cliConfig=new CLIConfig(HOSTNAME);
  cliConfig.getClientConfig().setAllTimeouts(60000);
  programClient=new ProgramClient(cliConfig.getClientConfig());
  adapterClient=new AdapterClient(cliConfig.getClientConfig());
  CLIMain cliMain=new CLIMain(cliConfig);
  cli=cliMain.getCLI();
  testCommandOutputContains(cli,"String_Node_Str" + PROTOCOL + "String_Node_Str"+ HOSTNAME+ "String_Node_Str"+ PORT,"String_Node_Str");
  testCommandOutputNotContains(cli,"String_Node_Str",FakeApp.NAME);
  File appJarFile=createAppJarFile(FakeApp.class);
  testCommandOutputContains(cli,"String_Node_Str" + appJarFile.getAbsolutePath(),"String_Node_Str");
  if (!appJarFile.delete()) {
    LOG.warn("String_Node_Str",appJarFile.getAbsolutePath());
  }
}

Fixed version (ground truth):
@BeforeClass public static void setUpClass() throws Exception {
  if (START_LOCAL_STANDALONE) {
    File adapterDir=TMP_FOLDER.newFolder("String_Node_Str");
    configuration=CConfiguration.create();
    configuration.set(Constants.AppFabric.ADAPTER_DIR,adapterDir.getAbsolutePath());
    setupAdapters(adapterDir);
    StandaloneTestBase.setUpClass();
  }
  clientConfig=new ClientConfig.Builder().setUri(CONNECTION).build();
  clientConfig.setAllTimeouts(60000);
  cliConfig=new CLIConfig(clientConfig);
  Injector injector=Guice.createInjector(new AbstractModule(){
    @Override protected void configure(){
      bind(PrintStream.class).toInstance(System.out);
      bind(String.class).annotatedWith(Names.named(CLIMain.NAME_NAMESPACE)).toInstance("String_Node_Str");
      bind(String.class).annotatedWith(Names.named(CLIMain.NAME_URI)).toInstance(CONNECTION.toString());
      bind(Boolean.class).annotatedWith(Names.named(CLIMain.NAME_VERIFY_SSL)).toInstance(false);
      bind(Boolean.class).annotatedWith(Names.named(CLIMain.NAME_VERBOSE)).toInstance(true);
      bind(Boolean.class).annotatedWith(Names.named(CLIMain.NAME_AUTOCONNECT)).toInstance(true);
      bind(CLIConfig.class).toInstance(cliConfig);
      bind(ClientConfig.class).toInstance(cliConfig.getClientConfig());
      bind(CConfiguration.class).toInstance(CConfiguration.create());
    }
  }
);
  programClient=new ProgramClient(cliConfig.getClientConfig());
  adapterClient=new AdapterClient(cliConfig.getClientConfig());
  CLIMain cliMain=injector.getInstance(CLIMain.class);
  cli=cliMain.getCLI();
  testCommandOutputContains(cli,"String_Node_Str" + CONNECTION.toString(),"String_Node_Str");
  testCommandOutputNotContains(cli,"String_Node_Str",FakeApp.NAME);
  File appJarFile=createAppJarFile(FakeApp.class);
  testCommandOutputContains(cli,"String_Node_Str" + appJarFile.getAbsolutePath(),"String_Node_Str");
  if (!appJarFile.delete()) {
    LOG.warn("String_Node_Str",appJarFile.getAbsolutePath());
  }
}
Program: 7258
Project: 7258
Buggy source:
@Test public void testConnect() throws Exception {
  testCommandOutputContains(cli,"String_Node_Str","String_Node_Str");
  testCommandOutputContains(cli,"String_Node_Str" + HOSTNAME,"String_Node_Str");
  testCommandOutputContains(cli,"String_Node_Str" + PROTOCOL + "String_Node_Str"+ HOSTNAME,"String_Node_Str");
  testCommandOutputContains(cli,"String_Node_Str" + PROTOCOL + "String_Node_Str"+ HOSTNAME+ "String_Node_Str"+ PORT,"String_Node_Str");
}

Fixed version (ground truth):
@Test public void testConnect() throws Exception {
  testCommandOutputContains(cli,"String_Node_Str","String_Node_Str");
  testCommandOutputContains(cli,"String_Node_Str" + CONNECTION.toString(),"String_Node_Str");
}
Program: 7260
Project: 7260
Buggy source:
@Override public void execute(Arguments arguments,PrintStream out) throws Exception {
  String namespaceId=arguments.get(ArgumentName.NAMESPACE_ID.toString());
  namespaceClient.delete(namespaceId);
  out.println(String.format(SUCCESS_MSG,namespaceId));
}

Fixed version (ground truth):
@Override public void execute(Arguments arguments,PrintStream out) throws Exception {
  Id.Namespace namespaceId=Id.Namespace.from(arguments.get(ArgumentName.NAMESPACE_ID.toString()));
  namespaceClient.delete(namespaceId);
  out.println(String.format(SUCCESS_MSG,namespaceId));
}
Program: 7262
Project: 7262
Buggy source:
@Override public void execute(Arguments arguments,PrintStream output) throws Exception {
  NamespaceMeta namespaceMeta=namespaceClient.get(arguments.get(ArgumentName.NAMESPACE_ID.getName()));
  new AsciiTable<NamespaceMeta>(new String[]{"String_Node_Str","String_Node_Str","String_Node_Str"},Lists.newArrayList(namespaceMeta),new RowMaker<NamespaceMeta>(){
    @Override public Object[] makeRow(    NamespaceMeta object){
      return new Object[]{object.getId(),object.getName(),object.getDescription()};
    }
  }
).print(output);
}

Fixed version (ground truth):
@Override public void execute(Arguments arguments,PrintStream output) throws Exception {
  Id.Namespace namespace=Id.Namespace.from(arguments.get(ArgumentName.NAMESPACE_ID.getName()));
  NamespaceMeta namespaceMeta=namespaceClient.get(namespace);
  new AsciiTable<NamespaceMeta>(new String[]{"String_Node_Str","String_Node_Str","String_Node_Str"},Lists.newArrayList(namespaceMeta),new RowMaker<NamespaceMeta>(){
    @Override public Object[] makeRow(    NamespaceMeta object){
      return new Object[]{object.getId(),object.getName(),object.getDescription()};
    }
  }
).print(output);
}
Program: 7263
Project: 7263
Buggy source:
@Override public void perform(Arguments arguments,PrintStream output) throws Exception {
  String namespace=arguments.get(ArgumentName.NAMESPACE_ID.toString());
  namespaceClient.get(namespace);
  cliConfig.setCurrentNamespace(Id.Namespace.from(namespace));
  output.printf("String_Node_Str",namespace);
}

Fixed version (ground truth):
@Override public void perform(Arguments arguments,PrintStream output) throws Exception {
  Id.Namespace namespace=Id.Namespace.from(arguments.get(ArgumentName.NAMESPACE_ID.toString()));
  namespaceClient.get(namespace);
  cliConfig.setCurrentNamespace(namespace);
  output.printf("String_Node_Str",namespace);
}
Program: 7264
Project: 7264
Buggy source:
private void verifyDoesNotExist(String namespaceId) throws IOException, UnAuthorizedAccessTokenException, CannotBeDeletedException {
  try {
    namespaceClient.get(namespaceId);
    Assert.fail(String.format("String_Node_Str",namespaceId));
  }
 catch (  NotFoundException e) {
  }
  try {
    namespaceClient.delete(namespaceId);
    Assert.fail(String.format("String_Node_Str",namespaceId));
  }
 catch (  NotFoundException e) {
  }
}

Fixed version (ground truth):
private void verifyDoesNotExist(Id.Namespace namespaceId) throws IOException, UnAuthorizedAccessTokenException, CannotBeDeletedException {
  try {
    namespaceClient.get(namespaceId);
    Assert.fail(String.format("String_Node_Str",namespaceId));
  }
 catch (  NotFoundException e) {
  }
  try {
    namespaceClient.delete(namespaceId);
    Assert.fail(String.format("String_Node_Str",namespaceId));
  }
 catch (  NotFoundException e) {
  }
}
Program: 7266
Project: 7266
Buggy source:
@Test public void testDeletingNamespace() throws Exception {
  Map<String,String> propMap=Maps.newHashMap();
  propMap.put("String_Node_Str","String_Node_Str");
  Id.Namespace myspace=Id.Namespace.from("String_Node_Str");
  namespaceClient.create(new NamespaceMeta.Builder().setId(myspace.getId()).build());
  client.setNamespacePreferences(myspace,propMap);
  Assert.assertEquals(propMap,client.getNamespacePreferences(myspace,false));
  Assert.assertEquals(propMap,client.getNamespacePreferences(myspace,true));
  namespaceClient.delete("String_Node_Str");
  namespaceClient.create(new NamespaceMeta.Builder().setId(myspace.getId()).build());
  Assert.assertTrue(client.getNamespacePreferences(myspace,false).isEmpty());
  Assert.assertTrue(client.getNamespacePreferences(myspace,true).isEmpty());
  namespaceClient.delete("String_Node_Str");
}

Fixed version (ground truth):
@Test public void testDeletingNamespace() throws Exception {
  Map<String,String> propMap=Maps.newHashMap();
  propMap.put("String_Node_Str","String_Node_Str");
  Id.Namespace myspace=Id.Namespace.from("String_Node_Str");
  namespaceClient.create(new NamespaceMeta.Builder().setId(myspace.getId()).build());
  client.setNamespacePreferences(myspace,propMap);
  Assert.assertEquals(propMap,client.getNamespacePreferences(myspace,false));
  Assert.assertEquals(propMap,client.getNamespacePreferences(myspace,true));
  namespaceClient.delete(myspace);
  namespaceClient.create(new NamespaceMeta.Builder().setId(myspace.getId()).build());
  Assert.assertTrue(client.getNamespacePreferences(myspace,false).isEmpty());
  Assert.assertTrue(client.getNamespacePreferences(myspace,true).isEmpty());
  namespaceClient.delete(myspace);
}
Program: 7268
Project: 7268
Buggy source:
@Test public void testAll() throws Exception {
  appClient.deploy(createAppJarFile(FakeApp.class));
  programClient.start(FakeApp.NAME,ProgramType.FLOW,FakeFlow.NAME);
  assertProgramRunning(programClient,FakeApp.NAME,ProgramType.FLOW,FakeFlow.NAME);
  streamClient.sendEvent(FakeApp.STREAM_NAME,"String_Node_Str");
  streamClient.sendEvent(FakeApp.STREAM_NAME,"String_Node_Str");
  Thread.sleep(3000);
  String namespace=getClientConfig().getNamespace();
  String instanceName=String.format("String_Node_Str",namespace,FakeApp.DS_NAME);
  Id.DatasetInstance datasetInstance=Id.DatasetInstance.from(namespace,instanceName);
  executeBasicQuery(instanceName);
  exploreClient.disableExploreDataset(datasetInstance).get();
  try {
    queryClient.execute("String_Node_Str" + FakeApp.DS_NAME).get();
    Assert.fail("String_Node_Str");
  }
 catch (  ExecutionException e) {
  }
  exploreClient.enableExploreDataset(datasetInstance).get();
  executeBasicQuery(instanceName);
}

Fixed version (ground truth):
@Test public void testAll() throws Exception {
  appClient.deploy(createAppJarFile(FakeApp.class));
  programClient.start(FakeApp.NAME,ProgramType.FLOW,FakeFlow.NAME);
  assertProgramRunning(programClient,FakeApp.NAME,ProgramType.FLOW,FakeFlow.NAME);
  streamClient.sendEvent(FakeApp.STREAM_NAME,"String_Node_Str");
  streamClient.sendEvent(FakeApp.STREAM_NAME,"String_Node_Str");
  Thread.sleep(3000);
  Id.Namespace namespace=getClientConfig().getNamespace();
  String instanceName=String.format("String_Node_Str",namespace,FakeApp.DS_NAME);
  Id.DatasetInstance datasetInstance=Id.DatasetInstance.from(namespace,instanceName);
  executeBasicQuery(instanceName);
  exploreClient.disableExploreDataset(datasetInstance).get();
  try {
    queryClient.execute("String_Node_Str" + FakeApp.DS_NAME).get();
    Assert.fail("String_Node_Str");
  }
 catch (  ExecutionException e) {
  }
  exploreClient.enableExploreDataset(datasetInstance).get();
  executeBasicQuery(instanceName);
}
Program: 7269
Project: 7269
Buggy source:
/** 
 * Retrieves details about a given namespace.
 * @param namespaceId id of the namespace for which details are requested.
 * @return
 * @throws IOException if a network error occurred
 * @throws UnAuthorizedAccessTokenException if the request is not authorized successfully in the gateway server
 * @throws NotFoundException if the specified namespace is not found
 */
public NamespaceMeta get(String namespaceId) throws IOException, UnAuthorizedAccessTokenException, NotFoundException {
  HttpResponse response=restClient.execute(HttpMethod.GET,config.resolveURLV3(String.format("String_Node_Str",namespaceId)),config.getAccessToken(),HttpURLConnection.HTTP_NOT_FOUND);
  if (HttpURLConnection.HTTP_NOT_FOUND == response.getResponseCode()) {
    throw new NotFoundException(NAMESPACE_ENTITY_TYPE,namespaceId);
  }
  return ObjectResponse.fromJsonBody(response,new TypeToken<NamespaceMeta>(){
  }
).getResponseObject();
}

Fixed version (ground truth):
/** 
 * Retrieves details about a given namespace.
 * @param namespaceId id of the namespace for which details are requested.
 * @return
 * @throws IOException if a network error occurred
 * @throws UnAuthorizedAccessTokenException if the request is not authorized successfully in the gateway server
 * @throws NotFoundException if the specified namespace is not found
 */
public NamespaceMeta get(Id.Namespace namespaceId) throws IOException, UnAuthorizedAccessTokenException, NotFoundException {
  HttpResponse response=restClient.execute(HttpMethod.GET,config.resolveURLV3(String.format("String_Node_Str",namespaceId)),config.getAccessToken(),HttpURLConnection.HTTP_NOT_FOUND);
  if (HttpURLConnection.HTTP_NOT_FOUND == response.getResponseCode()) {
    throw new NotFoundException(NAMESPACE_ENTITY_TYPE,namespaceId.getId());
  }
  return ObjectResponse.fromJsonBody(response,new TypeToken<NamespaceMeta>(){
  }
).getResponseObject();
}
Program: 7270
Project: 7270
Buggy source:
/** 
 * * Deletes a namespace from CDAP.
 * @param namespaceId id of the namespace to be deleted.
 * @throws IOException if a network error occurred
 * @throws UnAuthorizedAccessTokenException if the request is not authorized successfully in the gateway server
 * @throws NotFoundException if the specified namespace is not found
 * @throws CannotBeDeletedException if the specified namespace is reserved and cannot be deleted
 */
public void delete(String namespaceId) throws IOException, UnAuthorizedAccessTokenException, NotFoundException, CannotBeDeletedException {
  HttpResponse response=restClient.execute(HttpMethod.DELETE,config.resolveURLV3(String.format("String_Node_Str",namespaceId)),config.getAccessToken(),HttpURLConnection.HTTP_NOT_FOUND,HttpURLConnection.HTTP_FORBIDDEN);
  if (HttpURLConnection.HTTP_NOT_FOUND == response.getResponseCode()) {
    throw new NotFoundException(NAMESPACE_ENTITY_TYPE,namespaceId);
  }
  if (HttpURLConnection.HTTP_FORBIDDEN == response.getResponseCode()) {
    throw new CannotBeDeletedException(NAMESPACE_ENTITY_TYPE,namespaceId);
  }
}

Fixed version (ground truth):
/** 
 * * Deletes a namespace from CDAP.
 * @param namespaceId id of the namespace to be deleted.
 * @throws IOException if a network error occurred
 * @throws UnAuthorizedAccessTokenException if the request is not authorized successfully in the gateway server
 * @throws NotFoundException if the specified namespace is not found
 * @throws CannotBeDeletedException if the specified namespace is reserved and cannot be deleted
 */
public void delete(Id.Namespace namespaceId) throws IOException, UnAuthorizedAccessTokenException, NotFoundException, CannotBeDeletedException {
  HttpResponse response=restClient.execute(HttpMethod.DELETE,config.resolveURLV3(String.format("String_Node_Str",namespaceId.getId())),config.getAccessToken(),HttpURLConnection.HTTP_NOT_FOUND,HttpURLConnection.HTTP_FORBIDDEN);
  if (HttpURLConnection.HTTP_NOT_FOUND == response.getResponseCode()) {
    throw new NotFoundException(NAMESPACE_ENTITY_TYPE,namespaceId.getId());
  }
  if (HttpURLConnection.HTTP_FORBIDDEN == response.getResponseCode()) {
    throw new CannotBeDeletedException(NAMESPACE_ENTITY_TYPE,namespaceId.getId());
  }
}
Program: 7271
Project: 7271
Buggy source:
FileContentWriter(StreamConfig streamConfig,ConcurrentStreamWriter streamWriter,Location directory,Map<String,String> headers) throws IOException {
  this.streamConfig=streamConfig;
  this.streamWriter=streamWriter;
  this.streamEventData=new MutableStreamEventData();
  this.streamEvent=new MutableStreamEvent();
  directory.mkdirs();
  this.eventFile=directory.append(String.format("String_Node_Str",streamConfig.getStreamId()));
  this.indexFile=directory.append(String.format("String_Node_Str",streamConfig.getStreamId()));
  Map<String,String> properties=createStreamFileProperties(headers);
  properties.put(StreamDataFileConstants.Property.Key.UNI_TIMESTAMP,StreamDataFileConstants.Property.Value.CLOSE_TIMESTAMP);
  this.writer=new StreamDataFileWriter(Locations.newOutputSupplier(eventFile),Locations.newOutputSupplier(indexFile),streamConfig.getIndexInterval(),properties);
}

Fixed version (ground truth):
FileContentWriter(StreamConfig streamConfig,ConcurrentStreamWriter streamWriter,Location directory,Map<String,String> headers) throws IOException {
  this.streamConfig=streamConfig;
  this.streamWriter=streamWriter;
  this.streamEventData=new MutableStreamEventData();
  this.streamEvent=new MutableStreamEvent();
  directory.mkdirs();
  this.eventFile=directory.append("String_Node_Str");
  this.indexFile=directory.append("String_Node_Str");
  Map<String,String> properties=createStreamFileProperties(headers);
  properties.put(StreamDataFileConstants.Property.Key.UNI_TIMESTAMP,StreamDataFileConstants.Property.Value.CLOSE_TIMESTAMP);
  this.writer=new StreamDataFileWriter(Locations.newOutputSupplier(eventFile),Locations.newOutputSupplier(indexFile),streamConfig.getIndexInterval(),properties);
}
Program: 7273
Project: 7273
Buggy source:
public CubeQuery(long startTs,long endTs,int resolution,int limit,String measureName,MeasureType measureType,Map<String,String> sliceByTagValues,List<String> groupByTags,@Nullable Interpolator interpolator){
  this.startTs=startTs;
  this.endTs=endTs;
  this.resolution=resolution;
  this.limit=limit;
  this.measureName=measureName;
  this.measureType=measureType;
  this.sliceByTagValues=ImmutableMap.copyOf(sliceByTagValues);
  this.groupByTags=ImmutableList.copyOf(groupByTags);
  this.interpolator=interpolator;
}

Fixed version (ground truth):
public CubeQuery(long startTs,long endTs,int resolution,int limit,String measureName,MeasureType measureType,Map<String,String> sliceByTagValues,List<String> groupByTags,@Nullable Interpolator interpolator){
  this.startTs=startTs;
  this.endTs=endTs;
  this.resolution=resolution;
  this.limit=limit;
  this.measureName=measureName;
  this.measureType=measureType;
  this.sliceByTagValues=Maps.newHashMap(sliceByTagValues);
  this.groupByTags=ImmutableList.copyOf(groupByTags);
  this.interpolator=interpolator;
}
Program: 7274
Project: 7274
Buggy source:
@Test public void testGetId() throws Exception {
  InMemoryOrderedTableService.create("String_Node_Str");
  MetricsTable table=new InMemoryMetricsTable("String_Node_Str");
  EntityTable entityTable=new EntityTable(table);
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
  entityTable=new EntityTable(table);
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
}

Fixed version (ground truth):
@Test public void testGetId() throws Exception {
  InMemoryTableService.create("String_Node_Str");
  MetricsTable table=new InMemoryMetricsTable("String_Node_Str");
  EntityTable entityTable=new EntityTable(table);
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
  entityTable=new EntityTable(table);
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
}
Program: 7275
Project: 7275
Buggy source:
@Test public void testRecycleAfterMaxId() throws Exception {
  InMemoryOrderedTableService.create("String_Node_Str");
  MetricsTable table=new InMemoryMetricsTable("String_Node_Str");
  EntityTable entityTable=new EntityTable(table,101);
  for (long i=1; i <= 500; i++) {
    entityTable.getId("String_Node_Str","String_Node_Str" + i);
  }
  for (long i=1; i <= 100; i++) {
    Assert.assertEquals("String_Node_Str" + String.valueOf(400 + i),entityTable.getName(i,"String_Node_Str"));
  }
}

Fixed version (ground truth):
@Test public void testRecycleAfterMaxId() throws Exception {
  InMemoryTableService.create("String_Node_Str");
  MetricsTable table=new InMemoryMetricsTable("String_Node_Str");
  EntityTable entityTable=new EntityTable(table,101);
  for (long i=1; i <= 500; i++) {
    entityTable.getId("String_Node_Str","String_Node_Str" + i);
  }
  for (long i=1; i <= 100; i++) {
    Assert.assertEquals("String_Node_Str" + String.valueOf(400 + i),entityTable.getName(i,"String_Node_Str"));
  }
}
Program: 7276
Project: 7276
Buggy source:
@Test public void testGetName() throws Exception {
  InMemoryOrderedTableService.create("String_Node_Str");
  MetricsTable table=new InMemoryMetricsTable("String_Node_Str");
  EntityTable entityTable=new EntityTable(table);
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals("String_Node_Str" + i,entityTable.getName(i,"String_Node_Str"));
  }
}

Fixed version (ground truth):
@Test public void testGetName() throws Exception {
  InMemoryTableService.create("String_Node_Str");
  MetricsTable table=new InMemoryMetricsTable("String_Node_Str");
  EntityTable entityTable=new EntityTable(table);
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals((long)i,entityTable.getId("String_Node_Str","String_Node_Str" + i));
  }
  for (int i=1; i <= 10; i++) {
    Assert.assertEquals("String_Node_Str" + i,entityTable.getName(i,"String_Node_Str"));
  }
}
Program: 7277
Project: 7277
Buggy source:
@Override protected Cube getCube(String name,int[] resolutions,Collection<? extends Aggregation> aggregations){
  FactTableSupplier supplier=new FactTableSupplier(){
    @Override public FactTable get(    int resolution,    int rollTime){
      InMemoryOrderedTableService.create("String_Node_Str");
      InMemoryOrderedTableService.create("String_Node_Str");
      return new FactTable(new InMemoryMetricsTable("String_Node_Str"),new EntityTable(new InMemoryMetricsTable("String_Node_Str")),resolution,rollTime);
    }
  }
;
  return new DefaultCube(resolutions,supplier,aggregations);
}

Fixed version (ground truth):
@Override protected Cube getCube(String name,int[] resolutions,Collection<? extends Aggregation> aggregations){
  FactTableSupplier supplier=new FactTableSupplier(){
    @Override public FactTable get(    int resolution,    int rollTime){
      InMemoryTableService.create("String_Node_Str");
      InMemoryTableService.create("String_Node_Str");
      return new FactTable(new InMemoryMetricsTable("String_Node_Str"),new EntityTable(new InMemoryMetricsTable("String_Node_Str")),resolution,rollTime);
    }
  }
;
  return new DefaultCube(resolutions,supplier,aggregations);
}
Program: 7278
Project: 7278
Buggy source:
@Override public FactTable get(int resolution,int rollTime){
  InMemoryOrderedTableService.create("String_Node_Str");
  InMemoryOrderedTableService.create("String_Node_Str");
  return new FactTable(new InMemoryMetricsTable("String_Node_Str"),new EntityTable(new InMemoryMetricsTable("String_Node_Str")),resolution,rollTime);
}

Fixed version (ground truth):
@Override public FactTable get(int resolution,int rollTime){
  InMemoryTableService.create("String_Node_Str");
  InMemoryTableService.create("String_Node_Str");
  return new FactTable(new InMemoryMetricsTable("String_Node_Str"),new EntityTable(new InMemoryMetricsTable("String_Node_Str")),resolution,rollTime);
}
Program: 7279
Project: 7279
Buggy source:
@Test public void testMaxResolution() throws Exception {
  InMemoryOrderedTableService.create("String_Node_Str");
  InMemoryOrderedTableService.create("String_Node_Str");
  int resolution=Integer.MAX_VALUE;
  int rollTimebaseInterval=3600;
  FactTable table=new FactTable(new InMemoryMetricsTable("String_Node_Str"),new EntityTable(new InMemoryMetricsTable("String_Node_Str")),resolution,rollTimebaseInterval);
  long ts=System.currentTimeMillis() / 1000;
  int count=1000;
  for (int i=0; i < count; i++) {
    for (int k=0; k < 10; k++) {
      writeInc(table,"String_Node_Str" + k,ts + i * 60 * 60* 24,i * k,"String_Node_Str" + k,"String_Node_Str" + k);
    }
  }
  for (int k=0; k < 10; k++) {
    FactScan scan=new FactScan(0,0,"String_Node_Str" + k,tagValues("String_Node_Str" + k,"String_Node_Str" + k));
    Table<String,List<TagValue>,List<TimeValue>> expected=HashBasedTable.create();
    expected.put("String_Node_Str" + k,tagValues("String_Node_Str" + k,"String_Node_Str" + k),ImmutableList.of(new TimeValue(0,k * count * (count - 1) / 2)));
    assertScan(table,expected,scan);
  }
}

Fixed version (ground truth):
@Test public void testMaxResolution() throws Exception {
  InMemoryTableService.create("String_Node_Str");
  InMemoryTableService.create("String_Node_Str");
  int resolution=Integer.MAX_VALUE;
  int rollTimebaseInterval=3600;
  FactTable table=new FactTable(new InMemoryMetricsTable("String_Node_Str"),new EntityTable(new InMemoryMetricsTable("String_Node_Str")),resolution,rollTimebaseInterval);
  long ts=System.currentTimeMillis() / 1000;
  int count=1000;
  for (int i=0; i < count; i++) {
    for (int k=0; k < 10; k++) {
      writeInc(table,"String_Node_Str" + k,ts + i * 60 * 60* 24,i * k,"String_Node_Str" + k,"String_Node_Str" + k);
    }
  }
  for (int k=0; k < 10; k++) {
    FactScan scan=new FactScan(0,0,"String_Node_Str" + k,tagValues("String_Node_Str" + k,"String_Node_Str" + k));
    Table<String,List<TagValue>,List<TimeValue>> expected=HashBasedTable.create();
    expected.put("String_Node_Str" + k,tagValues("String_Node_Str" + k,"String_Node_Str" + k),ImmutableList.of(new TimeValue(0,k * count * (count - 1) / 2)));
    assertScan(table,expected,scan);
  }
}
Program: 7280
Project: 7280
Buggy source:
@GET @Path("String_Node_Str") public void workflowStatus(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String workflowName){
  programLifecycleHttpHandler.workflowStatus(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,workflowName);
}

Fixed version (ground truth):
@GET @Path("String_Node_Str") public void workflowStatus(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String workflowName){
  programLifecycleHttpHandler.workflowStatus(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,workflowName);
}
Program: 7281
Project: 7281
Buggy source:
/** 
 * Returns specification of a runnable - flow.
 */
@GET @Path("String_Node_Str") public void flowSpecification(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String flowId){
  programLifecycleHttpHandler.runnableSpecification(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,ProgramType.FLOW.getCategoryName(),flowId);
}

Fixed version (ground truth):
/** 
 * Returns specification of a runnable - flow.
 */
@GET @Path("String_Node_Str") public void flowSpecification(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String flowId){
  programLifecycleHttpHandler.runnableSpecification(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,ProgramType.FLOW.getCategoryName(),flowId);
}
Program: 7282
Project: 7282
Buggy source:
/** 
 * Returns a list of procedure associated with account & application.
 */
@GET @Path("String_Node_Str") public void getMapreduceByApp(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId){
  programLifecycleHttpHandler.getProgramsByApp(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,ProgramType.MAPREDUCE.getCategoryName());
}

Fixed version (ground truth):
/** 
 * Returns a list of mapreduce associated with account & application.
 */
@GET @Path("String_Node_Str") public void getMapreduceByApp(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId){
  programLifecycleHttpHandler.getMapreduceByApp(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId);
}
Program: 7283
Project: 7283
Buggy source:
/** 
 * Returns status of a type specified by {flows,workflows,mapreduce,spark,procedures,services,schedules}.
 */
@GET @Path("String_Node_Str") public void getStatus(final HttpRequest request,final HttpResponder responder,@PathParam("String_Node_Str") final String appId,@PathParam("String_Node_Str") final String type,@PathParam("String_Node_Str") final String id){
  programLifecycleHttpHandler.getStatus(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,type,id);
}

Fixed version (ground truth):
/** 
 * Returns status of a type specified by {flows,workflows,mapreduce,spark,procedures,services,schedules}.
 */
@GET @Path("String_Node_Str") public void getStatus(final HttpRequest request,final HttpResponder responder,@PathParam("String_Node_Str") final String appId,@PathParam("String_Node_Str") final String type,@PathParam("String_Node_Str") final String id){
  programLifecycleHttpHandler.getStatus(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,type,id);
}
Program: 7284
Project: 7284
Buggy source:
/** 
 * Deploys an application.
 */
@POST @Path("String_Node_Str") public BodyConsumer deploy(HttpRequest request,HttpResponder responder,@HeaderParam(ARCHIVE_NAME_HEADER) final String archiveName){
  try {
    return appLifecycleHttpHandler.deploy(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,null,archiveName);
  }
 catch (  Exception ex) {
    responder.sendString(HttpResponseStatus.INTERNAL_SERVER_ERROR,"String_Node_Str" + ex.getMessage());
    return null;
  }
}

Fixed version (ground truth):
/** 
 * Deploys an application.
 */
@POST @Path("String_Node_Str") public BodyConsumer deploy(HttpRequest request,HttpResponder responder,@HeaderParam(ARCHIVE_NAME_HEADER) final String archiveName){
  try {
    return appLifecycleHttpHandler.deploy(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,null,archiveName);
  }
 catch (  Exception ex) {
    responder.sendString(HttpResponseStatus.INTERNAL_SERVER_ERROR,"String_Node_Str" + ex.getMessage());
    return null;
  }
}
Program: 7285
Project: 7285
Buggy source:
/** 
 * Returns program runs based on options it returns either currently running or completed or failed. Default it returns all.
 */
@GET @Path("String_Node_Str") public void runnableHistory(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String runnableType,@PathParam("String_Node_Str") String runnableId,@QueryParam("String_Node_Str") String status,@QueryParam("String_Node_Str") String startTs,@QueryParam("String_Node_Str") String endTs,@QueryParam("String_Node_Str") @DefaultValue("String_Node_Str") final int resultLimit){
  programLifecycleHttpHandler.runnableHistory(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,runnableType,runnableId,status,startTs,endTs,resultLimit);
}

Fixed version (ground truth):
/** 
 * Returns program runs based on options it returns either currently running or completed or failed. Default it returns all.
 */
@GET @Path("String_Node_Str") public void runnableHistory(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String runnableType,@PathParam("String_Node_Str") String runnableId,@QueryParam("String_Node_Str") String status,@QueryParam("String_Node_Str") String startTs,@QueryParam("String_Node_Str") String endTs,@QueryParam("String_Node_Str") @DefaultValue("String_Node_Str") final int resultLimit){
  programLifecycleHttpHandler.runnableHistory(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,runnableType,runnableId,status,startTs,endTs,resultLimit);
}
Program: 7286
Project: 7286
Buggy source:
/** 
 * Returns specification of workflow.
 */
@GET @Path("String_Node_Str") public void workflowSpecification(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") final String appId,@PathParam("String_Node_Str") final String workflowId){
  programLifecycleHttpHandler.runnableSpecification(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,ProgramType.WORKFLOW.getCategoryName(),workflowId);
}

Fixed version (ground truth):
/** 
 * Returns specification of workflow.
 */
@GET @Path("String_Node_Str") public void workflowSpecification(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") final String appId,@PathParam("String_Node_Str") final String workflowId){
  programLifecycleHttpHandler.runnableSpecification(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,ProgramType.WORKFLOW.getCategoryName(),workflowId);
}
Program: 7287
Project: 7287
Buggy source:
/** 
 * Returns a list of procedure associated with account & application.
 */
@GET @Path("String_Node_Str") public void getFlowsByApp(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId){
  programLifecycleHttpHandler.getProgramsByApp(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,ProgramType.FLOW.getCategoryName());
}

Fixed version (ground truth):
/** 
 * Returns a list of flows associated with account & application.
 */
@GET @Path("String_Node_Str") public void getFlowsByApp(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId){
  programLifecycleHttpHandler.getFlowsByApp(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId);
}
Program: 7288
Project: 7288
Buggy source:
/** 
 * Returns a list of applications associated with an account.
 */
@GET @Path("String_Node_Str") public void getAllApps(HttpRequest request,HttpResponder responder){
  appLifecycleHttpHandler.getAllApps(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE);
}

Fixed version (ground truth):
/** 
 * Returns a list of applications associated with an account.
 */
@GET @Path("String_Node_Str") public void getAllApps(HttpRequest request,HttpResponder responder){
  appLifecycleHttpHandler.getAllApps(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE);
}
Program: 7289
Project: 7289
Buggy source:
/** 
 * Returns a list of spark jobs associated with account & application.
 */
@GET @Path("String_Node_Str") public void getSparkByApp(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId){
  programLifecycleHttpHandler.getProgramsByApp(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,ProgramType.SPARK.getCategoryName());
}

Fixed version (ground truth):
/** 
 * Returns a list of spark jobs associated with account & application.
 */
@GET @Path("String_Node_Str") public void getSparkByApp(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId){
  programLifecycleHttpHandler.getSparkByApp(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId);
}
Program: 7290
Project: 7290
Buggy source:
/** 
 * Changes input stream for a flowlet connection.
 */
@PUT @Path("String_Node_Str") public void changeFlowletStreamConnection(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String flowId,@PathParam("String_Node_Str") String flowletId,@PathParam("String_Node_Str") String streamId) throws IOException {
  programLifecycleHttpHandler.changeFlowletStreamConnection(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,flowId,flowletId,streamId);
}

Fixed version (ground truth):
/** 
 * Changes input stream for a flowlet connection.
 */
@PUT @Path("String_Node_Str") public void changeFlowletStreamConnection(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String flowId,@PathParam("String_Node_Str") String flowletId,@PathParam("String_Node_Str") String streamId) throws IOException {
  programLifecycleHttpHandler.changeFlowletStreamConnection(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,flowId,flowletId,streamId);
}
Program: 7291
Project: 7291
Buggy source:
/** 
 * Returns the schedule ids for a given workflow.
 */
@GET @Path("String_Node_Str") public void getWorkflowSchedules(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String workflowId){
  programLifecycleHttpHandler.getWorkflowSchedules(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,workflowId);
}

Fixed version (ground truth):
/** 
 * Returns the schedule ids for a given workflow.
 */
@GET @Path("String_Node_Str") public void getWorkflowSchedules(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String workflowId){
  programLifecycleHttpHandler.getWorkflowSchedules(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,workflowId);
}
Program: 7292
Project: 7292
Buggy source:
/** 
 * Deletes queues.
 */
@DELETE @Path("String_Node_Str") public void deleteFlowQueues(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String flowId){
  programLifecycleHttpHandler.deleteFlowQueues(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,flowId);
}

Fixed version (ground truth):
/** 
 * Deletes queues.
 */
@DELETE @Path("String_Node_Str") public void deleteFlowQueues(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String flowId){
  programLifecycleHttpHandler.deleteFlowQueues(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,flowId);
}
Program: 7293
Project: 7293
Buggy source:
@GET @Path("String_Node_Str") public void serviceSpecification(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String serviceId){
  programLifecycleHttpHandler.runnableSpecification(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,ProgramType.SERVICE.getCategoryName(),serviceId);
}

Fixed version (ground truth):
@GET @Path("String_Node_Str") public void serviceSpecification(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String serviceId){
  programLifecycleHttpHandler.runnableSpecification(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,ProgramType.SERVICE.getCategoryName(),serviceId);
}
Program: 7294
Project: 7294
Buggy source:
/** 
 * Gets number of instances for a worker.
 */
@GET @Path("String_Node_Str") public void getWorkerInstances(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") final String appId,@PathParam("String_Node_Str") final String workerId){
  programLifecycleHttpHandler.getWorkerInstances(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,workerId);
}

Fixed version (ground truth):
/** 
 * Gets number of instances for a worker.
 */
@GET @Path("String_Node_Str") public void getWorkerInstances(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") final String appId,@PathParam("String_Node_Str") final String workerId){
  programLifecycleHttpHandler.getWorkerInstances(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,workerId);
}
Program: 7295
Project: 7295
Buggy source:
/** 
 * Resume a schedule.
 */
@POST @Path("String_Node_Str") public void resumeSchedule(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String scheduleName){
  programLifecycleHttpHandler.performAction(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE,appId,"String_Node_Str",scheduleName,"String_Node_Str");
}

Fixed version (ground truth):
/** 
 * Resume a schedule.
 */
@POST @Path("String_Node_Str") public void resumeSchedule(HttpRequest request,HttpResponder responder,@PathParam("String_Node_Str") String appId,@PathParam("String_Node_Str") String scheduleName){
  programLifecycleHttpHandler.performAction(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE,appId,"String_Node_Str",scheduleName,"String_Node_Str");
}
Program: 7296
Project: 7296
Buggy source:
/** 
 * Returns a list of map/reduces associated with an account.
 */
@GET @Path("String_Node_Str") public void getAllMapReduce(HttpRequest request,HttpResponder responder){
  programLifecycleHttpHandler.getAllMapReduce(rewriteRequest(request),responder,Constants.DEFAULT_NAMESPACE);
}

Fixed version (ground truth):
/** 
 * Returns a list of map/reduces associated with an account.
 */
@GET @Path("String_Node_Str") public void getAllMapReduce(HttpRequest request,HttpResponder responder){
  programLifecycleHttpHandler.getAllMapReduce(RESTMigrationUtils.rewriteV2RequestToV3(request),responder,Constants.DEFAULT_NAMESPACE);
}