[freeside-commits] branch FREESIDE_4_BRANCH updated. b6785c0b3eef8cce1d67c53824d00a1afd9cc36a

Ivan Kohler ivan at freeside.biz
Wed Apr 18 18:03:11 PDT 2018


The branch, FREESIDE_4_BRANCH has been updated
       via  b6785c0b3eef8cce1d67c53824d00a1afd9cc36a (commit)
      from  f9dc3d967e8c8d05a151f3035786b14888046d6f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit b6785c0b3eef8cce1d67c53824d00a1afd9cc36a
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Wed Apr 18 18:03:10 2018 -0700

    ip allocation mutex for high-traffic implementations, RT#79825

diff --git a/FS/FS/IP_Mixin.pm b/FS/FS/IP_Mixin.pm
index beb41d290..3ec769313 100644
--- a/FS/FS/IP_Mixin.pm
+++ b/FS/FS/IP_Mixin.pm
@@ -130,6 +130,10 @@ sub assign_ip_addr {
   my $self = shift;
   my %opt = @_;
 
+  #otherwise we'll get the same assignment for concurrent identical calls
+  # this will serialize them
+  $_->lock_table foreach @subclasses;
+
   my @blocks;
   my $na = $self->NetAddr;
 

-----------------------------------------------------------------------

Summary of changes:
 FS/FS/IP_Mixin.pm | 4 ++++
 1 file changed, 4 insertions(+)




More information about the freeside-commits mailing list