[LON-CAPA-cvs] cvs: loncom /interface loncommon.pm
raeburn
raeburn at source.lon-capa.org
Thu Jan 28 21:28:32 EST 2021
raeburn Fri Jan 29 02:28:32 2021 EDT
Modified files:
/loncom/interface loncommon.pm
Log:
- For users from a different institution if current server's offload
targets are all set to switch on next access, set the offload target
to the least loaded server in the user's domain.
Index: loncom/interface/loncommon.pm
diff -u loncom/interface/loncommon.pm:1.1352 loncom/interface/loncommon.pm:1.1353
--- loncom/interface/loncommon.pm:1.1352 Thu Jan 28 22:12:53 2021
+++ loncom/interface/loncommon.pm Fri Jan 29 02:28:32 2021
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# a pile of common routines
#
-# $Id: loncommon.pm,v 1.1352 2021/01/28 22:12:53 raeburn Exp $
+# $Id: loncommon.pm,v 1.1353 2021/01/29 02:28:32 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -8603,6 +8603,13 @@
if (ref($domdefs{'offloadnow'}) eq 'HASH') {
if ($domdefs{'offloadnow'}{$lonhost}) {
$offload = 1;
+ if (($env{'user.domain'} ne '') && ($env{'user.domain'} ne $dom_in_use) &&
+ (!(($env{'user.name'} eq 'public') && ($env{'user.domain'} eq 'public')))) {
+ unless (&Apache::lonnet::shared_institution($env{'user.domain'})) {
+ $offloadoth = 1;
+ $dom_in_use = $env{'user.domain'};
+ }
+ }
}
}
unless ($offload) {
More information about the LON-CAPA-cvs
mailing list