LGTM, thanks.
On Mon, Oct 7, 2013 at 4:38 PM, Jose A. Lopes <[email protected]> wrote: > Add opcode related constants to the Haskell to Python constant generation. > > Signed-off-by: Jose A. Lopes <[email protected]> > --- > lib/constants.py | 20 ++++++-------------- > src/Ganeti/HsConstants.hs | 25 +++++++++++++++++++++++++ > 2 files changed, 31 insertions(+), 14 deletions(-) > > diff --git a/lib/constants.py b/lib/constants.py > index 169687b..196e7e8 100644 > --- a/lib/constants.py > +++ b/lib/constants.py > @@ -1550,20 +1550,12 @@ BUILTIN_DATA_COLLECTOR_VERSION = > _constants.BUILTIN_DATA_COLLECTOR_VERSION > > OPCODE_REASON = _constants.OPCODE_REASON > > -# The source reasons for the execution of an OpCode > -OPCODE_REASON_SRC_CLIENT = "gnt:client" > -OPCODE_REASON_SRC_NODED = "gnt:daemon:noded" > -OPCODE_REASON_SRC_OPCODE = "gnt:opcode" > -OPCODE_REASON_SRC_RLIB2 = "gnt:library:rlib2" > -OPCODE_REASON_SRC_USER = "gnt:user" > - > -OPCODE_REASON_SOURCES = compat.UniqueFrozenset([ > - OPCODE_REASON_SRC_CLIENT, > - OPCODE_REASON_SRC_NODED, > - OPCODE_REASON_SRC_OPCODE, > - OPCODE_REASON_SRC_RLIB2, > - OPCODE_REASON_SRC_USER, > - ]) > +OPCODE_REASON_SRC_CLIENT = _constants.OPCODE_REASON_SRC_CLIENT > +OPCODE_REASON_SRC_NODED = _constants.OPCODE_REASON_SRC_NODED > +OPCODE_REASON_SRC_OPCODE = _constants.OPCODE_REASON_SRC_OPCODE > +OPCODE_REASON_SRC_RLIB2 = _constants.OPCODE_REASON_SRC_RLIB2 > +OPCODE_REASON_SRC_USER = _constants.OPCODE_REASON_SRC_USER > +OPCODE_REASON_SOURCES = _constants.OPCODE_REASON_SOURCES > > DISKSTATS_FILE = _constants.DISKSTATS_FILE > > diff --git a/src/Ganeti/HsConstants.hs b/src/Ganeti/HsConstants.hs > index ec2177f..555a4af 100644 > --- a/src/Ganeti/HsConstants.hs > +++ b/src/Ganeti/HsConstants.hs > @@ -3748,6 +3748,31 @@ ndsSsconf = "ssconf" > ndsStartNodeDaemon :: String > ndsStartNodeDaemon = "start_node_daemon" > > +-- * The source reasons for the execution of an OpCode > + > +opcodeReasonSrcClient :: String > +opcodeReasonSrcClient = "gnt:client" > + > +opcodeReasonSrcNoded :: String > +opcodeReasonSrcNoded = "gnt:daemon:noded" > + > +opcodeReasonSrcOpcode :: String > +opcodeReasonSrcOpcode = "gnt:opcode" > + > +opcodeReasonSrcRlib2 :: String > +opcodeReasonSrcRlib2 = "gnt:library:rlib2" > + > +opcodeReasonSrcUser :: String > +opcodeReasonSrcUser = "gnt:user" > + > +opcodeReasonSources :: FrozenSet String > +opcodeReasonSources = > + ConstantUtils.mkSet [opcodeReasonSrcClient, > + opcodeReasonSrcNoded, > + opcodeReasonSrcOpcode, > + opcodeReasonSrcRlib2, > + opcodeReasonSrcUser] > + > -- | Path generating random UUID > randomUuidFile :: String > randomUuidFile = ConstantUtils.randomUuidFile > -- > 1.8.4 > > -- Thomas Thrainer | Software Engineer | [email protected] | Google Germany GmbH Dienerstr. 12 80331 München Registergericht und -nummer: Hamburg, HRB 86891 Sitz der Gesellschaft: Hamburg Geschäftsführer: Graham Law, Christine Elizabeth Flores
