[LON-CAPA-cvs] cvs: loncom /lonnet/perl lonnet.pm

raeburn raeburn at source.lon-capa.org
Fri Oct 7 10:31:28 EDT 2022


raeburn		Fri Oct  7 14:31:28 2022 EDT

  Modified files:              
    /loncom/lonnet/perl	lonnet.pm 
  Log:
  - Remove &Apache::lonnet:: from some calls to subroutines within lonnet.pm
  
  
-------------- next part --------------
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.1493 loncom/lonnet/perl/lonnet.pm:1.1494
--- loncom/lonnet/perl/lonnet.pm:1.1493	Fri Oct  7 12:53:32 2022
+++ loncom/lonnet/perl/lonnet.pm	Fri Oct  7 14:31:28 2022
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # TCP networking package
 #
-# $Id: lonnet.pm,v 1.1493 2022/10/07 12:53:32 raeburn Exp $
+# $Id: lonnet.pm,v 1.1494 2022/10/07 14:31:28 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -985,9 +985,9 @@
                                                      :  $userloadpercent;
     my ($uint_dom,$remotesessions);
     if (($udom ne '') && (&domain($udom) ne '')) {
-        my $uprimary_id = &Apache::lonnet::domain($udom,'primary');
-        $uint_dom = &Apache::lonnet::internet_dom($uprimary_id);
-        my %udomdefaults = &Apache::lonnet::get_domain_defaults($udom);
+        my $uprimary_id = &domain($udom,'primary');
+        $uint_dom = &internet_dom($uprimary_id);
+        my %udomdefaults = &get_domain_defaults($udom);
         $remotesessions = $udomdefaults{'remotesessions'};
     }
     my $spareshash = &this_host_spares($udom);
@@ -1023,7 +1023,7 @@
                 if ($protocol{$spare_server} eq 'https') {
                     $protocol = $protocol{$spare_server};
                 }
-                my $alias = &Apache::lonnet::use_proxy_alias($r,$spare_server);
+                my $alias = &use_proxy_alias($r,$spare_server);
                 $hostname = $alias if ($alias ne '');
 	        $spare_server = $protocol.'://'.$hostname;
             }
