Forum Discussion

eoas74_27325's avatar
eoas74_27325
Icon for Nimbostratus rankNimbostratus
Oct 01, 2009

Feature request: file changed on disk warning

It happened again. I and my colleagues has overwritten each others changes by forgetting to refresh the list of iRules before starting to work.

 

 

I would love to see the iRule Editor taking note of the timestamp of the config when loading the rules and then checking the timestamp again when one tries to save a change and throw a warning if the config on disk is newer than the one being modified in the editor.

 

 

Of course, mutual exclusive file locking of the config would be even better, but I think it would be hard to get and still have the possibility to update the config directly as well as through the web-gui and the iRule Editor.

 

 

Would anyone else be interested in such a feature?

 

 

Best Regards /eoas74
  • The bigger problem is now that the iRule Editor can be toggled to not automatically flush changes to disk, one user could make a change to the running config and the config file on disk will not be updated.

     

     

    We have a voluntary locking mechanism in the iControl API and it might be a good idea to include support in the iRule editor. I'll take a look at that next week. Thanks for the feedback and I'll let you know how it goes. This wouldn't extend across the GUI or CLI but it would support multiple iRule Editor users.

     

     

    Another idea could be to query the iRule before saving it to see if it's changed since the last time requested. I keep a copy of the original iRule in the Editor's buffer to support the "Reset" right click option. This could be compared against a newly created iRule.

     

     

    BTW, I really appreciate this kind of feedback as it gives me ideas how the Editor is used in the wild and ideas for adding new features. Please pass along anything else you would like enhanced or changed in it and I'll see what I can come up with.

     

     

    -Joe
  • Glad to be of service.

     

     

    You idea of querying the iRule at hand before saving and comparing it to the original iRule in buffer sounds like the right way to go. A simple warning when the rule has changed would save me and my colleagues a lot of trouble.

     

     

    Best Regards /eoas74