Code

* gosa-si-server-nobus
authorrettenbe <rettenbe@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 21 May 2008 09:55:50 +0000 (09:55 +0000)
committerrettenbe <rettenbe@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 21 May 2008 09:55:50 +0000 (09:55 +0000)
* under construction

git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10981 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-si/modules/ClientPackages.pm
gosa-si/server/events/server_server_com.pm

index b25c44d95f4c1282f7f2f8f8857a6b9ee6d9f95d..41cecf8c42d702a0f0070026fba6dacba73f078c 100644 (file)
@@ -172,16 +172,6 @@ if($bus_activ eq "on") {
     &register_at_bus();
 }
 
-# add myself to known_server_db
-my $res = $main::known_server_db->add_dbentry( {table=>'known_server',
-        primkey=>['hostname'],
-        hostname=>$server_address,
-        status=>'myself',
-        hostkey=>$ClientPackages_key,
-        timestamp=>&get_time,
-        } );
-
-
 
 ### functions #################################################################
 
index bc1027c8bbd340f96a2e9e33e090bde1db763fd0..760928ef2bdf42bf28315d77f95ef56e749967b3 100644 (file)
@@ -58,7 +58,7 @@ sub new_server {
         my @client_details = split(/,/, $client);
 
         # workaround to avoid double entries in foreign_clients_db
-        my $del_sql = "DELTE FROM $main::foreign_clients_tn WHERE hostname='".$client_details[0]."'";
+        my $del_sql = "DELETE FROM $main::foreign_clients_tn WHERE hostname='".$client_details[0]."'";
         push(@sql_list, $del_sql);
 
         my $sql = "INSERT INTO $main::foreign_clients_tn VALUES ("
@@ -69,7 +69,9 @@ sub new_server {
         push(@sql_list, $sql);
     }
     if (@sql_list) {
-        &main::daemon_log("$session_id DEBUG: Inserting ".scalar @sql_list." entries to foreign_clients_db", 8);
+               my $len = @sql_list;
+               $len /= 2;
+        &main::daemon_log("$session_id DEBUG: Inserting ".$len." entries to foreign_clients_db", 8);
         my $res = $main::foreign_clients_db->exec_statementlist(\@sql_list);
     }
             
@@ -94,4 +96,18 @@ sub confirm_new_server {
 
 }
 
+
+sub new_foreign_client {
+               my ($msg, $msg_hash, $session_id) = @_ ;
+               my $header = @{$msg_hash->{'header'}}[0];
+               my $source = @{$msg_hash->{'source'}}[0];
+               my $new_client = @{$msg_hash->{'client'}}[0];
+
+               my $func_dic = ();
+               
+
+               return;
+}
+
+
 1;