File Mover Blog

  • 06 Jul

    Variable for Rule ID in Limagito File Mover

    Variable for Rule ID in Limagito File Mover
    Q: We are running a ‘On Event’ command  to log to our database: sqlcmd -S gp-db4 -d  etc….
    I see there is a variable for Rule name, %RRN but can not see one for the Rule ID.
    limagito file mover Variable for Rule ID
    Why this is important is the Rule name will change and need to use the RuleID as a key. Is this possible?

    A: In version v2025.6.20.0 we added a new Variable:

    Parameters, Added %RRI = Rule, Rule ID

    Customer: That was the ticket!

    CMD /C sqlcmd -S gp-db4.??????.com -d xyzman -U LIMAGITO_STATUS -P <PWD> -Q “EXEC [dbo].[Limagito_OnSuccess] @Server=’%COMPUTERNAME%’, @RuleId=’%RRI'”

    If you need any help with this question, please let us know.

    Best Regards,

    Limagito Team

    #managedfiletransfer #filetransfer #filemanagement

    By Limagito-Team Parameters ,
  • 06 Jul

    Having 10 or more groups and want to reference group 1 in RegEx

    Having 10 or more groups and want to reference group 1 in RegEx

    Q: This regex rename is under the unzip…

    My intent is to fix the lack of a leading zero in the MM field of the file name but limagito is seeing it as capture group 10, not capture group 1 with a zero after it.
    Escaping the zero didn’t work either. Is there something else i could have done?
    I eventually hard coded the 2025, because hopefully this is a 1 off error anyway.

    limagito file mover reference group 1 in RegEx

    A: You’ve identified a classic regex gotcha! When you have 10 or more groups and want to reference group 1 followed by a literal “0”, the regex engine interprets `\10` as group 10 instead of group 1 + “0”.

    Here is a solution to solve this: Use \g<n> syntax (most regex flavors)
    # Instead of: \10
    # Use: \g<1>0

    If you need any help with this ‘reference group 1 in RegEx’ question, please let us know.

    Best Regards,

    Limagito Team

    #regex #managedfiletransfer #filetransfer #filemanagement

    By Limagito-Team Rename
  • 06 Jul

    Python Thread Exec Mode setup within Limagito File Mover

    Python Thread Exec Mode setup within Limagito File Mover

    In version v2025.6.7.0 we added a “Global Python” setup option.

    limagito file mover global python setup

    The GIL (Global Interpreter Lock) in Python is a mutex (mutual exclusion lock) that protects access to Python objects, ensuring that only one thread executes Python bytecode at a time, even on multi-core processors.

    We added two Thread Exec Modes:

    New Interpreter

    • Each thread gets its own Python interpreter state (Py_NewInterpreter).
    • Shared global interpreter (GIL) lock, but separate Python states.
    • Useful when isolation between threads is desired.
    • Each interpreter is independent: global variables, modules, and sys state are not shared.
    • Not all Python C modules work well in sub-interpreters (some share global state unsafely).
    • Use this when:
      • You need full isolation between threads (like sandboxing).
      • You can tolerate potential issues with C extension compatibility.

    New Interpreter Own GIL

    • Same as “New Interpreter”, but each thread also manages its own GIL state.
    • This mode gives each thread its own Python interpreter + GIL state.
    • Makes thread-safe management of the Python GIL easier.
    • Internally uses PyEval_SaveThread / PyEval_RestoreThread.
    • Use this when:
      • You want per-thread interpreters with clean GIL handling.
      • You want Python output or state kept separate per thread (e.g. in logs).
      • This is the recommended mode when you want each thread to run Python independently.

    limagito file mover Python Thread Exec Mode

    If you need any help with this ‘Python Thread Exec Mode’ option, please let us know.

    Best Regards,

    Limagito Team

    #python #managedfiletransfer #filetransfer #filemanagement

    By Limagito-Team Python
1 2 3 4 155
SEARCH