Program: 132171
Project: 132171
Buggy source:
@Override public java.lang.AutoCloseable createInstance(){
  SfcProviderLogbackLoader.loadSfcLogbackConfiguration();
  final OpendaylightSfc opendaylightSfc=new OpendaylightSfc();
  DataBroker dataBrokerService=getDataBrokerDependency();
  opendaylightSfc.setDataProvider(dataBrokerService);
  final SfcProviderRpc sfcProviderRpc=new SfcProviderRpc();
  SfcProviderSffEntryDataListener sfcProviderSffEntryDataListener=new SfcProviderSffEntryDataListener();
  final ListenerRegistration<DataChangeListener> sffDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.sffIID,sfcProviderSffEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderSfEntryDataListener sfcProviderSfEntryDataListener=new SfcProviderSfEntryDataListener();
  final ListenerRegistration<DataChangeListener> sfEntryDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.sfEntryIID,sfcProviderSfEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderSfcEntryDataListener sfcProviderSfcEntryDataListener=new SfcProviderSfcEntryDataListener();
  final ListenerRegistration<DataChangeListener> sfcEntryDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.sfcEntryIID,sfcProviderSfcEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderScfEntryDataListener sfcProviderScfEntryDataListener=new SfcProviderScfEntryDataListener();
  final ListenerRegistration<DataChangeListener> scfEntryDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.scfEntryIID,sfcProviderScfEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderSfpEntryDataListener sfcProviderSfpEntryDataListener=new SfcProviderSfpEntryDataListener();
  final ListenerRegistration<DataChangeListener> sfpEntryDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.sfpEntryIID,sfcProviderSfpEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderSfpDataListener sfcProviderSfpDataListener=new SfcProviderSfpDataListener();
  final ListenerRegistration<DataChangeListener> sfpDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.sfpIID,sfcProviderSfpDataListener,DataBroker.DataChangeScope.SUBTREE);
  final BindingAwareBroker.RpcRegistration<ServiceFunctionService> sfRpcRegistration=getRpcRegistryDependency().addRpcImplementation(ServiceFunctionService.class,sfcProviderRpc);
  final BindingAwareBroker.RpcRegistration<ServiceFunctionChainService> sfcRpcRegistration=getRpcRegistryDependency().addRpcImplementation(ServiceFunctionChainService.class,sfcProviderRpc);
  final BindingAwareBroker.RpcRegistration<ServiceNodeService> snRpcRegistration=getRpcRegistryDependency().addRpcImplementation(ServiceNodeService.class,sfcProviderRpc);
final class AutoCloseableSfc implements AutoCloseable {
    @Override public void close(){
      sfEntryDataChangeListenerRegistration.close();
      sfcEntryDataChangeListenerRegistration.close();
      scfEntryDataChangeListenerRegistration.close();
      sfpEntryDataChangeListenerRegistration.close();
      sffDataChangeListenerRegistration.close();
      sfRpcRegistration.close();
      sfcRpcRegistration.close();
      snRpcRegistration.close();
      try {
        opendaylightSfc.close();
      }
 catch (      ExecutionException|InterruptedException e) {
        LOG.error("String_Node_Str" + "String_Node_Str",this);
      }
      LOG.info("String_Node_Str",this);
    }
  }
  AutoCloseable ret=new AutoCloseableSfc();
  Object[] emptyObjArray={};
  Class[] emptyClassArray={};
  ScheduledExecutorService scheduledExecutorService=Executors.newScheduledThreadPool(1);
  scheduledExecutorService.schedule(SfcProviderBootstrapRestAPI.getPutBootstrapData(emptyObjArray,emptyClassArray),15,TimeUnit.SECONDS);
  scheduledExecutorService.shutdown();
  LOG.info("String_Node_Str",ret);
  return ret;
}