@@ -1211,7 +1211,7 @@
         unless (defined($cached)) {
             my $cachetime = 60*60*24;
             my %domconfig =
-                &Apache::lonnet::get_dom('configuration',['loadbalancing'],$udom);
+                &get_dom('configuration',['loadbalancing'],$udom);
             if (ref($domconfig{'loadbalancing'}) eq 'HASH') {
                 $balancers = &do_cache_new('loadbalancing',$udom,$domconfig{'loadbalancing'},
                                            $cachetime);
@@ -1404,7 +1404,7 @@
 sub can_host_session {
     my ($udom,$lonhost,$remoterev,$remotesessions,$hostedsessions) = @_;
     my $canhost = 1;
-    my $host_idn = &Apache::lonnet::internet_dom($lonhost);
+    my $host_idn = &internet_dom($lonhost);
     if (ref($remotesessions) eq 'HASH') {
         if (ref($remotesessions->{'excludedomain'}) eq 'ARRAY') {
             if (grep(/^\Q$host_idn\E$/,@{$remotesessions->{'excludedomain'}})) {
@@ -1440,8 +1440,8 @@
     }
     if ($canhost) {
         if (ref($hostedsessions) eq 'HASH') {
-            my $uprimary_id = &Apache::lonnet::domain($udom,'primary');
-            my $uint_dom = &Apache::lonnet::internet_dom($uprimary_id);
+            my $uprimary_id = &domain($udom,'primary');
+            my $uint_dom = &internet_dom($uprimary_id);
             if (ref($hostedsessions->{'excludedomain'}) eq 'ARRAY') {
                 if (($uint_dom ne '') && 
                     (grep(/^\Q$uint_dom\E$/,@{$hostedsessions->{'excludedomain'}}))) {
@@ -1533,7 +1533,7 @@
     } else {
         my $cachetime = 60*60*24;
         my %domconfig =
-            &Apache::lonnet::get_dom('configuration',['usersessions'],$dom_in_use);
+            &get_dom('configuration',['usersessions'],$dom_in_use);
         if (ref($domconfig{'usersessions'}) eq 'HASH') {
             if (ref($domconfig{'usersessions'}{'spares'}) eq 'HASH') {
                 if (ref($domconfig{'usersessions'}{'spares'}{$lonhost_in_use}) eq 'HASH') {
@@ -1585,9 +1585,9 @@
         $rule_in_effect,$offloadto,$otherserver,$setcookie,$dom_balancers);
     my $lonhost = $perlvar{'lonHostID'};
     my @hosts = &current_machine_ids();
-    my $uprimary_id = &Apache::lonnet::domain($udom,'primary');
-    my $uintdom = &Apache::lonnet::internet_dom($uprimary_id);
-    my $intdom = &Apache::lonnet::internet_dom($lonhost);
+    my $uprimary_id = &domain($udom,'primary');
+    my $uintdom = &internet_dom($uprimary_id);
+    my $intdom = &internet_dom($lonhost);
     my $serverhomedom = &host_domain($lonhost);
     my $domneedscache;
     my $cachetime = 60*60*24;
@@ -1601,7 +1601,7 @@
     my ($result,$cached)=&is_cached_new('loadbalancing',$dom_in_use);
     unless (defined($cached)) {
         my %domconfig =
-            &Apache::lonnet::get_dom('configuration',['loadbalancing'],$dom_in_use);
+            &get_dom('configuration',['loadbalancing'],$dom_in_use);
         if (ref($domconfig{'loadbalancing'}) eq 'HASH') {
             $result = &do_cache_new('loadbalancing',$dom_in_use,$domconfig{'loadbalancing'},$cachetime);
         } else {
@@ -1662,7 +1662,7 @@
         ($result,$cached)=&is_cached_new('loadbalancing',$serverhomedom);
         unless (defined($cached)) {
             my %domconfig =
-                &Apache::lonnet::get_dom('configuration',['loadbalancing'],$serverhomedom);
+                &get_dom('configuration',['loadbalancing'],$serverhomedom);
             if (ref($domconfig{'loadbalancing'}) eq 'HASH') {
                 $result = &do_cache_new('loadbalancing',$serverhomedom,$domconfig{'loadbalancing'},$cachetime);
             } else {
@@ -1795,7 +1795,7 @@
             }
         } elsif ($rule_in_effect eq 'externalbalancer') {
             my %domconfig =
-                &Apache::lonnet::get_dom('configuration',['loadbalancing'],$udom);
+                &get_dom('configuration',['loadbalancing'],$udom);
             if (ref($domconfig{'loadbalancing'}) eq 'HASH') {
                 if ($domconfig{'loadbalancing'}{'lonhost'} ne '') {
                     if (&hostname($domconfig{'loadbalancing'}{'lonhost'}) ne '') {
@@ -1859,15 +1859,15 @@
         return ($trusted,$untrusted);
     }
     my $callprimary = &domain($calldom,'primary');
-    my $intcalldom = &Apache::lonnet::internet_dom($callprimary);
+    my $intcalldom = &internet_dom($callprimary);
     if ($intcalldom eq '') {
         return ($trusted,$untrusted);
     }
 
-    my ($trustconfig,$cached)=&Apache::lonnet::is_cached_new('trust',$calldom);
+    my ($trustconfig,$cached)=&is_cached_new('trust',$calldom);
     unless (defined($cached)) {
-        my %domconfig = &Apache::lonnet::get_dom('configuration',['trust'],$calldom);
-        &Apache::lonnet::do_cache_new('trust',$calldom,$domconfig{'trust'},3600);
+        my %domconfig = &get_dom('configuration',['trust'],$calldom);
+        &do_cache_new('trust',$calldom,$domconfig{'trust'},3600);
         $trustconfig = $domconfig{'trust'};
     }
     if (ref($trustconfig)) {
@@ -2345,7 +2345,7 @@
 sub retrieve_inst_usertypes {
     my ($udom) = @_;
     my (%returnhash, at order);
-    my %domdefs = &Apache::lonnet::get_domain_defaults($udom);
+    my %domdefs = &get_domain_defaults($udom);
     if ((ref($domdefs{'inststatustypes'}) eq 'HASH') && 
         (ref($domdefs{'inststatusorder'}) eq 'ARRAY')) {
         return ($domdefs{'inststatustypes'},$domdefs{'inststatusorder'});
@@ -2693,7 +2693,7 @@
     }
     my %domdefaults;
     my %domconfig =
-         &Apache::lonnet::get_dom('configuration',['defaults','quotas',
+         &get_dom('configuration',['defaults','quotas',
                                   'requestcourses','inststatus',
                                   'coursedefaults','usersessions',
                                   'requestauthor','selfenrollment',
@@ -2907,7 +2907,7 @@
         } else {
             $cats = {};
         }
-        &Apache::lonnet::do_cache_new('cats',$dom,$cats,3600);
+        &do_cache_new('cats',$dom,$cats,3600);
     }
     return $cats;
 }
@@ -2962,7 +2962,7 @@
     if ($domdefaults{'portal_def'}) {
         $firsturl = $domdefaults{'portal_def'};
     } else {
-        my $alias = &Apache::lonnet::use_proxy_alias($r,$chome);
+        my $alias = &use_proxy_alias($r,$chome);
         $hostname = $alias if ($alias ne '');
         $firsturl = $protocol.'://'.$hostname;
     }
@@ -3160,7 +3160,7 @@
 	return "/$cdom/$cnum";
     }
 
-    my %courseinfo=&Apache::lonnet::coursedescription($courseid);
+    my %courseinfo=&coursedescription($courseid);
     if (exists($courseinfo{'num'})) {
 	return "/$courseinfo{'domain'}/$courseinfo{'num'}";
     }
@@ -3358,14 +3358,14 @@
 # ---------------------------------------------------------- Get a studentphoto
 sub studentphoto {
     my ($udom,$unam,$ext) = @_;
-    my $home=&Apache::lonnet::homeserver($unam,$udom);
+    my $home=&homeserver($unam,$udom);
     if (defined($env{'request.course.id'})) {
         if ($env{'course.'.$env{'request.course.id'}.'.internal.showphoto'}) {
             if ($udom eq $env{'course.'.$env{'request.course.id'}.'.domain'}) {
                 return(&retrievestudentphoto($udom,$unam,$ext)); 
             } else {
                 my ($result,$perm_reqd)=
-		    &Apache::lonnet::auto_photo_permission($unam,$udom);
+		    &auto_photo_permission($unam,$udom);
                 if ($result eq 'ok') {
                     if (!($perm_reqd eq 'yes')) {
                         return(&retrievestudentphoto($udom,$unam,$ext));
@@ -3375,7 +3375,7 @@
         }
     } else {
         my ($result,$perm_reqd) = 
-	    &Apache::lonnet::auto_photo_permission($unam,$udom);
+	    &auto_photo_permission($unam,$udom);
         if ($result eq 'ok') {
             if (!($perm_reqd eq 'yes')) {
                 return(&retrievestudentphoto($udom,$unam,$ext));
@@ -3387,14 +3387,14 @@
 
 sub retrievestudentphoto {
     my ($udom,$unam,$ext,$type) = @_;
-    my $home=&Apache::lonnet::homeserver($unam,$udom);
-    my $ret=&Apache::lonnet::reply("studentphoto:$udom:$unam:$ext:$type",$home);
+    my $home=&homeserver($unam,$udom);
+    my $ret=&reply("studentphoto:$udom:$unam:$ext:$type",$home);
     if ($ret eq 'ok') {
         my $url="/uploaded/$udom/$unam/internal/studentphoto.$ext";
         if ($type eq 'thumbnail') {
             $url="/uploaded/$udom/$unam/internal/studentphoto_tn.$ext"; 
         }
-        my $tokenurl=&Apache::lonnet::tokenwrapper($url);
+        my $tokenurl=&tokenwrapper($url);
         return $tokenurl;
     } else {
         if ($type eq 'thumbnail') {
@@ -3671,8 +3671,8 @@
         ($form{'grade_courseid'} eq $env{'request.course.id'}) &&
         ($form{'grade_username'} ne '') && ($form{'grade_domain'} ne '') &&
         ($form{'grade_symb'} ne '') &&
-        (&Apache::lonnet::allowed('mgr',$env{'request.course.id'}.
-                                 ($env{'request.course.sec'}?'/'.$env{'request.course.sec'}:'')))) {
+        (&allowed('mgr',$env{'request.course.id'}.
+                        ($env{'request.course.sec'}?'/'.$env{'request.course.sec'}:'')))) {
         $islocal = 1;
     }
     $response= &LONCAPA::LWPReq::makerequest($lonhost,$request,'',\%perlvar,
@@ -3823,7 +3823,7 @@
     }
 
     if ($env{'request.course.id'}) {
-        my $crsedit = &Apache::lonnet::allowed('mdc',$env{'request.course.id'});
+        my $crsedit = &allowed('mdc',$env{'request.course.id'});
         if ($group ne '') {
 # if this is a group homepage or group bulletin board, check group privs
             my $allowed = 0;
@@ -3852,7 +3852,7 @@
             }
         } else {
             if ($resurl =~ m{^/?adm/viewclasslist$}) {
-                unless (&Apache::lonnet::allowed('opa',$env{'request.course.id'})) {
+                unless (&allowed('opa',$env{'request.course.id'})) {
                     return;
                 }
             } elsif (!$crsedit) {
@@ -5134,7 +5134,7 @@
     foreach my $entry (keys(%userrolehash)) {
         my ($role,$uname,$udom,$runame,$rudom,$rsec)=
 	    split(/\:/,$entry);
-        if (&Apache::lonnet::put('nohist_userroles',
+        if (&put('nohist_userroles',
              { $role.':'.$uname.':'.$udom.':'.$rsec => $userrolehash{$entry} },
                 $rudom,$runame) eq 'ok') {
 	    delete $userrolehash{$entry};
@@ -5333,7 +5333,7 @@
     my ($trole,$username,$domain,$area,$tstart,$tend,$delflag,$context)=@_;
     if ($area =~ m{^/($match_domain)/$}) {
         my $cdom = $1;
-        my $domconfiguser = &Apache::lonnet::get_domainconfiguser($cdom);
+        my $domconfiguser = &get_domainconfiguser($cdom);
         my $namespace = 'rolelog';
         my %storehash = (
                            role    => $trole,
@@ -5564,8 +5564,8 @@
     } elsif ($cid =~ /^($match_domain)_($match_courseid)$/) {
         $cdom = $1;
         $cnum = $2;
-        %info = &Apache::lonnet::get('environment',['internal.coursecode'],
-                                     $cdom,$cnum);
+        %info = &get('environment',['internal.coursecode'],
+                     $cdom,$cnum);
     }
     if (($info{'internal.coursecode'} ne '') && ($checkreg)) {
         my $user = $env{'user.name'}.':'.$env{'user.domain'};
@@ -5892,7 +5892,7 @@
 
 sub dcmailput {
     my ($domain,$msgid,$message,$server)=@_;
-    my $status = &Apache::lonnet::critical(
+    my $status = &critical(
        'dcmailput:'.$domain.':'.&escape($msgid).'='.
        &escape($message),$server);
     return $status;
@@ -7485,7 +7485,7 @@
                      '&host='.&escape($perlvar{'lonHostID'}).
                      '&version='.$esc_v.
                      '&by='.&escape($env{'user.name'}.':'.$env{'user.domain'});
-       &Apache::lonnet::courselog($symb.':'.$uname.':'.$udomain.':PUTSTORE:'.$namevalue);
+       &courselog($symb.':'.$uname.':'.$udomain.':PUTSTORE:'.$namevalue);
    }
    if ($reply eq 'unknown_cmd') {
        # gfall back to way things use to be done
@@ -7635,16 +7635,16 @@
     my $tries = 0;
 
 # attempt to get lock on nohist_$namespace file
-    my $gotlock = &Apache::lonnet::newput('nohist_'.$namespace,$lockhash,$cdom,$cnum);
+    my $gotlock = &newput('nohist_'.$namespace,$lockhash,$cdom,$cnum);
     while (($gotlock ne 'ok') && $tries <$locktries) {
         $tries ++;
         sleep 1;
-        $gotlock = &Apache::lonnet::newput('nohist_'.$namespace,$lockhash,$cdom,$cnum);
+        $gotlock = &newput('nohist_'.$namespace,$lockhash,$cdom,$cnum);
     }
 
 # attempt to get unique identifier, based on current timestamp
     if ($gotlock eq 'ok') {
-        my %inuse = &Apache::lonnet::dump('nohist_'.$namespace,$cdom,$cnum,$prefix);
+        my %inuse = &dump('nohist_'.$namespace,$cdom,$cnum,$prefix);
         my $id = time;
         $newid = $id;
         if ($idtype eq 'addcode') {
@@ -7665,7 +7665,7 @@
             my %new_item =  (
                               $prefix."\0".$newid => $who,
                             );
-            my $putresult = &Apache::lonnet::put('nohist_'.$namespace,\%new_item,
+            my $putresult = &put('nohist_'.$namespace,\%new_item,
                                                  $cdom,$cnum);
             if ($putresult ne 'ok') {
                 undef($newid);
@@ -8104,7 +8104,7 @@
             if ($env{'course.'.$cdom.'_'.$cnum.'.internal.courseowner'} eq $uname.':'.$udom) {
                 return 1;
             } else {
-                my %courseinfo = &Apache::lonnet::coursedescription($cdom.'/'.$cnum);
+                my %courseinfo = &coursedescription($cdom.'/'.$cnum);
                 if ($courseinfo{'internal.courseowner'} eq $uname.':'.$udom) {
                     return 1;
                 }
@@ -8996,7 +8996,7 @@
     if ((defined($cached)) && (ref($blocksref) eq 'HASH')) {
         %commblocks = %{$blocksref};
     } else {
-        %commblocks = &Apache::lonnet::dump('comm_block',$cdom,$cnum);
+        %commblocks = &dump('comm_block',$cdom,$cnum);
         my $cachetime = 600;
         &do_cache_new('comm_block',$hashid,\%commblocks,$cachetime);
     }
@@ -10622,10 +10622,10 @@
     }
     if (($putresult eq 'ok') || ($delresult eq 'ok')) {
         my %crsinfo =
-            &Apache::lonnet::courseiddump($cdom,'.',1,'.','.',$cnum,undef,undef,'.');
+            &courseiddump($cdom,'.',1,'.','.',$cnum,undef,undef,'.');
         if (ref($crsinfo{$cid}) eq 'HASH') {
             $crsinfo{$cid}{'co-owners'} = \@newcoowners;
-            my $cidput = &Apache::lonnet::courseidput($cdom,\%crsinfo,$chome,'notime');
+            my $cidput = &courseidput($cdom,\%crsinfo,$chome,'notime');
         }
     }
 }
@@ -10843,7 +10843,7 @@
         return 'error: '.$reply;
     }
     if ($names{'permanentemail'} ne $oldnames{'permanentemail'}) {
-        &Apache::lonnet::devalidate_cache_new('emailscache',$uname.':'.$udom);
+        &devalidate_cache_new('emailscache',$uname.':'.$udom);
     }
     my $sqlresult = &update_allusers_table($uname,$udom,\%names);
     &devalidate_cache_new('namescache',$uname.':'.$udom);
@@ -10923,7 +10923,7 @@
     }
     my $fullname = &format_name($first,$middle,$last,$gene,'lastname');
     my $user = "$uname:$udom";
-    my %old_entry = &Apache::lonnet::get('classlist',[$user],$cdom,$cnum);
+    my %old_entry = &get('classlist',[$user],$cdom,$cnum);
     my $reply=cput('classlist',
 		   {$user => 
 			join(':',$end,$start,$uid,$usec,$fullname,$type,$locktype,$credits,$instsec) },
@@ -11057,7 +11057,7 @@
         }
     }
     my %host_servers =
-        &Apache::lonnet::get_servers($udom,'library');
+        &get_servers($udom,'library');
     unless ($host_servers{$course_server}) {
         return 'error: invalid home server for course: '.$course_server;
     }
@@ -13551,13 +13551,13 @@
 sub get_course_slots {
     my ($cnum,$cdom) = @_;
     my $hashid=$cnum.':'.$cdom;
-    my ($result,$cached) = &Apache::lonnet::is_cached_new('allslots',$hashid);
+    my ($result,$cached) = &is_cached_new('allslots',$hashid);
     if (defined($cached)) {
         if (ref($result) eq 'HASH') {
             return %{$result};
         }
     } else {
-        my %slots=&Apache::lonnet::dump('slots',$cdom,$cnum);
+        my %slots=&dump('slots',$cdom,$cnum);
         my ($tmp) = keys(%slots);
         if ($tmp !~ /^(con_lost|error|no_such_host)/i) {
             &do_cache_new('allslots',$hashid,\%slots,600);
@@ -14771,7 +14771,7 @@
 
 sub get_proxy_settings {
     my ($dom_in_use) = @_;
-    my %domdefaults = &Apache::lonnet::get_domain_defaults($dom_in_use);
+    my %domdefaults = &get_domain_defaults($dom_in_use);
     my $proxyinfo = {
                        ipheader => $domdefaults{'waf_ipheader'},
                        trusted  => $domdefaults{'waf_trusted'},
@@ -14804,11 +14804,11 @@
         if ($cached) {
             return $alias;
         }
-        my $dom = &Apache::lonnet::host_domain($lonid);
+        my $dom = &host_domain($lonid);
         if ($dom ne '') {
             my $cachetime = 60*60*24;
             my %domconfig =
-                &Apache::lonnet::get_dom('configuration',['wafproxy'],$dom);
+                &get_dom('configuration',['wafproxy'],$dom);
             if (ref($domconfig{'wafproxy'}) eq 'HASH') {
                 if (ref($domconfig{'wafproxy'}{'alias'}) eq 'HASH') {
                     $alias = $domconfig{'wafproxy'}{'alias'}{$lonid};
@@ -14855,11 +14855,11 @@
         if ($cached) {
             return $use_alias;
         }
-        my $dom = &Apache::lonnet::host_domain($lonid);
+        my $dom = &host_domain($lonid);
         if ($dom ne '') {
             my $cachetime = 60*60*24;
             my %domconfig =
-                &Apache::lonnet::get_dom('configuration',['wafproxy'],$dom);
+                &get_dom('configuration',['wafproxy'],$dom);
             if (ref($domconfig{'wafproxy'}) eq 'HASH') {
                 if (ref($domconfig{'wafproxy'}{'saml'}) eq 'HASH') {
                     $use_alias = $domconfig{'wafproxy'}{'saml'}{$lonid};
@@ -14887,7 +14887,7 @@
             $lonid = $perlvar{'lonHostID'};
         }
         if ($lonid) {
-            unless (&Apache::lonnet::host_domain($lonid) eq $defdom) {
+            unless (&host_domain($lonid) eq $defdom) {
                 return;
             }
         } else {
@@ -14900,11 +14900,11 @@
     if ($cached) {
         return $landing;
     }
-    my $dom = &Apache::lonnet::host_domain($lonid);
+    my $dom = &host_domain($lonid);
     if ($dom ne '') {
         my $cachetime = 60*60*24;
         my %domconfig =
-            &Apache::lonnet::get_dom('configuration',['login'],$dom);
+            &get_dom('configuration',['login'],$dom);
         if (ref($domconfig{'login'}) eq 'HASH') {
             if (ref($domconfig{'login'}{'saml'}) eq 'HASH') {
                 if (ref($domconfig{'login'}{'saml'}{$lonid}) eq 'HASH') {
@@ -15034,7 +15034,7 @@
     my ($url,$func,$ignore_cache,$nocache,$hashref) = @_;
     if (!$ignore_cache) {
 	my ($content,$cached)=
-	    &Apache::lonnet::is_cached_new('dns',$url);
+	    &is_cached_new('dns',$url);
 	if ($cached) {
 	    &$func($content,$hashref);
 	    return;
@@ -15113,7 +15113,7 @@
 sub parse_dns_checksums_tab {
     my ($lines,$hashref) = @_;
     my $lonhost = $perlvar{'lonHostID'};
-    my $machine_dom = &Apache::lonnet::host_domain($lonhost);
+    my $machine_dom = &host_domain($lonhost);
     my $loncaparev = &get_server_loncaparev($machine_dom);
     my $distro = (split(/\:/,&get_server_distarch($lonhost)))[0];
     my $webconfdir = '/etc/httpd/conf';
@@ -15157,7 +15157,7 @@
 
 sub fetch_dns_checksums {
     my %checksums;
-    my $machine_dom = &Apache::lonnet::host_domain($perlvar{'lonHostID'});
+    my $machine_dom = &host_domain($perlvar{'lonHostID'});
     my $loncaparev = &get_server_loncaparev($machine_dom,$perlvar{'lonHostID'});
     my ($release,$timestamp) = split(/\-/,$loncaparev);
     &get_dns("/adm/dns/checksums/$release",\&parse_dns_checksums_tab,1,1,
@@ -15545,7 +15545,7 @@
 		return %iphost;
 	    }
 	    my ($ip_info,$cached)=
-		&Apache::lonnet::is_cached_new('iphost','iphost');
+		&is_cached_new('iphost','iphost');
 	    if ($cached) {
 		%iphost      = %{$ip_info->[0]};
 		%name_to_ip  = %{$ip_info->[1]};
@@ -15557,7 +15557,7 @@
 	# get yesterday's info for fallback
 	my %old_name_to_ip;
 	my ($ip_info,$cached)=
-	    &Apache::lonnet::is_cached_new('iphost','iphost');
+	    &s_cached_new('iphost','iphost');
 	if ($cached) {
 	    %old_name_to_ip = %{$ip_info->[1]};
 	}
@@ -15624,7 +15624,7 @@
         my ($lonid) = @_;
         return if ($lonid eq '');
         my ($idnref,$cached)=
-            &Apache::lonnet::is_cached_new('internetnames',$lonid);
+            &is_cached_new('internetnames',$lonid);
         if ($cached) {
             return $idnref;
         }


More information about the LON-CAPA-cvs mailing list