PmaRegistryImpl implements PmaRegistry { public void deviceRemoved(String deviceName) { m_pmaSessionPool.clear(deviceName); m_factory.deviceDeleted(deviceName); } PmaRegistryImpl(DeviceManager deviceManager,
                           PmaSessionFactory factory); @Override @Transactional(value = Transactional.TxType.REQUIRED, rollbackOn = {RuntimeException.class, Exception.class}) Map<NetConfResponse, List<Notification>> executeNC(String deviceName, String netconfRequest); @Override RT executeWithPmaSession(String deviceName, PmaSessionTemplate<RT> sessionTemplate); @Override void forceAlign(String deviceName); @Override void align(String deviceName); void deviceRemoved(String deviceName); @Override NetConfResponse getAllPersistCfg(String deviceName); static final String COMPONENT_ID; }
@Test public void testDeviceRemoved() throws ExecutionException { m_pmaRegistry.deviceRemoved("device1"); m_pmaRegistry.executeWithPmaSession("device1", session -> "response"); }