Fixed version (ground truth):
@Override public java.lang.AutoCloseable createInstance(){
  SfcProviderLogbackLoader.loadSfcLogbackConfiguration();
  final OpendaylightSfc opendaylightSfc=new OpendaylightSfc();
  DataBroker dataBrokerService=getDataBrokerDependency();
  opendaylightSfc.setDataProvider(dataBrokerService);
  final SfcProviderRpc sfcProviderRpc=new SfcProviderRpc();
  SfcProviderSffEntryDataListener sfcProviderSffEntryDataListener=new SfcProviderSffEntryDataListener();
  final ListenerRegistration<DataChangeListener> sffDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.SFF_IID,sfcProviderSffEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderSfEntryDataListener sfcProviderSfEntryDataListener=new SfcProviderSfEntryDataListener();
  final ListenerRegistration<DataChangeListener> sfEntryDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.SF_ENTRY_IID,sfcProviderSfEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderSfcEntryDataListener sfcProviderSfcEntryDataListener=new SfcProviderSfcEntryDataListener();
  final ListenerRegistration<DataChangeListener> sfcEntryDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.SFC_ENTRY_IID,sfcProviderSfcEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderScfEntryDataListener sfcProviderScfEntryDataListener=new SfcProviderScfEntryDataListener();
  final ListenerRegistration<DataChangeListener> scfEntryDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.SCF_ENTRY_IID,sfcProviderScfEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderSfpEntryDataListener sfcProviderSfpEntryDataListener=new SfcProviderSfpEntryDataListener();
  final ListenerRegistration<DataChangeListener> sfpEntryDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.SFP_ENTRY_IID,sfcProviderSfpEntryDataListener,DataBroker.DataChangeScope.SUBTREE);
  SfcProviderSfpDataListener sfcProviderSfpDataListener=new SfcProviderSfpDataListener();
  final ListenerRegistration<DataChangeListener> sfpDataChangeListenerRegistration=dataBrokerService.registerDataChangeListener(LogicalDatastoreType.CONFIGURATION,OpendaylightSfc.SFP_IID,sfcProviderSfpDataListener,DataBroker.DataChangeScope.SUBTREE);
  final BindingAwareBroker.RpcRegistration<ServiceFunctionService> sfRpcRegistration=getRpcRegistryDependency().addRpcImplementation(ServiceFunctionService.class,sfcProviderRpc);
  final BindingAwareBroker.RpcRegistration<ServiceFunctionChainService> sfcRpcRegistration=getRpcRegistryDependency().addRpcImplementation(ServiceFunctionChainService.class,sfcProviderRpc);
  final BindingAwareBroker.RpcRegistration<ServiceNodeService> snRpcRegistration=getRpcRegistryDependency().addRpcImplementation(ServiceNodeService.class,sfcProviderRpc);
final class AutoCloseableSfc implements AutoCloseable {
    @Override public void close(){
      sfEntryDataChangeListenerRegistration.close();
      sfcEntryDataChangeListenerRegistration.close();
      scfEntryDataChangeListenerRegistration.close();
      sfpEntryDataChangeListenerRegistration.close();
      sffDataChangeListenerRegistration.close();
      sfRpcRegistration.close();
      sfcRpcRegistration.close();
      snRpcRegistration.close();
      try {
        opendaylightSfc.close();
      }
 catch (      ExecutionException|InterruptedException e) {
        LOG.error("String_Node_Str" + "String_Node_Str",this);
      }
      LOG.info("String_Node_Str",this);
    }
  }
  AutoCloseable ret=new AutoCloseableSfc();
  Object[] emptyObjArray={};
  Class[] emptyClassArray={};
  ScheduledExecutorService scheduledExecutorService=Executors.newScheduledThreadPool(1);
  scheduledExecutorService.schedule(SfcProviderBootstrapRestAPI.getPutBootstrapData(emptyObjArray,emptyClassArray),15,TimeUnit.SECONDS);
  scheduledExecutorService.shutdown();
  LOG.info("String_Node_Str",ret);
  return ret;
}