Skip to content
Snippets Groups Projects
Commit 90af4ce0 authored by Raphael GIRARDOT's avatar Raphael GIRARDOT
Browse files

HdbExtractor DbProxy can throw an ArchivingException (should help TANGOARCH-548)

parent 91fac421
No related branches found
No related tags found
No related merge requests found
...@@ -44,8 +44,6 @@ ...@@ -44,8 +44,6 @@
//-====================================================================== //-======================================================================
package HdbExtractor.Proxy; package HdbExtractor.Proxy;
import org.tango.utils.DevFailedUtils;
import fr.esrf.Tango.DevFailed; import fr.esrf.Tango.DevFailed;
import fr.soleil.archiving.common.api.ConnectionFactory; import fr.soleil.archiving.common.api.ConnectionFactory;
import fr.soleil.archiving.common.api.exception.ArchivingException; import fr.soleil.archiving.common.api.exception.ArchivingException;
...@@ -58,16 +56,14 @@ public class DbProxy { ...@@ -58,16 +56,14 @@ public class DbProxy {
private IArchivingManagerApiRef manager; private IArchivingManagerApiRef manager;
public DbProxy(final String myDbHost, final String myDbName, final String mySchemaName, final String myDbUser, public DbProxy(final String myDbHost, final String myDbName, final String mySchemaName, final String myDbUser,
final String myDbPassword, final boolean myRacConnection) { final String myDbPassword, final boolean myRacConnection) throws ArchivingException {
try { try {
manager = ArchivingManagerApiRefFactory.getInstance(true, ConnectionFactory.connectThroughTango( manager = ArchivingManagerApiRefFactory.getInstance(true, ConnectionFactory.connectThroughTango(
"HdbExtractor", ConfigConst.HDB_CLASS_DEVICE, myDbHost, myDbName, mySchemaName, myDbUser, "HdbExtractor", ConfigConst.HDB_CLASS_DEVICE, myDbHost, myDbName, mySchemaName, myDbUser,
myDbPassword, null, null, myRacConnection, false, true)); myDbPassword, null, null, myRacConnection, false, true));
manager.archivingConfigureWithoutArchiverListInit(); manager.archivingConfigureWithoutArchiverListInit();
} catch (final ArchivingException e) {
System.err.println(e.toString());
} catch (DevFailed e) { } catch (DevFailed e) {
System.err.println(DevFailedUtils.toString(e)); throw new ArchivingException(e);
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment