diff --git a/Python_Assignment/Exercise_5/cmd_line.py b/Python_Assignment/Exercise_5/cmd_line.py new file mode 100644 index 0000000..e144cbb --- /dev/null +++ b/Python_Assignment/Exercise_5/cmd_line.py @@ -0,0 +1,35 @@ + + +''' + +Create a python file math.py which has three functions; sum, diff and mul. +Each function accepts two numbers. +Function sum returns result of addition of two passed in numbers, diff returns the positive difference between two specified numbers and mul returns the multiplication of two numbers. +Numbers passed in may be integer or decimal. +Create main program python file. +Include math.py in this main file and call three math functions. +Main program accepts two command line arguments, which are two numbers to pass into above three math functions. +Validate that specified command line parameters are integers or decimal. +Also validate that exactly two arguments are passed to the main program from command line, if not, print the help message to pass in two numbers. +Main program should call all three math functions over the two numbers passed in and print the output on console. +''' + +import argparse +from math1 import * + +#creating object of parser +parser=argparse.ArgumentParser("File program") + +#check how many values are passed and that are float or not? +parser.add_argument("input", nargs=2, type=float, help="Enter integers only and only two arguments") + +#parsing argument from standard input +args=parser.parse_args() + +#assigning command line values to num1 and num2 +num1,num2=args.input[0:2] + +#calling all functions of math1 file +print("Addition is: ",add(num1,num2)) +print("Multiplication is: ",mul(num1,num2)) +print("Difference is: ",diff(num1,num2)) \ No newline at end of file diff --git a/Python_Assignment/Exercise_5/math1.py b/Python_Assignment/Exercise_5/math1.py new file mode 100644 index 0000000..280659c --- /dev/null +++ b/Python_Assignment/Exercise_5/math1.py @@ -0,0 +1,24 @@ +''' +Validate that specified command line parameters are + integers or decimal. Also validate that exactly two + arguments are passed to the main program from command + line, + if not, print the help message to pass in two + numbers. Main program should call all three math + functions over the two numbers passed in and print + the output on console. +''' + +# Function adds two number and return its sum +def add(num1, num2): + return num1 + num2 + + +# Function multiplies two number and return answer +def mul(num1, num2): + return num1 * num2 + + +# Function finds difference between two number and return difference +def diff(num1, num2): + return(abs(num1 - num2)) diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_41_47DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_41_47DiscoveryTestServer.txt new file mode 100644 index 0000000..605e3d9 --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_41_47DiscoveryTestServer.txt @@ -0,0 +1,99 @@ +[1071539.967 (000169):SsdpService:INFO]SsdpService::Initialize +[1071539.967 (000174):MdnsService:INFO]ReconnectClient() +[1071539.967 (000169):SsdpAPI:INFO]Register +[1071539.967 (000169):SsdpAPI:INFO]Register Creating SsdpClient +[1071539.967 (000169):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071539.967 (000169):DiscoveryServiceTestServer:INFO]Server constructor; pid=169, tid=169 +[1071539.967 (000169):DiscoveryServiceTestServer:INFO]Initialize; pid=169, tid=169 +[1071539.968 (000169):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071539.968 (000169):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071539.968 (000169):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071539.968 (000169):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071539.969 (000174):mDNS:INFO]Client state: RUNNING. +[1071539.969 (000174):MdnsService:INFO]ReconnectPublisher() +[1071539.971 (000174):mDNS:INFO]Client state: RUNNING. +[1071539.971 (000174):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071539.971 (000174):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071539.971 (000174):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071539.971 (000174):MdnsService:INFO]ClientConnected() +[1071539.972 (000174):MdnsService:INFO]PublisherConnected() +[1071539.989 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 15): Connection refused +[1071540.089 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 15): Connection refused +[1071540.155 (000173):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071540.155 (000173):DiscoveryServiceServer:INFO]Create +[1071540.155 (000173):DiscoveryServiceServer:INFO]Initialize +[1071540.190 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071540.290 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071540.391 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071540.491 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071540.591 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071540.692 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071540.737 (000173):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=475ecba6-23ae-11e7-9f8e-0242ac110002 +[1071540.737 (000173):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1071540.737 (000174):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 475ecba6-23ae-11e7-9f8e-0242ac110002 +[1071540.737 (000174):SsdpAPI:INFO]RegisterForMediaServerDeviceStatus +[1071540.738 (000173):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 475ecba6-23ae-11e7-9f8e-0242ac110002, status=1********** +[1071540.792 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071540.893 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071540.993 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071541.094 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071541.194 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071541.245 (000173):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=476bc266-23ae-11e7-9f8e-0242ac110002 +[1071541.245 (000173):DiscoveryServiceITC:INFO]RegisterForDeviceStatusMdns +[1071541.246 (000174):MdnsService:INFO]RegisterForDeviceStatus() - [system:ERROR] whith DiscoveryFilter = 476bc266-23ae-11e7-9f8e-0242ac110002 +[1071541.246 (000173):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 476bc266-23ae-11e7-9f8e-0242ac110002, status=1********** +[1071541.295 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071541.395 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071541.496 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071541.596 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071541.696 (000177):Network:ERROR]Failed connect call for 127.0.0.1:40010 (fd 23): Connection refused +[1071541.797 (000174):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071541.797 (000174):SsdpAPI:INFO]FireRegisteredEvent +[1071541.797 (000174):SsdpService:INFO]Registered() +[1071542.427 (000174):MdnsService:INFO]Discovered(47e0df9c-23ae-11e7-ae86-0242ac110003) +[1071542.428 (000174):MdnsService:INFO]Resolved(47e0df9c-23ae-11e7-ae86-0242ac110003) +[1071547.979 (000174):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=475ecba6-23ae-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:475ecba6-23ae-11e7-9f8e-0242ac110002,location=http://172.17.0.2:43609/475ecba6-23ae-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071547.979 (000173):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071548.749 (000174):MdnsService:INFO]Removed(47e0df9c-23ae-11e7-ae86-0242ac110003) +[1071550.436 (000174):MdnsService:INFO]Discovered(476bc266-23ae-11e7-9f8e-0242ac110002) +[1071550.437 (000174):MdnsService:INFO]Resolved(476bc266-23ae-11e7-9f8e-0242ac110002) +[1071550.437 (000173):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=476bc266-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071551.374 (000174):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=475ecba6-23ae-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:475ecba6-23ae-11e7-9f8e-0242ac110002,location=http://172.17.0.2:43609/475ecba6-23ae-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1071551.374 (000173):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071553.403 (000174):MdnsService:INFO]Removed(476bc266-23ae-11e7-9f8e-0242ac110002) +[1071553.405 (000173):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=476bc266-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071554.926 (000173):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071554.926 (000173):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071555.385 (000173):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071555.385 (000173):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071555.385 (000174):SsdpAPI:INFO]UnRegisterForMediaServerDeviceStatus +[1071556.636 (000173):Network:INFO]Received EOS (fd 15) +[1071556.636 (000173):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: [system:ERROR] Receive failed, disconnecting +[1071556.636 (000173):DiscoveryServiceServer_Router:INFO]Disconnected +[1071556.636 (000173):DiscoveryServiceServer:INFO]HandleDisconnect +[1071556.636 (000173):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071556.636 (000173):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071557.346 (000173):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071557.346 (000173):DiscoveryServiceServer:INFO]Create +[1071557.346 (000173):DiscoveryServiceServer:INFO]Initialize +[1071557.346 (000173):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071558.872 (000174):MdnsService:INFO]Discovered(51959690-23ae-11e7-9f8e-0242ac110002) +[1071558.873 (000174):MdnsService:INFO]Resolved(51959690-23ae-11e7-9f8e-0242ac110002) +[1071564.106 (000174):MdnsService:INFO]Discovered(54a52fbc-23ae-11e7-9f8e-0242ac110002) +[1071564.107 (000174):MdnsService:INFO]Resolved(54a52fbc-23ae-11e7-9f8e-0242ac110002) +[1071570.527 (000173):DiscoveryServiceServer:INFO]GetDeviceList +[1071570.527 (000173):DiscoveryServiceITC:INFO]GetDeviceList +[1071570.527 (000174):SsdpService:INFO]GetDeviceList +[1071570.527 (000173):DiscoveryServiceServer:INFO]MediaServerListResponse +[1071571.060 (000173):DiscoveryServiceServer:INFO]GetDeviceList +[1071571.060 (000173):DiscoveryServiceITC:INFO]GetDeviceList +[1071571.060 (000174):MdnsService:INFO]GetDeviceList() +[1071571.061 (000173):DiscoveryServiceServer:INFO]MediaServerListResponse +[1071573.130 (000174):MdnsService:INFO]Removed(54a52fbc-23ae-11e7-9f8e-0242ac110002) +[1071573.973 (000174):MdnsService:INFO]Removed(51959690-23ae-11e7-9f8e-0242ac110002) +[1071574.305 (000173):Network:INFO]Received EOS (fd 15) +[1071574.305 (000173):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071574.305 (000173):DiscoveryServiceServer_Router:INFO]Disconnected +[1071574.305 (000173):DiscoveryServiceServer:INFO]HandleDisconnect +[1071574.305 (000173):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071574.305 (000173):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_42_23DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_42_23DiscoveryTestServer.txt new file mode 100644 index 0000000..31eb3ad --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_42_23DiscoveryTestServer.txt @@ -0,0 +1,278 @@ +[1071575.165 (001707):SsdpService:INFO]SsdpService::Initialize +[1071575.165 (001709):MdnsService:INFO]ReconnectClient() +[1071575.166 (001707):SsdpAPI:INFO]Register +[1071575.166 (001707):SsdpAPI:INFO]Register Creating SsdpClient +[1071575.166 (001707):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071575.166 (001707):DiscoveryServiceTestServer:INFO]Server constructor; pid=1707, tid=1707 +[1071575.166 (001707):DiscoveryServiceTestServer:INFO]Initialize; pid=1707, tid=1707 +[1071575.166 (001707):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071575.166 (001707):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071575.166 (001707):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071575.166 (001707):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071575.168 (001709):mDNS:INFO]Client state: RUNNING. +[1071575.168 (001709):MdnsService:INFO]ReconnectPublisher() +[1071575.170 (001709):mDNS:INFO]Client state: RUNNING. +[1071575.170 (001709):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071575.170 (001709):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071575.170 (001709):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071575.170 (001709):MdnsService:INFO]ClientConnected() +[1071575.171 (001709):MdnsService:INFO]PublisherConnected() +[1071575.171 (001709):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071575.171 (001709):SsdpAPI:INFO]FireRegisteredEvent +[1071575.171 (001709):SsdpService:INFO]Registered() +[1071575.314 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071575.314 (001708):DiscoveryServiceServer:INFO]Create +[1071575.314 (001708):DiscoveryServiceServer:INFO]Initialize +[1071577.033 (001709):MdnsService:INFO]Discovered(5c412d84-23ae-11e7-9f8e-0242ac110002) +[1071577.034 (001709):MdnsService:INFO]Resolved(5c412d84-23ae-11e7-9f8e-0242ac110002) +[1071577.397 (001709):MdnsService:INFO]Discovered(4d62ac8e-23ae-11e7-ae86-0242ac110003) +[1071578.039 (001709):MdnsService:INFO]Resolved(4d62ac8e-23ae-11e7-ae86-0242ac110003) +[1071581.883 (001709):MdnsService:INFO]Removed(4d62ac8e-23ae-11e7-ae86-0242ac110003) +[1071582.375 (001708):DiscoveryServiceServer:INFO]GetDeviceList +[1071582.375 (001708):DiscoveryServiceITC:INFO]GetDeviceList +[1071582.375 (001709):MdnsService:INFO]GetDeviceList() +[1071582.375 (001708):DiscoveryServiceServer:INFO]MediaServerListResponse +[1071584.293 (001709):MdnsService:INFO]Removed(5c412d84-23ae-11e7-9f8e-0242ac110002) +[1071588.716 (001708):DiscoveryServiceServer:INFO]GetDeviceList +[1071588.716 (001708):DiscoveryServiceITC:INFO]GetDeviceList +[1071588.716 (001709):MdnsService:INFO]GetDeviceList() +[1071588.716 (001708):DiscoveryServiceServer:INFO]MediaServerListResponse +[1071589.966 (001708):Network:INFO]Received EOS (fd 24) +[1071589.966 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071589.966 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071589.966 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071589.966 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071589.966 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071590.484 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071590.484 (001708):DiscoveryServiceServer:INFO]Create +[1071590.484 (001708):DiscoveryServiceServer:INFO]Initialize +[1071590.484 (001708):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071592.276 (001709):MdnsService:INFO]Discovered(654e6c0c-23ae-11e7-9f8e-0242ac110002) +[1071592.277 (001709):MdnsService:INFO]Resolved(654e6c0c-23ae-11e7-9f8e-0242ac110002) +[1071593.795 (001709):MdnsService:INFO]Discovered(66628e20-23ae-11e7-9f8e-0242ac110002) +[1071593.796 (001709):MdnsService:INFO]Resolved(66628e20-23ae-11e7-9f8e-0242ac110002) +[1071595.427 (001709):MdnsService:INFO]Discovered(675fff42-23ae-11e7-9f8e-0242ac110002) +[1071595.428 (001709):MdnsService:INFO]Resolved(675fff42-23ae-11e7-9f8e-0242ac110002) +[1071598.862 (001708):DiscoveryServiceServer:INFO]GetDeviceList +[1071598.862 (001708):DiscoveryServiceITC:INFO]GetDeviceList +[1071598.862 (001709):MdnsService:INFO]GetDeviceList() +[1071598.862 (001708):DiscoveryServiceServer:INFO]MediaServerListResponse +[1071600.580 (001709):MdnsService:INFO]Removed(654e6c0c-23ae-11e7-9f8e-0242ac110002) +[1071601.039 (001709):MdnsService:INFO]Removed(66628e20-23ae-11e7-9f8e-0242ac110002) +[1071605.417 (001708):DiscoveryServiceServer:INFO]GetDeviceList +[1071605.417 (001708):DiscoveryServiceITC:INFO]GetDeviceList +[1071605.417 (001709):MdnsService:INFO]GetDeviceList() +[1071605.417 (001708):DiscoveryServiceServer:INFO]MediaServerListResponse +[1071607.078 (001709):MdnsService:INFO]Removed(675fff42-23ae-11e7-9f8e-0242ac110002) +[1071607.703 (001708):Network:INFO]Received EOS (fd 24) +[1071607.703 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071607.703 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071607.703 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071607.703 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071607.703 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071608.260 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071608.260 (001708):DiscoveryServiceServer:INFO]Create +[1071608.260 (001708):DiscoveryServiceServer:INFO]Initialize +[1071608.260 (001708):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071614.639 (001708):DiscoveryServiceServer:INFO]GetDeviceList +[1071614.640 (001708):DiscoveryServiceITC:INFO]GetDeviceList +[1071614.640 (001709):MdnsService:INFO]GetDeviceList() +[1071614.640 (001708):DiscoveryServiceServer:INFO]MediaServerListResponse +[1071615.890 (001708):Network:INFO]Received EOS (fd 24) +[1071615.891 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071615.891 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071615.891 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071615.891 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071615.891 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071616.484 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071616.484 (001708):DiscoveryServiceServer:INFO]Create +[1071616.484 (001708):DiscoveryServiceServer:INFO]Initialize +[1071616.484 (001708):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071617.846 (001709):MdnsService:INFO]Discovered(74c38050-23ae-11e7-9f8e-0242ac110002) +[1071617.847 (001709):MdnsService:INFO]Resolved(74c38050-23ae-11e7-9f8e-0242ac110002) +[1071618.009 (001708):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=74c38050-23ae-11e7-9f8e-0242ac110002 +[1071618.009 (001708):DiscoveryServiceITC:INFO]RegisterForDeviceStatusMdns +[1071618.009 (001709):MdnsService:INFO]RegisterForDeviceStatus() - DiscoveryFilter = 74c38050-23ae-11e7-9f8e-0242ac110002 +[1071618.009 (001708):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 74c38050-23ae-11e7-9f8e-0242ac110002, status=1********** +[1071618.009 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=74c38050-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071619.852 (001709):MdnsService:INFO]Removed(74c38050-23ae-11e7-9f8e-0242ac110002) +[1071619.853 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=74c38050-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071620.660 (001708):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071620.660 (001708):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071622.037 (001708):Network:INFO]Received EOS (fd 24) +[1071622.037 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071622.037 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071622.037 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071622.037 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071622.038 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071622.538 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071622.538 (001708):DiscoveryServiceServer:INFO]Create +[1071622.538 (001708):DiscoveryServiceServer:INFO]Initialize +[1071622.538 (001708):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071623.305 (001709):MdnsService:INFO]Discovered(785ccd7a-23ae-11e7-9f8e-0242ac110002) +[1071623.886 (001709):MdnsService:INFO]Resolved(785ccd7a-23ae-11e7-9f8e-0242ac110002) +[1071624.330 (001708):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=2d2dca6e9dc8 +[1071624.330 (001708):DiscoveryServiceITC:INFO]RegisterForDeviceStatusMdns +[1071624.330 (001709):MdnsService:INFO]RegisterForDeviceStatus() - DiscoveryFilter = 2d2dca6e9dc8 +[1071624.330 (001708):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 2d2dca6e9dc8, status=1********** +[1071624.330 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=785ccd7a-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071626.182 (001709):MdnsService:INFO]Removed(785ccd7a-23ae-11e7-9f8e-0242ac110002) +[1071626.183 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=785ccd7a-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071627.259 (001708):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071627.259 (001708):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071628.660 (001708):Network:INFO]Received EOS (fd 24) +[1071628.660 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071628.660 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071628.660 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071628.660 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071628.660 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071629.477 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071629.477 (001708):DiscoveryServiceServer:INFO]Create +[1071629.477 (001708):DiscoveryServiceServer:INFO]Initialize +[1071629.477 (001708):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071629.636 (001708):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=garbage +[1071629.636 (001708):DiscoveryServiceITC:INFO]RegisterForDeviceStatusMdns +[1071629.636 (001709):MdnsService:INFO]RegisterForDeviceStatus() - DiscoveryFilter = garbage +[1071629.636 (001708):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= garbage, status=1********** +[1071631.162 (001709):MdnsService:INFO]Discovered(7cddf8a6-23ae-11e7-9f8e-0242ac110002) +[1071631.597 (001709):MdnsService:INFO]Resolved(7cddf8a6-23ae-11e7-9f8e-0242ac110002) +[1071631.597 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=7cddf8a6-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071633.362 (001709):MdnsService:INFO]Discovered(7e143ea6-23ae-11e7-ae86-0242ac110003) +[1071633.363 (001709):MdnsService:INFO]Resolved(7e143ea6-23ae-11e7-ae86-0242ac110003) +[1071633.363 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=7e143ea6-23ae-11e7-ae86-0242ac110003, DeviceState=ONLINE +[1071633.947 (001709):MdnsService:INFO]Discovered(7e449ae2-23ae-11e7-9f8e-0242ac110002) +[1071633.948 (001709):MdnsService:INFO]Resolved(7e449ae2-23ae-11e7-9f8e-0242ac110002) +[1071633.948 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=7e449ae2-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071636.438 (001709):MdnsService:INFO]Discovered(7fbfa48e-23ae-11e7-9f8e-0242ac110002) +[1071636.439 (001709):MdnsService:INFO]Resolved(7fbfa48e-23ae-11e7-9f8e-0242ac110002) +[1071636.439 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=7fbfa48e-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071638.300 (001709):MdnsService:INFO]Removed(7cddf8a6-23ae-11e7-9f8e-0242ac110002) +[1071638.301 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=7cddf8a6-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071640.067 (001709):MdnsService:INFO]Removed(7e449ae2-23ae-11e7-9f8e-0242ac110002) +[1071640.067 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=7e449ae2-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071642.460 (001709):MdnsService:INFO]Removed(7fbfa48e-23ae-11e7-9f8e-0242ac110002) +[1071642.460 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=7fbfa48e-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071644.513 (001709):MdnsService:INFO]Removed(7e143ea6-23ae-11e7-ae86-0242ac110003) +[1071644.513 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=7e143ea6-23ae-11e7-ae86-0242ac110003, DeviceState=OFFLINE +[1071649.502 (001708):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071649.502 (001708):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071651.754 (001708):Network:INFO]Received EOS (fd 24) +[1071651.754 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071651.754 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071651.754 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071651.754 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071651.754 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071652.371 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071652.371 (001708):DiscoveryServiceServer:INFO]Create +[1071652.371 (001708):DiscoveryServiceServer:INFO]Initialize +[1071652.372 (001708):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071652.855 (001708):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=8a4b289c-23ae-11e7-9f8e-0242ac110002 +[1071652.855 (001708):DiscoveryServiceITC:INFO]RegisterForDeviceStatusMdns +[1071652.855 (001709):MdnsService:INFO]RegisterForDeviceStatus() - DiscoveryFilter = 8a4b289c-23ae-11e7-9f8e-0242ac110002 +[1071652.855 (001708):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 8a4b289c-23ae-11e7-9f8e-0242ac110002, status=1********** +[1071654.351 (001709):MdnsService:INFO]Discovered(8a4b289c-23ae-11e7-9f8e-0242ac110002) +[1071654.352 (001709):MdnsService:INFO]Resolved(8a4b289c-23ae-11e7-9f8e-0242ac110002) +[1071654.352 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=8a4b289c-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071656.273 (001709):MdnsService:INFO]Removed(8a4b289c-23ae-11e7-9f8e-0242ac110002) +[1071656.274 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=8a4b289c-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071658.110 (001709):MdnsService:INFO]Discovered(8a4b289c-23ae-11e7-9f8e-0242ac110002) +[1071658.111 (001709):MdnsService:INFO]Resolved(8a4b289c-23ae-11e7-9f8e-0242ac110002) +[1071658.111 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=8a4b289c-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071659.941 (001709):MdnsService:INFO]Removed(8a4b289c-23ae-11e7-9f8e-0242ac110002) +[1071659.942 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=8a4b289c-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071661.695 (001709):MdnsService:INFO]Discovered(8a4b289c-23ae-11e7-9f8e-0242ac110002) +[1071661.696 (001709):MdnsService:INFO]Resolved(8a4b289c-23ae-11e7-9f8e-0242ac110002) +[1071661.696 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=8a4b289c-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071663.583 (001709):MdnsService:INFO]Removed(8a4b289c-23ae-11e7-9f8e-0242ac110002) +[1071663.584 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=8a4b289c-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071664.342 (001708):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071664.342 (001708):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071665.593 (001708):Network:INFO]Received EOS (fd 24) +[1071665.593 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071665.593 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071665.593 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071665.593 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071665.593 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071666.117 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071666.117 (001708):DiscoveryServiceServer:INFO]Create +[1071666.117 (001708):DiscoveryServiceServer:INFO]Initialize +[1071666.118 (001708):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071667.118 (001709):MdnsService:INFO]Discovered(92670b0e-23ae-11e7-9f8e-0242ac110002) +[1071667.717 (001709):MdnsService:INFO]Resolved(92670b0e-23ae-11e7-9f8e-0242ac110002) +[1071669.125 (001709):MdnsService:INFO]Discovered(935c6ac2-23ae-11e7-9f8e-0242ac110002) +[1071669.126 (001709):MdnsService:INFO]Resolved(935c6ac2-23ae-11e7-9f8e-0242ac110002) +[1071670.458 (001709):MdnsService:INFO]Discovered(942baec2-23ae-11e7-9f8e-0242ac110002) +[1071670.459 (001709):MdnsService:INFO]Resolved(942baec2-23ae-11e7-9f8e-0242ac110002) +[1071670.702 (001708):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=92670b0e-23ae-11e7-9f8e-0242ac110002 +[1071670.702 (001708):DiscoveryServiceITC:INFO]RegisterForDeviceStatusMdns +[1071670.702 (001709):MdnsService:INFO]RegisterForDeviceStatus() - DiscoveryFilter = 92670b0e-23ae-11e7-9f8e-0242ac110002 +[1071670.702 (001708):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 92670b0e-23ae-11e7-9f8e-0242ac110002, status=1********** +[1071670.702 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=92670b0e-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071671.845 (001708):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=a53a38dc0d4d +[1071671.845 (001708):DiscoveryServiceITC:INFO]RegisterForDeviceStatusMdns +[1071671.845 (001709):MdnsService:INFO]RegisterForDeviceStatus() - DiscoveryFilter = a53a38dc0d4d +[1071671.845 (001708):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= a53a38dc0d4d, status=1********** +[1071671.845 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=935c6ac2-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071672.681 (001709):MdnsService:INFO]Discovered(8639e3d8-23ae-11e7-ae86-0242ac110003) +[1071673.320 (001709):MdnsService:INFO]Resolved(8639e3d8-23ae-11e7-ae86-0242ac110003) +[1071673.973 (001709):MdnsService:INFO]Removed(92670b0e-23ae-11e7-9f8e-0242ac110002) +[1071673.974 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=92670b0e-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071675.790 (001709):MdnsService:INFO]Removed(935c6ac2-23ae-11e7-9f8e-0242ac110002) +[1071675.791 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=935c6ac2-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071676.775 (001708):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071676.775 (001708):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071677.375 (001708):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071677.375 (001708):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071678.944 (001709):MdnsService:INFO]Removed(942baec2-23ae-11e7-9f8e-0242ac110002) +[1071679.528 (001709):MdnsService:INFO]Removed(8639e3d8-23ae-11e7-ae86-0242ac110003) +[1071679.702 (001708):Network:INFO]Received EOS (fd 24) +[1071679.702 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071679.702 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071679.702 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071679.702 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071679.702 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071680.504 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071680.504 (001708):DiscoveryServiceServer:INFO]Create +[1071680.504 (001708):DiscoveryServiceServer:INFO]Initialize +[1071680.504 (001708):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071682.082 (001709):MdnsService:INFO]Discovered(9afb8790-23ae-11e7-9f8e-0242ac110002) +[1071682.083 (001709):MdnsService:INFO]Resolved(9afb8790-23ae-11e7-9f8e-0242ac110002) +[1071682.256 (001708):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=9afb8790-23ae-11e7-9f8e-0242ac110002 +[1071682.256 (001708):DiscoveryServiceITC:INFO]RegisterForDeviceStatusMdns +[1071682.256 (001709):MdnsService:INFO]RegisterForDeviceStatus() - DiscoveryFilter = 9afb8790-23ae-11e7-9f8e-0242ac110002 +[1071682.256 (001708):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 9afb8790-23ae-11e7-9f8e-0242ac110002, status=1********** +[1071682.256 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=9afb8790-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071684.416 (001709):MdnsService:INFO]Removed(9afb8790-23ae-11e7-9f8e-0242ac110002) +[1071684.417 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=9afb8790-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071685.075 (001708):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071685.075 (001708):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071686.019 (001709):MdnsService:INFO]Discovered(9afb8790-23ae-11e7-9f8e-0242ac110002) +[1071686.553 (001709):MdnsService:INFO]Resolved(9afb8790-23ae-11e7-9f8e-0242ac110002) +[1071695.928 (001709):MdnsService:INFO]Removed(9afb8790-23ae-11e7-9f8e-0242ac110002) +[1071699.356 (001708):Network:INFO]Received EOS (fd 24) +[1071699.356 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071699.356 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071699.356 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071699.356 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071699.356 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071700.165 (001708):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071700.165 (001708):DiscoveryServiceServer:INFO]Create +[1071700.165 (001708):DiscoveryServiceServer:INFO]Initialize +[1071700.166 (001708):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071700.424 (001708):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=a6a59ac2-23ae-11e7-9f8e-0242ac110002 +[1071700.424 (001708):DiscoveryServiceITC:INFO]RegisterForDeviceStatusMdns +[1071700.425 (001709):MdnsService:INFO]RegisterForDeviceStatus() - DiscoveryFilter = a6a59ac2-23ae-11e7-9f8e-0242ac110002 +[1071700.425 (001708):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= a6a59ac2-23ae-11e7-9f8e-0242ac110002, status=1********** +[1071701.419 (001709):MdnsService:INFO]Discovered(a6a59ac2-23ae-11e7-9f8e-0242ac110002) +[1071701.883 (001709):MdnsService:INFO]Resolved(a6a59ac2-23ae-11e7-9f8e-0242ac110002) +[1071701.883 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=a6a59ac2-23ae-11e7-9f8e-0242ac110002, DeviceState=ONLINE +[1071703.669 (001709):MdnsService:INFO]Removed(a6a59ac2-23ae-11e7-9f8e-0242ac110002) +[1071703.670 (001708):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackMdns, Name=a6a59ac2-23ae-11e7-9f8e-0242ac110002, DeviceState=OFFLINE +[1071704.335 (001708):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071704.335 (001708):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071705.561 (001708):Network:INFO]Received EOS (fd 24) +[1071705.561 (001708):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071705.561 (001708):DiscoveryServiceServer_Router:INFO]Disconnected +[1071705.561 (001708):DiscoveryServiceServer:INFO]HandleDisconnect +[1071705.561 (001708):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071705.561 (001708):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_44_35DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_44_35DiscoveryTestServer.txt new file mode 100644 index 0000000..1e1471f --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_44_35DiscoveryTestServer.txt @@ -0,0 +1,44 @@ +[1071707.265 (006464):SsdpService:INFO]SsdpService::Initialize +[1071707.265 (006466):MdnsService:INFO]ReconnectClient() +[1071707.265 (006464):SsdpAPI:INFO]Register +[1071707.265 (006464):SsdpAPI:INFO]Register Creating SsdpClient +[1071707.265 (006464):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071707.265 (006464):DiscoveryServiceTestServer:INFO]Server constructor; pid=6464, tid=6464 +[1071707.265 (006464):DiscoveryServiceTestServer:INFO]Initialize; pid=6464, tid=6464 +[1071707.266 (006464):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071707.266 (006464):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071707.266 (006464):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071707.266 (006464):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071707.267 (006466):mDNS:INFO]Connecting... +[1071707.267 (006466):MdnsService:INFO]ReconnectPublisher() +[1071707.413 (006465):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071707.413 (006465):DiscoveryServiceServer:INFO]Create +[1071707.413 (006465):DiscoveryServiceServer:INFO]Initialize +[1071707.919 (006467):mDNS:INFO]Client state: REGISTERING. +WARNING: Unhandled message: interface=(null), path=(null), member=(null) +[1071707.919 (006466):mDNS:INFO]Client state: REGISTERING. +[1071707.919 (006466):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071707.919 (006466):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071707.919 (006466):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071707.920 (006466):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071707.920 (006466):SsdpAPI:INFO]FireRegisteredEvent +[1071707.920 (006466):SsdpService:INFO]Registered() +[1071708.776 (006496):mDNS:INFO]Client state: RUNNING. +[1071708.776 (006467):mDNS:INFO]Client state: RUNNING. +[1071708.776 (006466):MdnsService:INFO]PublisherConnected() +[1071708.776 (006466):MdnsService:INFO]ClientConnected() +[1071710.307 (006465):DiscoveryServiceServer:INFO]MdnsDeviceAnnouncements - name: ac89620c-23ae-11e7-9f8e-0242ac110002 +[1071710.307 (006465):DiscoveryServiceITC:INFO]HandleMediaRendererInitDeviceRequest +[1071710.307 (006466):SsdpService:INFO]BroadcastInitialDeviceAnnouncement +[1071710.307 (006466):SsdpControl:INFO]BroadcastInitialDeviceAnnouncement sending UPnP_SOURCE_MSG_ID_MediaRendererInitDevice +[1071710.308 (006466):MdnsService:INFO]BroadcastInitialDeviceAnnouncement(ac89620c-23ae-11e7-9f8e-0242ac110002) +[1071711.167 (006496):mDNS:INFO]Service ac89620c-23ae-11e7-9f8e-0242ac110002: established +[1071711.167 (006466):MdnsService:INFO]RendererPublished() +[1071711.167 (006466):MdnsService:INFO]Discovered(ac89620c-23ae-11e7-9f8e-0242ac110002) +[1071711.168 (006466):MdnsService:INFO]Resolved(ac89620c-23ae-11e7-9f8e-0242ac110002) +[1071716.422 (006465):Network:INFO]Received EOS (fd 19) +[1071716.422 (006465):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071716.422 (006465):DiscoveryServiceServer_Router:INFO]Disconnected +[1071716.423 (006465):DiscoveryServiceServer:INFO]HandleDisconnect +[1071716.423 (006465):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071716.423 (006465):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_44_47DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_44_47DiscoveryTestServer.txt new file mode 100644 index 0000000..7974fe4 --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_44_47DiscoveryTestServer.txt @@ -0,0 +1,44 @@ +[1071719.654 (006852):SsdpService:INFO]SsdpService::Initialize +[1071719.654 (006854):MdnsService:INFO]ReconnectClient() +[1071719.654 (006852):SsdpAPI:INFO]Register +[1071719.654 (006852):SsdpAPI:INFO]Register Creating SsdpClient +[1071719.655 (006852):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071719.655 (006852):DiscoveryServiceTestServer:INFO]Server constructor; pid=6852, tid=6852 +[1071719.655 (006852):DiscoveryServiceTestServer:INFO]Initialize; pid=6852, tid=6852 +[1071719.655 (006852):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071719.655 (006852):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071719.655 (006852):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071719.655 (006852):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071719.656 (006854):mDNS:INFO]Connecting... +[1071719.656 (006854):MdnsService:INFO]ReconnectPublisher() +[1071719.803 (006853):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071719.803 (006853):DiscoveryServiceServer:INFO]Create +[1071719.803 (006853):DiscoveryServiceServer:INFO]Initialize +[1071719.806 (006853):DiscoveryServiceServer:INFO]MdnsDeviceAnnouncements - name: b232e32c-23ae-11e7-9f8e-0242ac110002 +[1071719.806 (006853):DiscoveryServiceITC:INFO]HandleMediaRendererInitDeviceRequest +[1071744.672 (006854):mDNS:INFO]Connecting... +[1071744.673 (006854):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071744.673 (006854):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071744.673 (006854):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071744.673 (006854):SsdpService:INFO]BroadcastInitialDeviceAnnouncement +[1071744.673 (006854):MdnsService:INFO]BroadcastInitialDeviceAnnouncement(b232e32c-23ae-11e7-9f8e-0242ac110002) +[1071744.673 (006854):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071744.673 (006854):SsdpAPI:INFO]FireRegisteredEvent +[1071744.673 (006854):SsdpService:INFO]Registered() +[1071744.673 (006854):SsdpControl:INFO]BroadcastInitialDeviceAnnouncement sending UPnP_SOURCE_MSG_ID_MediaRendererInitDevice +[1071745.329 (007633):mDNS:INFO]Client state: REGISTERING. +[1071745.329 (006855):mDNS:INFO]Client state: REGISTERING. +[1071746.223 (006855):mDNS:INFO]Client state: RUNNING. +[1071746.223 (007633):mDNS:INFO]Client state: RUNNING. +[1071746.223 (006854):MdnsService:INFO]ClientConnected() +[1071746.224 (006854):MdnsService:INFO]PublisherConnected() +[1071746.403 (006854):MdnsService:INFO]Discovered(b232e32c-23ae-11e7-9f8e-0242ac110002) +[1071747.122 (007633):mDNS:INFO]Service b232e32c-23ae-11e7-9f8e-0242ac110002: established +[1071747.122 (006854):MdnsService:INFO]RendererPublished() +[1071747.123 (006854):MdnsService:INFO]Resolved(b232e32c-23ae-11e7-9f8e-0242ac110002) +[1071749.835 (006853):Network:INFO]Received EOS (fd 19) +[1071749.835 (006853):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071749.835 (006853):DiscoveryServiceServer_Router:INFO]Disconnected +[1071749.835 (006853):DiscoveryServiceServer:INFO]HandleDisconnect +[1071749.835 (006853):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071749.835 (006853):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_45_21DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_45_21DiscoveryTestServer.txt new file mode 100644 index 0000000..6efc270 --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_45_21DiscoveryTestServer.txt @@ -0,0 +1,40 @@ +[1071753.701 (007931):SsdpService:INFO]SsdpService::Initialize +[1071753.701 (007933):MdnsService:INFO]ReconnectClient() +[1071753.701 (007931):SsdpAPI:INFO]Register +[1071753.701 (007931):SsdpAPI:INFO]Register Creating SsdpClient +[1071753.702 (007931):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071753.702 (007931):DiscoveryServiceTestServer:INFO]Server constructor; pid=7931, tid=7931 +[1071753.702 (007931):DiscoveryServiceTestServer:INFO]Initialize; pid=7931, tid=7931 +[1071753.702 (007931):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071753.702 (007931):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071753.702 (007931):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071753.702 (007931):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071753.703 (007933):mDNS:INFO]Connecting... +[1071753.703 (007933):MdnsService:INFO]ReconnectPublisher() +[1071753.852 (007932):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071753.852 (007932):DiscoveryServiceServer:INFO]Create +[1071753.852 (007932):DiscoveryServiceServer:INFO]Initialize +[1071754.393 (007933):mDNS:INFO]Client state: REGISTERING. +[1071754.394 (007934):mDNS:INFO]Client state: REGISTERING. +WARNING: Unhandled message: interface=(null), path=(null), member=(null) +[1071754.394 (007933):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071754.394 (007933):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071754.394 (007933):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071754.395 (007933):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071754.395 (007933):SsdpAPI:INFO]FireRegisteredEvent +[1071754.395 (007933):SsdpService:INFO]Registered() +[1071755.174 (007961):mDNS:INFO]Client state: RUNNING. +[1071755.174 (007933):MdnsService:INFO]PublisherConnected() +[1071755.174 (007934):mDNS:INFO]Client state: RUNNING. +[1071755.174 (007933):MdnsService:INFO]ClientConnected() +[1071756.678 (007932):DiscoveryServiceServer:INFO]MdnsAddService - name: c82d1918-23ae-11e7-9f8e-0242ac110002 +[1071756.678 (007932):DiscoveryServiceITC:INFO]HandleAddServiceRequest +[1071756.678 (007933):MdnsService:INFO]AddService(c82d1918-23ae-11e7-9f8e-0242ac110002 - _testsuperservice._tcp) +[1071757.463 (007961):mDNS:INFO]Service c82d1918-23ae-11e7-9f8e-0242ac110002: established +[1071757.463 (007933):MdnsService:INFO]ServicePublished(c82d1918-23ae-11e7-9f8e-0242ac110002) +[1071762.862 (007932):Network:INFO]Received EOS (fd 17) +[1071762.862 (007932):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071762.862 (007932):DiscoveryServiceServer_Router:INFO]Disconnected +[1071762.862 (007932):DiscoveryServiceServer:INFO]HandleDisconnect +[1071762.862 (007932):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071762.862 (007932):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_45_33DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_45_33DiscoveryTestServer.txt new file mode 100644 index 0000000..865822a --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_45_33DiscoveryTestServer.txt @@ -0,0 +1,38 @@ +[1071765.745 (008323):SsdpService:INFO]SsdpService::Initialize +[1071765.745 (008325):MdnsService:INFO]ReconnectClient() +[1071765.745 (008323):SsdpAPI:INFO]Register +[1071765.745 (008323):SsdpAPI:INFO]Register Creating SsdpClient +[1071765.745 (008323):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071765.745 (008323):DiscoveryServiceTestServer:INFO]Server constructor; pid=8323, tid=8323 +[1071765.745 (008323):DiscoveryServiceTestServer:INFO]Initialize; pid=8323, tid=8323 +[1071765.746 (008323):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071765.746 (008323):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071765.746 (008323):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071765.746 (008323):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071765.747 (008325):mDNS:INFO]Connecting... +[1071765.747 (008325):MdnsService:INFO]ReconnectPublisher() +[1071766.061 (008324):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071766.061 (008324):DiscoveryServiceServer:INFO]Create +[1071766.061 (008324):DiscoveryServiceServer:INFO]Initialize +[1071766.063 (008324):DiscoveryServiceServer:INFO]MdnsAddService - name: cdc52e06-23ae-11e7-9f8e-0242ac110002 +[1071766.063 (008324):DiscoveryServiceITC:INFO]HandleAddServiceRequest +[1071790.767 (008325):mDNS:INFO]Connecting... +[1071790.767 (008325):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071790.767 (008325):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071790.767 (008325):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071790.767 (008325):MdnsService:INFO]AddService(cdc52e06-23ae-11e7-9f8e-0242ac110002 - _testsuperservice._tcp) +[1071790.768 (008325):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071790.768 (008325):SsdpAPI:INFO]FireRegisteredEvent +[1071790.768 (008325):SsdpService:INFO]Registered() +[1071791.353 (008326):mDNS:INFO]Client state: REGISTERING. +[1071791.353 (009090):mDNS:INFO]Client state: REGISTERING. +[1071792.295 (008326):mDNS:INFO]Client state: RUNNING. +[1071792.295 (009090):mDNS:INFO]Client state: RUNNING. +[1071792.295 (008325):MdnsService:INFO]ClientConnected() +[1071792.296 (008325):MdnsService:INFO]PublisherConnected() +[1071796.092 (008324):Network:INFO]Received EOS (fd 17) +[1071796.093 (008324):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071796.093 (008324):DiscoveryServiceServer_Router:INFO]Disconnected +[1071796.093 (008324):DiscoveryServiceServer:INFO]HandleDisconnect +[1071796.093 (008324):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071796.093 (008324):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_46_06DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_46_06DiscoveryTestServer.txt new file mode 100644 index 0000000..97002e5 --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_46_06DiscoveryTestServer.txt @@ -0,0 +1,49 @@ +[1071798.074 (009338):SsdpService:INFO]SsdpService::Initialize +[1071798.074 (009340):MdnsService:INFO]ReconnectClient() +[1071798.074 (009338):SsdpAPI:INFO]Register +[1071798.074 (009338):SsdpAPI:INFO]Register Creating SsdpClient +[1071798.074 (009338):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071798.074 (009338):DiscoveryServiceTestServer:INFO]Server constructor; pid=9338, tid=9338 +[1071798.074 (009338):DiscoveryServiceTestServer:INFO]Initialize; pid=9338, tid=9338 +[1071798.074 (009338):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071798.074 (009338):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071798.074 (009338):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071798.074 (009338):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071798.075 (009340):mDNS:INFO]Connecting... +[1071798.075 (009340):MdnsService:INFO]ReconnectPublisher() +[1071798.222 (009339):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071798.223 (009339):DiscoveryServiceServer:INFO]Create +[1071798.223 (009339):DiscoveryServiceServer:INFO]Initialize +[1071798.571 (009341):mDNS:INFO]Client state: REGISTERING. +WARNING: Unhandled message: interface=(null), path=(null), member=(null) +[1071798.572 (009340):mDNS:INFO]Client state: REGISTERING. +[1071798.572 (009340):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071798.572 (009340):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071798.572 (009340):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071798.572 (009340):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071798.572 (009340):SsdpAPI:INFO]FireRegisteredEvent +[1071798.572 (009340):SsdpService:INFO]Registered() +[1071799.450 (009341):mDNS:INFO]Client state: RUNNING. +[1071799.450 (009360):mDNS:INFO]Client state: RUNNING. +[1071799.450 (009340):MdnsService:INFO]ClientConnected() +[1071799.451 (009340):MdnsService:INFO]PublisherConnected() +[1071800.823 (009339):DiscoveryServiceServer:INFO]MdnsDeviceAnnouncements - name: e27cfebe-23ae-11e7-9f8e-0242ac110002 +[1071800.823 (009339):DiscoveryServiceITC:INFO]HandleMediaRendererInitDeviceRequest +[1071800.823 (009340):SsdpService:INFO]BroadcastInitialDeviceAnnouncement +[1071800.823 (009340):SsdpControl:INFO]BroadcastInitialDeviceAnnouncement sending UPnP_SOURCE_MSG_ID_MediaRendererInitDevice +[1071800.823 (009340):MdnsService:INFO]BroadcastInitialDeviceAnnouncement(e27cfebe-23ae-11e7-9f8e-0242ac110002) +[1071801.707 (009360):mDNS:INFO]Service e27cfebe-23ae-11e7-9f8e-0242ac110002: established +[1071801.707 (009340):MdnsService:INFO]RendererPublished() +[1071801.707 (009340):MdnsService:INFO]Discovered(e27cfebe-23ae-11e7-9f8e-0242ac110002) +[1071801.708 (009340):MdnsService:INFO]Resolved(e27cfebe-23ae-11e7-9f8e-0242ac110002) +[1071803.908 (009339):DiscoveryServiceServer:INFO]MdnsAddService - name: e27d0508-23ae-11e7-9f8e-0242ac110002 +[1071803.908 (009339):DiscoveryServiceITC:INFO]HandleAddServiceRequest +[1071803.908 (009340):MdnsService:INFO]AddService(e27d0508-23ae-11e7-9f8e-0242ac110002 - _testsuperservice._tcp) +[1071804.791 (009360):mDNS:INFO]Service e27d0508-23ae-11e7-9f8e-0242ac110002: established +[1071804.791 (009340):MdnsService:INFO]ServicePublished(e27d0508-23ae-11e7-9f8e-0242ac110002) +[1071810.236 (009339):Network:INFO]Received EOS (fd 17) +[1071810.236 (009339):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071810.236 (009339):DiscoveryServiceServer_Router:INFO]Disconnected +[1071810.236 (009339):DiscoveryServiceServer:INFO]HandleDisconnect +[1071810.236 (009339):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071810.236 (009339):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_46_20DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_46_20DiscoveryTestServer.txt new file mode 100644 index 0000000..155dc30 --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_46_20DiscoveryTestServer.txt @@ -0,0 +1,49 @@ +[1071812.537 (009802):SsdpService:INFO]SsdpService::Initialize +[1071812.537 (009804):MdnsService:INFO]ReconnectClient() +[1071812.537 (009802):SsdpAPI:INFO]Register +[1071812.537 (009802):SsdpAPI:INFO]Register Creating SsdpClient +[1071812.537 (009802):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071812.537 (009802):DiscoveryServiceTestServer:INFO]Server constructor; pid=9802, tid=9802 +[1071812.537 (009802):DiscoveryServiceTestServer:INFO]Initialize; pid=9802, tid=9802 +[1071812.538 (009802):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071812.538 (009802):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071812.538 (009802):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071812.538 (009802):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071812.539 (009804):mDNS:INFO]Connecting... +[1071812.539 (009804):MdnsService:INFO]ReconnectPublisher() +[1071812.701 (009803):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071812.702 (009803):DiscoveryServiceServer:INFO]Create +[1071812.702 (009803):DiscoveryServiceServer:INFO]Initialize +[1071812.705 (009803):DiscoveryServiceServer:INFO]MdnsDeviceAnnouncements - name: e991ff2e-23ae-11e7-9f8e-0242ac110002 +[1071812.705 (009803):DiscoveryServiceITC:INFO]HandleMediaRendererInitDeviceRequest +[1071815.797 (009803):DiscoveryServiceServer:INFO]MdnsAddService - name: e9920424-23ae-11e7-9f8e-0242ac110002 +[1071815.797 (009803):DiscoveryServiceITC:INFO]HandleAddServiceRequest +[1071837.556 (009804):mDNS:INFO]Connecting... +[1071837.556 (009804):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071837.556 (009804):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071837.556 (009804):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071837.556 (009804):SsdpService:INFO]BroadcastInitialDeviceAnnouncement +[1071837.556 (009804):MdnsService:INFO]BroadcastInitialDeviceAnnouncement(e991ff2e-23ae-11e7-9f8e-0242ac110002) +[1071837.556 (009804):MdnsService:INFO]AddService(e9920424-23ae-11e7-9f8e-0242ac110002 - _testsuperservice._tcp) +[1071837.557 (009804):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071837.557 (009804):SsdpAPI:INFO]FireRegisteredEvent +[1071837.557 (009804):SsdpService:INFO]Registered() +[1071837.557 (009804):SsdpControl:INFO]BroadcastInitialDeviceAnnouncement sending UPnP_SOURCE_MSG_ID_MediaRendererInitDevice +[1071838.209 (009805):mDNS:INFO]Client state: REGISTERING. +[1071838.209 (010569):mDNS:INFO]Client state: REGISTERING. +[1071839.172 (009805):mDNS:INFO]Client state: RUNNING. +[1071839.172 (010569):mDNS:INFO]Client state: RUNNING. +[1071839.172 (009804):MdnsService:INFO]ClientConnected() +[1071839.172 (009804):MdnsService:INFO]PublisherConnected() +[1071839.378 (009804):MdnsService:INFO]Discovered(e991ff2e-23ae-11e7-9f8e-0242ac110002) +[1071840.137 (010569):mDNS:INFO]Service e991ff2e-23ae-11e7-9f8e-0242ac110002: established +[1071840.137 (009804):MdnsService:INFO]RendererPublished() +[1071840.137 (009804):MdnsService:INFO]Resolved(e991ff2e-23ae-11e7-9f8e-0242ac110002) +[1071840.139 (010569):mDNS:INFO]Service e9920424-23ae-11e7-9f8e-0242ac110002: established +[1071840.139 (009804):MdnsService:INFO]ServicePublished(e9920424-23ae-11e7-9f8e-0242ac110002) +[1071843.734 (009803):Network:INFO]Received EOS (fd 19) +[1071843.734 (009803):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071843.734 (009803):DiscoveryServiceServer_Router:INFO]Disconnected +[1071843.734 (009803):DiscoveryServiceServer:INFO]HandleDisconnect +[1071843.734 (009803):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071843.734 (009803):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_46_53DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_46_53DiscoveryTestServer.txt new file mode 100644 index 0000000..b1fe954 --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_46_53DiscoveryTestServer.txt @@ -0,0 +1,50 @@ +[1071845.719 (010840):SsdpService:INFO]SsdpService::Initialize +[1071845.719 (010844):MdnsService:INFO]ReconnectClient() +[1071845.719 (010840):SsdpAPI:INFO]Register +[1071845.719 (010840):SsdpAPI:INFO]Register Creating SsdpClient +[1071845.719 (010840):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071845.719 (010840):DiscoveryServiceTestServer:INFO]Server constructor; pid=10840, tid=10840 +[1071845.719 (010840):DiscoveryServiceTestServer:INFO]Initialize; pid=10840, tid=10840 +[1071845.719 (010840):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071845.719 (010840):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071845.719 (010840):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071845.719 (010840):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071845.720 (010844):mDNS:INFO]Connecting... +[1071845.720 (010844):MdnsService:INFO]ReconnectPublisher() +[1071846.109 (010843):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071846.109 (010843):DiscoveryServiceServer:INFO]Create +[1071846.109 (010843):DiscoveryServiceServer:INFO]Initialize +[1071846.624 (010845):mDNS:INFO]Client state: REGISTERING. +WARNING: Unhandled message: interface=(null), path=(null), member=(null) +[1071846.624 (010844):mDNS:INFO]Client state: REGISTERING. +[1071846.625 (010844):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071846.625 (010844):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071846.625 (010844):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071846.625 (010844):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071846.625 (010844):SsdpAPI:INFO]FireRegisteredEvent +[1071846.625 (010844):SsdpService:INFO]Registered() +[1071847.434 (010845):mDNS:INFO]Client state: RUNNING. +[1071847.434 (010881):mDNS:INFO]Client state: RUNNING. +[1071847.434 (010844):MdnsService:INFO]ClientConnected() +[1071847.435 (010844):MdnsService:INFO]PublisherConnected() +[1071848.963 (010843):DiscoveryServiceServer:INFO]MdnsAddService - name: ff2eaeae-23ae-11e7-9f8e-0242ac110002 +[1071848.963 (010843):DiscoveryServiceITC:INFO]HandleAddServiceRequest +[1071848.963 (010844):MdnsService:INFO]AddService(ff2eaeae-23ae-11e7-9f8e-0242ac110002 - _testsuperservice0._tcp) +[1071849.775 (010881):mDNS:INFO]Service ff2eaeae-23ae-11e7-9f8e-0242ac110002: established +[1071849.775 (010844):MdnsService:INFO]ServicePublished(ff2eaeae-23ae-11e7-9f8e-0242ac110002) +[1071852.049 (010843):DiscoveryServiceServer:INFO]MdnsAddService - name: 0105a07a-23af-11e7-9f8e-0242ac110002 +[1071852.049 (010843):DiscoveryServiceITC:INFO]HandleAddServiceRequest +[1071852.049 (010844):MdnsService:INFO]AddService(0105a07a-23af-11e7-9f8e-0242ac110002 - _testsuperservice1._tcp) +[1071852.861 (010881):mDNS:INFO]Service 0105a07a-23af-11e7-9f8e-0242ac110002: established +[1071852.861 (010844):MdnsService:INFO]ServicePublished(0105a07a-23af-11e7-9f8e-0242ac110002) +[1071855.147 (010843):DiscoveryServiceServer:INFO]MdnsAddService - name: 02de584c-23af-11e7-9f8e-0242ac110002 +[1071855.147 (010843):DiscoveryServiceITC:INFO]HandleAddServiceRequest +[1071855.147 (010844):MdnsService:INFO]AddService(02de584c-23af-11e7-9f8e-0242ac110002 - _testsuperservice2._tcp) +[1071855.959 (010881):mDNS:INFO]Service 02de584c-23af-11e7-9f8e-0242ac110002: established +[1071855.960 (010844):MdnsService:INFO]ServicePublished(02de584c-23af-11e7-9f8e-0242ac110002) +[1071862.125 (010843):Network:INFO]Received EOS (fd 17) +[1071862.125 (010843):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071862.125 (010843):DiscoveryServiceServer_Router:INFO]Disconnected +[1071862.125 (010843):DiscoveryServiceServer:INFO]HandleDisconnect +[1071862.125 (010843):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071862.125 (010843):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_47_13DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_47_13DiscoveryTestServer.txt new file mode 100644 index 0000000..5eb7181 --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_47_13DiscoveryTestServer.txt @@ -0,0 +1,48 @@ +[1071865.191 (011458):SsdpService:INFO]SsdpService::Initialize +[1071865.191 (011460):MdnsService:INFO]ReconnectClient() +[1071865.191 (011458):SsdpAPI:INFO]Register +[1071865.191 (011458):SsdpAPI:INFO]Register Creating SsdpClient +[1071865.191 (011458):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071865.191 (011458):DiscoveryServiceTestServer:INFO]Server constructor; pid=11458, tid=11458 +[1071865.191 (011458):DiscoveryServiceTestServer:INFO]Initialize; pid=11458, tid=11458 +[1071865.191 (011458):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071865.191 (011458):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071865.191 (011458):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071865.191 (011458):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071865.192 (011460):mDNS:INFO]Connecting... +[1071865.192 (011460):MdnsService:INFO]ReconnectPublisher() +[1071865.439 (011459):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071865.439 (011459):DiscoveryServiceServer:INFO]Create +[1071865.439 (011459):DiscoveryServiceServer:INFO]Initialize +[1071865.912 (011461):mDNS:INFO]Client state: REGISTERING. +WARNING: Unhandled message: interface=(null), path=(null), member=(null) +[1071865.913 (011460):mDNS:INFO]Client state: REGISTERING. +[1071865.913 (011460):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071865.913 (011460):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071865.913 (011460):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071865.913 (011460):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071865.914 (011460):SsdpAPI:INFO]FireRegisteredEvent +[1071865.914 (011460):SsdpService:INFO]Registered() +[1071866.811 (011461):mDNS:INFO]Client state: RUNNING. +[1071866.811 (011460):MdnsService:INFO]ClientConnected() +[1071866.811 (011487):mDNS:INFO]Client state: RUNNING. +[1071866.812 (011460):MdnsService:INFO]PublisherConnected() +[1071868.247 (011459):DiscoveryServiceServer:INFO]MdnsAddService - name: 0aad281e-23af-11e7-9f8e-0242ac110002 +[1071868.247 (011459):DiscoveryServiceITC:INFO]HandleAddServiceRequest +[1071868.247 (011460):MdnsService:INFO]AddService(0aad281e-23af-11e7-9f8e-0242ac110002 - _addremoveservice0._tcp) +[1071869.149 (011487):mDNS:INFO]Service 0aad281e-23af-11e7-9f8e-0242ac110002: established +[1071869.149 (011460):MdnsService:INFO]ServicePublished(0aad281e-23af-11e7-9f8e-0242ac110002) +[1071871.383 (011459):DiscoveryServiceServer:INFO]MdnsAddService - name: 0c8bc0f0-23af-11e7-9f8e-0242ac110002 +[1071871.383 (011459):DiscoveryServiceITC:INFO]HandleAddServiceRequest +[1071871.383 (011460):MdnsService:INFO]AddService(0c8bc0f0-23af-11e7-9f8e-0242ac110002 - _addremoveservice1._tcp) +[1071872.284 (011487):mDNS:INFO]Service 0c8bc0f0-23af-11e7-9f8e-0242ac110002: established +[1071872.284 (011460):MdnsService:INFO]ServicePublished(0c8bc0f0-23af-11e7-9f8e-0242ac110002) +[1071877.145 (011459):DiscoveryServiceServer:INFO]MdnsRemoveService - name: 0aad281e-23af-11e7-9f8e-0242ac110002 +[1071877.145 (011459):DiscoveryServiceITC:INFO]HandleRemoveServiceRequest +[1071877.146 (011460):MdnsService:INFO]RemoveService(0aad281e-23af-11e7-9f8e-0242ac110002 - _addremoveservice0._tcp) +[1071882.456 (011459):Network:INFO]Received EOS (fd 17) +[1071882.456 (011459):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071882.456 (011459):DiscoveryServiceServer_Router:INFO]Disconnected +[1071882.456 (011459):DiscoveryServiceServer:INFO]HandleDisconnect +[1071882.457 (011459):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071882.457 (011459):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_47_32DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_47_32DiscoveryTestServer.txt new file mode 100644 index 0000000..bc9bd88 --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_47_32DiscoveryTestServer.txt @@ -0,0 +1,49 @@ +[1071884.795 (012076):SsdpService:INFO]SsdpService::Initialize +[1071884.795 (012078):MdnsService:INFO]ReconnectClient() +[1071884.795 (012076):SsdpAPI:INFO]Register +[1071884.795 (012076):SsdpAPI:INFO]Register Creating SsdpClient +[1071884.795 (012076):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071884.795 (012076):DiscoveryServiceTestServer:INFO]Server constructor; pid=12076, tid=12076 +[1071884.795 (012076):DiscoveryServiceTestServer:INFO]Initialize; pid=12076, tid=12076 +[1071884.795 (012076):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071884.795 (012076):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071884.795 (012076):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071884.795 (012076):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071884.797 (012078):mDNS:INFO]Connecting... +[1071884.797 (012078):MdnsService:INFO]ReconnectPublisher() +[1071884.959 (012077):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071884.959 (012077):DiscoveryServiceServer:INFO]Create +[1071884.959 (012077):DiscoveryServiceServer:INFO]Initialize +[1071885.051 (012077):DiscoveryServiceServer:INFO]RegisterForServiceStatus() +[1071885.051 (012077):DiscoveryServiceITC:INFO]RegisterForServiceStatus +[1071909.799 (012078):mDNS:INFO]Connecting... +[1071909.799 (012078):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071909.799 (012078):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071909.799 (012078):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071909.799 (012078):SsdpService:INFO]RegisterForServiceStatus() +[1071909.799 (012077):DiscoveryServiceServer:INFO]ServiceStatusCallback() +[1071909.799 (012077):DiscoveryServiceServer:INFO]ServiceStatusCallback(), sending status: RESTARTING, protocol: 2 +[1071909.799 (012078):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071909.800 (012078):SsdpAPI:INFO]FireRegisteredEvent +[1071909.800 (012078):SsdpService:INFO]Registered() +[1071910.657 (012855):mDNS:INFO]Client state: REGISTERING. +[1071910.657 (012079):mDNS:INFO]Client state: REGISTERING. +[1071911.420 (012079):mDNS:INFO]Client state: RUNNING. +[1071911.420 (012855):mDNS:INFO]Client state: RUNNING. +[1071911.420 (012078):MdnsService:INFO]ClientConnected() +[1071911.421 (012078):MdnsService:INFO]PublisherConnected() +[1071911.421 (012077):DiscoveryServiceServer:INFO]ServiceStatusCallback() +[1071911.421 (012077):DiscoveryServiceServer:INFO]ServiceStatusCallback(), sending status: AVAILABLE, protocol: 2 +[1071913.765 (012855):mDNS:ERROR]ClientStatus: Daemon connection failed at /scratch/scm/Lisa/trunk/sandbox3/Core/MDNS/AvahiImpl.cpp line 371 +[1071913.765 (012079):mDNS:ERROR]ClientStatus: Daemon connection failed at /scratch/scm/Lisa/trunk/sandbox3/Core/MDNS/AvahiImpl.cpp line 371 +[1071913.765 (012078):MdnsService:INFO]ReconnectPublisher() +[1071913.767 (012078):mDNS:INFO]Connecting... +[1071913.767 (012078):MdnsService:INFO]ReconnectClient() +[1071913.767 (012077):DiscoveryServiceServer:INFO]ServiceStatusCallback() +[1071913.767 (012077):DiscoveryServiceServer:INFO]ServiceStatusCallback(), sending status: RESTARTING, protocol: 2 +[1071916.898 (012077):Network:INFO]Received EOS (fd 17) +[1071916.898 (012077):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071916.898 (012077):DiscoveryServiceServer_Router:INFO]Disconnected +[1071916.898 (012077):DiscoveryServiceServer:INFO]HandleDisconnect +[1071916.898 (012077):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071916.898 (012077):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_48_06DiscoveryTestServer.txt b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_48_06DiscoveryTestServer.txt new file mode 100644 index 0000000..9a7bf1a --- /dev/null +++ b/Python_Assignment/Exercise_6/log_files/log-2017-04-17-20_48_06DiscoveryTestServer.txt @@ -0,0 +1,309 @@ +[1071918.623 (013154):SsdpService:INFO]SsdpService::Initialize +[1071918.623 (013158):MdnsService:INFO]ReconnectClient() +[1071918.623 (013154):SsdpAPI:INFO]Register +[1071918.623 (013154):SsdpAPI:INFO]Register Creating SsdpClient +[1071918.623 (013154):DiscoveryServiceITC:INFO]DiscoveryServiceITC Constructor... +[1071918.623 (013154):DiscoveryServiceTestServer:INFO]Server constructor; pid=13154, tid=13154 +[1071918.623 (013154):DiscoveryServiceTestServer:INFO]Initialize; pid=13154, tid=13154 +[1071918.624 (013154):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071918.624 (013154):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071918.624 (013154):IPCDirectory:INFO]DefaultAddress: Service 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' +[1071918.624 (013154):DiscoveryServiceServerListener:INFO]Serving address: stream://localhost:40028?no_delay&nonblocking +[1071918.626 (013158):mDNS:INFO]Client state: REGISTERING. +[1071918.626 (013158):MdnsService:INFO]ReconnectPublisher() +[1071918.628 (013158):mDNS:INFO]Client state: REGISTERING. +[1071918.628 (013158):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071918.628 (013158):IPCDirectory:ERROR]stat services.json: No such file or directory +[1071918.628 (013158):IPCDirectory:INFO]DefaultAddress: Service 'SsdpControl' at 'stream://localhost:40010?no_delay&nonblocking' +[1071918.628 (013158):SsdpControl:INFO]Creating router with name SsdpControl_Router +[1071918.629 (013158):SsdpAPI:INFO]FireRegisteredEvent +[1071918.629 (013158):SsdpService:INFO]Registered() +[1071918.749 (013160):mDNS:INFO]Client state: RUNNING. +[1071918.749 (013159):mDNS:INFO]Client state: RUNNING. +[1071918.749 (013158):MdnsService:INFO]PublisherConnected() +[1071918.749 (013158):MdnsService:INFO]ClientConnected() +[1071918.782 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071918.782 (013157):DiscoveryServiceServer:INFO]Create +[1071918.782 (013157):DiscoveryServiceServer:INFO]Initialize +[1071918.925 (013158):MdnsService:INFO]Discovered(267cb2da-23af-11e7-ae86-0242ac110003) +[1071918.926 (013158):MdnsService:INFO]Resolved(267cb2da-23af-11e7-ae86-0242ac110003) +[1071920.093 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=28e5e546-23af-11e7-9f8e-0242ac110002 +[1071920.093 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1071920.093 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 28e5e546-23af-11e7-9f8e-0242ac110002 +[1071920.093 (013158):SsdpAPI:INFO]RegisterForMediaServerDeviceStatus +[1071920.093 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 28e5e546-23af-11e7-9f8e-0242ac110002, status=1********** +[1071920.094 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=28e5e546-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:d52943c6-23ae-11e7-ae86-0242ac110003,location=http://172.17.0.2:42023/28e5e546-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071920.094 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071921.979 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=28e5e546-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:28e5e546-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:42023/28e5e546-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071921.979 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071923.226 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=28e5e546-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:28e5e546-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:42023/28e5e546-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1071923.226 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071924.544 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071924.544 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071924.544 (013158):SsdpAPI:INFO]UnRegisterForMediaServerDeviceStatus +[1071924.569 (013158):MdnsService:INFO]Removed(267cb2da-23af-11e7-ae86-0242ac110003) +[1071925.795 (013157):Network:INFO]Received EOS (fd 24) +[1071925.795 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071925.795 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1071925.796 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1071925.796 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071925.796 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071926.771 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071926.771 (013157):DiscoveryServiceServer:INFO]Create +[1071926.771 (013157):DiscoveryServiceServer:INFO]Initialize +[1071926.771 (013157):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071928.422 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=2de9b914-23af-11e7-9f8e-0242ac110002 +[1071928.422 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1071928.422 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 2de9b914-23af-11e7-9f8e-0242ac110002 +[1071928.422 (013158):SsdpAPI:INFO]RegisterForMediaServerDeviceStatus +[1071928.422 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 2de9b914-23af-11e7-9f8e-0242ac110002, status=1********** +[1071930.964 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=2de9b914-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:2de9b914-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:41254/2de9b914-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071930.964 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071931.587 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=2de9b914-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:2de9b914-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:41254/2de9b914-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1071931.587 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071935.968 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=2de9b914-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:2de9b914-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:44438/2de9b914-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071935.968 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071936.993 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=2de9b914-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:2de9b914-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:44438/2de9b914-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1071936.993 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071941.977 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=2de9b914-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:2de9b914-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:39935/2de9b914-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071941.977 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071943.264 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=2de9b914-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:2de9b914-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:39935/2de9b914-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1071943.264 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071944.686 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071944.686 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071944.686 (013158):SsdpAPI:INFO]UnRegisterForMediaServerDeviceStatus +[1071946.220 (013157):Network:INFO]Received EOS (fd 24) +[1071946.220 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071946.220 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1071946.221 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1071946.221 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071946.221 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071947.355 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071947.355 (013157):DiscoveryServiceServer:INFO]Create +[1071947.355 (013157):DiscoveryServiceServer:INFO]Initialize +[1071947.355 (013157):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071954.379 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=3a151c56-23af-11e7-9f8e-0242ac110002 +[1071954.379 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1071954.379 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 3a151c56-23af-11e7-9f8e-0242ac110002 +[1071954.379 (013158):SsdpAPI:INFO]RegisterForMediaServerDeviceStatus +[1071954.380 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 3a151c56-23af-11e7-9f8e-0242ac110002, status=1********** +[1071954.380 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=3a151c56-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:d52943c6-23ae-11e7-ae86-0242ac110003,location=http://172.17.0.2:34749/3a151c56-23af-11e7-9f8e-0242ac110002/description-2.xml, DeviceState=ONLINE +[1071954.380 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071990.015 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1071990.015 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1071990.016 (013158):SsdpAPI:INFO]UnRegisterForMediaServerDeviceStatus +[1071991.267 (013157):Network:INFO]Received EOS (fd 24) +[1071991.267 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1071991.267 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1071991.267 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1071991.267 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1071991.267 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1071991.783 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1071991.783 (013157):DiscoveryServiceServer:INFO]Create +[1071991.783 (013157):DiscoveryServiceServer:INFO]Initialize +[1071991.783 (013157):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1071995.320 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=54732840-23af-11e7-9f8e-0242ac110002 +[1071995.320 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1071995.320 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 54732840-23af-11e7-9f8e-0242ac110002 +[1071995.320 (013158):SsdpAPI:INFO]RegisterForMediaServerDeviceStatus +[1071995.320 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 54732840-23af-11e7-9f8e-0242ac110002, status=1********** +[1071995.321 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=54732840-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:3a151c56-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:44270/54732840-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071995.321 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=54732840-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:54732840-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:44270/54732840-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071995.321 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=54732840-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:d52943c6-23ae-11e7-ae86-0242ac110003,location=http://172.17.0.2:44270/54732840-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071995.321 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071995.321 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071995.321 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071996.680 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=552b98f8-23af-11e7-9f8e-0242ac110002 +[1071996.680 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1071996.680 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 552b98f8-23af-11e7-9f8e-0242ac110002 +[1071996.680 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 552b98f8-23af-11e7-9f8e-0242ac110002, status=1********** +[1071996.681 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=54732840-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:3a151c56-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:44270/54732840-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071996.681 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=54732840-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:54732840-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:44270/54732840-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071996.681 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071996.681 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=54732840-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:d52943c6-23ae-11e7-ae86-0242ac110003,location=http://172.17.0.2:44270/54732840-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071996.681 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071996.681 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071996.969 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=552b98f8-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:552b98f8-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:33360/552b98f8-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1071996.969 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1071999.542 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=54732840-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:54732840-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:44270/54732840-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1071999.542 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072000.768 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=552b98f8-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:552b98f8-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:33360/552b98f8-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1072000.768 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072001.810 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1072001.810 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1072002.493 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1072002.493 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1072002.493 (013158):SsdpAPI:INFO]UnRegisterForMediaServerDeviceStatus +[1072004.745 (013157):Network:INFO]Received EOS (fd 24) +[1072004.745 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1072004.745 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1072004.746 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1072004.746 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1072004.746 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1072005.271 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1072005.271 (013157):DiscoveryServiceServer:INFO]Create +[1072005.271 (013157):DiscoveryServiceServer:INFO]Initialize +[1072005.271 (013157):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1072006.430 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=5c706b84-23af-11e7-9f8e-0242ac110002 +[1072006.430 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1072006.430 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 5c706b84-23af-11e7-9f8e-0242ac110002 +[1072006.430 (013158):SsdpAPI:INFO]RegisterForMediaServerDeviceStatus +[1072006.430 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 5c706b84-23af-11e7-9f8e-0242ac110002, status=1********** +[1072006.431 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=5c706b84-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:3a151c56-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:43482/5c706b84-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1072006.431 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=5c706b84-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:d52943c6-23ae-11e7-ae86-0242ac110003,location=http://172.17.0.2:43482/5c706b84-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1072006.431 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072006.431 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072008.969 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=5c706b84-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:5c706b84-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:43482/5c706b84-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1072008.969 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072009.652 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=5c706b84-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:5c706b84-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:43482/5c706b84-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1072009.652 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072010.607 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1072010.607 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1072010.607 (013158):SsdpAPI:INFO]UnRegisterForMediaServerDeviceStatus +[1072016.889 (013157):Network:INFO]Received EOS (fd 24) +[1072016.889 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1072016.889 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1072016.889 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1072016.889 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1072016.889 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1072017.464 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1072017.464 (013157):DiscoveryServiceServer:INFO]Create +[1072017.464 (013157):DiscoveryServiceServer:INFO]Initialize +[1072017.464 (013157):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1072017.739 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=63ba0a94-23af-11e7-9f8e-0242ac110002 +[1072017.739 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1072017.739 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 63ba0a94-23af-11e7-9f8e-0242ac110002 +[1072017.739 (013158):SsdpAPI:INFO]RegisterForMediaServerDeviceStatus +[1072017.739 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 63ba0a94-23af-11e7-9f8e-0242ac110002, status=1********** +[1072020.969 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=63ba0a94-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:63ba0a94-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:44664/63ba0a94-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1072020.969 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072021.632 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=63ba0a94-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:63ba0a94-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:44664/63ba0a94-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1072021.632 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072022.707 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1072022.707 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1072022.707 (013158):SsdpAPI:INFO]UnRegisterForMediaServerDeviceStatus +[1072024.224 (013157):Network:INFO]Received EOS (fd 24) +[1072024.224 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1072024.224 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1072024.225 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1072024.225 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1072024.225 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1072024.857 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1072024.857 (013157):DiscoveryServiceServer:INFO]Create +[1072024.857 (013157):DiscoveryServiceServer:INFO]Initialize +[1072024.858 (013157):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1072025.950 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=68317bd4-23af-11e7-9f8e-0242ac110002 +[1072025.950 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1072025.950 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 68317bd4-23af-11e7-9f8e-0242ac110002 +[1072025.950 (013158):SsdpAPI:INFO]RegisterForMediaServerDeviceStatus +[1072025.950 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 68317bd4-23af-11e7-9f8e-0242ac110002, status=1********** +[1072026.264 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=685000c2-23af-11e7-9f8e-0242ac110002 +[1072026.265 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1072026.265 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 685000c2-23af-11e7-9f8e-0242ac110002 +[1072026.265 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 685000c2-23af-11e7-9f8e-0242ac110002, status=1********** +[1072026.579 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=686e8a56-23af-11e7-9f8e-0242ac110002 +[1072026.579 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1072026.579 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 686e8a56-23af-11e7-9f8e-0242ac110002 +[1072026.579 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 686e8a56-23af-11e7-9f8e-0242ac110002, status=1********** +[1072026.893 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=688e5ad4-23af-11e7-9f8e-0242ac110002 +[1072026.893 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1072026.893 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 688e5ad4-23af-11e7-9f8e-0242ac110002 +[1072026.894 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 688e5ad4-23af-11e7-9f8e-0242ac110002, status=1********** +[1072027.158 (013157):DiscoveryServiceServer:INFO]RegisterForDeviceStatus() filter=68ace4fe-23af-11e7-9f8e-0242ac110002 +[1072027.158 (013157):DiscoveryServiceITC:INFO]RegisterForDeviceStatusSSDP +[1072027.158 (013158):SsdpService:INFO]RegisterForDeviceStatus() - DiscoveryFilter= 68ace4fe-23af-11e7-9f8e-0242ac110002 +[1072027.158 (013157):DiscoveryServiceServer:INFO]RegistrationStatusCallback()****Filter= 68ace4fe-23af-11e7-9f8e-0242ac110002, status=1********** +[1072030.980 (013158):SsdpService:INFO]HandleDeviceStatus()-ERROR while Calling cb for registered filter=68317bd4-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:68317bd4-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:46813/68317bd4-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1072030.980 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072031.603 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=68317bd4-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:68317bd4-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:46813/68317bd4-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1072031.603 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072035.965 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=685000c2-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:685000c2-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:43608/685000c2-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1072035.965 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072036.528 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=685000c2-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:685000c2-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:43608/685000c2-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1072036.528 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072040.971 (013158):SsdpService:INFO]HandleDeviceStatus()-Calling cb for registered filter=686e8a56-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:686e8a56-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:36813/686e8a56-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=ONLINE +[1072040.971 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072041.513 (013158):SsdpService:INFO]HandleDeviceStatus()-[ERROR] while Calling cb for registered filter=686e8a56-23af-11e7-9f8e-0242ac110002, DeviceInfo.id=uuid:686e8a56-23af-11e7-9f8e-0242ac110002,location=http://172.17.0.2:36813/686e8a56-23af-11e7-9f8e-0242ac110002/description-1.xml, DeviceState=OFFLINE +[1072041.514 (013157):DiscoveryServiceServer:INFO]DeviceDiscoveryCallbackSsdp +[1072042.837 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1072042.837 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1072043.329 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1072043.329 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1072043.821 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1072043.821 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1072044.313 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1072044.313 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1072045.005 (013157):DiscoveryServiceServer:INFO]UnregisterForDeviceStatus +[1072045.005 (013157):DiscoveryServiceITC:INFO]UnRegisterForDeviceStatus +[1072045.005 (013158):SsdpAPI:INFO]UnRegisterForMediaServerDeviceStatus +[1072048.283 (013157):Network:INFO]Received EOS (fd 24) +[1072048.283 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1072048.283 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1072048.283 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1072048.283 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1072048.283 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1072048.890 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1072048.890 (013157):DiscoveryServiceServer:INFO]Create +[1072048.890 (013157):DiscoveryServiceServer:INFO]Initialize +[1072048.891 (013157):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1072055.561 (013157):DiscoveryServiceServer:INFO]GetDeviceList +[1072055.561 (013157):DiscoveryServiceITC:INFO]GetDeviceList +[1072055.561 (013158):SsdpService:INFO]GetDeviceList +[1072055.562 (013157):DiscoveryServiceServer:INFO]MediaServerListResponse +[1072061.648 (013157):DiscoveryServiceServer:INFO]GetDeviceList +[1072061.648 (013157):DiscoveryServiceITC:INFO]GetDeviceList +[1072061.648 (013158):SsdpService:INFO]GetDeviceList +[1072061.649 (013157):DiscoveryServiceServer:INFO]MediaServerListResponse +[1072062.924 (013157):Network:INFO]Received EOS (fd 24) +[1072062.924 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1072062.924 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1072062.924 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1072062.924 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1072062.924 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1072063.500 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1072063.500 (013157):DiscoveryServiceServer:INFO]Create +[1072063.500 (013157):DiscoveryServiceServer:INFO]Initialize +[1072063.500 (013157):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1072072.705 (013157):DiscoveryServiceServer:INFO]GetDeviceList +[1072072.705 (013157):DiscoveryServiceITC:INFO]GetDeviceList +[1072072.705 (013158):SsdpService:INFO]GetDeviceList +[1072072.706 (013157):DiscoveryServiceServer:INFO]MediaServerListResponse +[1072079.294 (013157):DiscoveryServiceServer:INFO]GetDeviceList +[1072079.294 (013157):DiscoveryServiceITC:INFO]GetDeviceList +[1072079.294 (013158):SsdpService:INFO]GetDeviceList +[1072079.295 (013157):DiscoveryServiceServer:INFO]MediaServerListResponse +[1072081.579 (013157):Network:INFO]Received EOS (fd 24) +[1072081.579 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1072081.579 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1072081.579 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1072081.579 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1072081.579 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set +[1072082.145 (013157):DiscoveryServiceTestServer:INFO]AcceptNewClient - START +[1072082.145 (013157):DiscoveryServiceServer:INFO]Create +[1072082.145 (013157):DiscoveryServiceServer:INFO]Initialize +[1072082.145 (013157):DiscoveryServiceServer:INFO]~DiscoveryServiceServer +[1072082.873 (013159):mDNS:ERROR]ClientStatus: Daemon connection failed at /scratch/scm/Lisa/trunk/sandbox3/Core/MDNS/AvahiImpl.cpp line 371 +[1072082.873 (013160):mDNS:ERROR]ClientStatus: Daemon connection failed at /scratch/scm/Lisa/trunk/sandbox3/Core/MDNS/AvahiImpl.cpp line 371 +[1072082.874 (013158):MdnsService:INFO]ReconnectClient() +[1072082.875 (013158):mDNS:INFO]Connecting... +[1072082.875 (013158):MdnsService:INFO]ReconnectPublisher() +[1072083.619 (018370):mDNS:INFO]Client state: REGISTERING. +WARNING: Unhandled message: interface=(null), path=(null), member=(null) +[1072083.619 (013158):mDNS:INFO]Client state: REGISTERING. +[1072084.530 (018370):mDNS:INFO]Client state: RUNNING. +[1072084.530 (018401):mDNS:INFO]Client state: RUNNING. +[1072084.530 (013158):MdnsService:INFO]ClientConnected() +[1072084.530 (013158):MdnsService:INFO]PublisherConnected() +[1072084.716 (013158):MdnsService:INFO]Discovered(8b3706b2-23af-11e7-9f8e-0242ac110002) +[1072085.443 (013158):MdnsService:INFO]Resolved(8b3706b2-23af-11e7-9f8e-0242ac110002) +[1072090.833 (013157):DiscoveryServiceServer:INFO]GetDeviceList +[1072090.834 (013157):DiscoveryServiceITC:INFO]GetDeviceList +[1072090.834 (013158):SsdpService:INFO]GetDeviceList +[1072090.834 (013157):DiscoveryServiceServer:INFO]MediaServerListResponse +[1072093.027 (013158):MdnsService:INFO]Removed(8b3706b2-23af-11e7-9f8e-0242ac110002) +[1072093.111 (013157):Network:INFO]Received EOS (fd 24) +[1072093.111 (013157):DiscoveryServiceServer_Router:WARNING]HandleSocketActivity: Receive failed, disconnecting +[1072093.111 (013157):DiscoveryServiceServer_Router:INFO]Disconnected +[1072093.111 (013157):DiscoveryServiceServer:INFO]HandleDisconnect +[1072093.111 (013157):DiscoveryServiceServer_Router:INFO]Disconnect Requested... +[1072093.111 (013157):DiscoveryServiceServer_Router:INFO]Disconnected when socket is not set diff --git a/Python_Assignment/Exercise_6/six.py b/Python_Assignment/Exercise_6/six.py new file mode 100644 index 0000000..5cac454 --- /dev/null +++ b/Python_Assignment/Exercise_6/six.py @@ -0,0 +1,113 @@ +''' + +Create a class for processing log statistics for attached device log files. +Constructor of this class accepts one argument which is the path to a folder containing all log files to process. +Class should contain a method to start processing all files on demand. +Once processing is completed, the required statistics should be loaded to class members as follows. + +- num_of_errors = + +- num_of_warnings = + +- num_of_info = + +- num_of_log_lines = + +All above statistics should be computed based on processing of all the log files existing in the folder. +Make sure that computation is based on tags available in square brackets at the start of log lines and not from the message portion of log. \ + +i.e. Consider below fragment of log + +[1071765.746 (008323):IPCDirectory:ERROR]stat services.json: No such file or directory + +[1071765.746 (008323):IPCDirectory:INFO]DefaultAddress: Service ERROR 'DiscoveryService' at 'stream://localhost:40028?no_delay&nonblocking' + +[1071765.746 (008323):IPCDirectory:INFO]Creation: Class WARNING at debug 'level' at 'stream://localhost:40028?no_delay&nonblocking' + +Output of program: + +- num_of_errors = 1 + +- num_of_warnings = 0 + +- num_of_info = 2 + +- num_of_log_lines = 3 + +Class has a print_stats method which prints the above statistics. Create instance of class and call required methods in the main program. + +Attachments: 12 log*.txt files +''' +import os +import sys +class Statistics: + + def __init__(self, log_path): + # changing path to display all log files which are in log folder + os.chdir(log_path) + + def start_logging(self): + #Variables that stores total number of statistics + self.total_num_of_errors=0 + self.total_num_of_warnings = 0 + self.total_num_of_info = 0 + self.total_num_of_log_lines = 0 + + for log_files in os.listdir(): + #Print opened log file's name + print(log_files) + + with open(log_files) as f: + + #Reading all lines of opened file + log_file = f.readlines() + + #Initializing variables to zero whenever new file open + self.num_of_errors = 0 + self.num_of_warnings = 0 + self.num_of_info = 0 + self.num_of_log_lines = 0 + + #Reading all lines one by one from file + for f_line in log_file: + + between_braces=f_line[f_line.find('[')+1 : f_line.find(']')] + + # if found ERROR then increases the num_of_errors counter + if "ERROR" in between_braces: + self.num_of_errors += 1 + self.total_num_of_errors +=1 + # if found WARNING then increases the num_of_warnings counter + if "WARNING" in between_braces: + self.num_of_warnings += 1 + self.total_num_of_warnings += 1 + # if found INFO then increases the num_of_info counter + if "INFO" in between_braces: + self.num_of_info += 1 + self.total_num_of_info += 1 + # Increasing line counter whenever new line read + self.num_of_log_lines += 1 + self.total_num_of_log_lines+=1 + + # calling print_stats method to print data each time whenever file close + self.print_stats() + #Calling print_total_stats method to print total statistics of all log file + self.print_total_stats() + + # Function that prints all counters (num_of_errors, num_of_warnings, num_of_info, num_of_log_lines) + def print_stats(self): + + print("num_of_errors-", self.num_of_errors, "\nnum_of_warnings-", self.num_of_warnings,"\nnum_of_info-", self.num_of_info, "\nnum_of_log_lines-", self.num_of_log_lines, "\n") + + # Method print statistics of all log files + def print_total_stats(self): + print("total_num_of_errors-", self.total_num_of_errors, "\ntotal_num_of_warnings-", self.total_num_of_warnings,"\ntotal_num_of_info-", self.total_num_of_info, "\ntotal_num_of_log_lines-", self.total_num_of_log_lines, "\n") + +#Store user's given path +log_path=sys.argv[1] + +# creating object of class Statistics +obj=Statistics(log_path) + +# Calling method of class which works on log files +obj.start_logging() \ No newline at end of file diff --git a/Python_Assignment/Exercise_7/client.py b/Python_Assignment/Exercise_7/client.py new file mode 100644 index 0000000..82dc14f --- /dev/null +++ b/Python_Assignment/Exercise_7/client.py @@ -0,0 +1,49 @@ +import socket +import sys + +# creating socket object +socket_obj = socket.socket(socket.AF_INET, socket.SOCK_STREAM) +# Setting host and port +host = socket.gethostname() +port = 200 + +try: + #Setting host and port values given by user in command line argument + host= sys.argv[1] + port=sys.argv[2] +except: + print("no external port or host passed in command line argument") + +# Connecting the host on port +try: + socket_obj.connect((host, int(port))) + print(host,port) + print("Connected to server") + +except socket.gaierror:#gaierror is for, if user enters wrong IP address + print("Wrong IPaddress") +except: + print("Error while connecting") + +while True: + + user_input = input("\nEnter any one command at a time \nCommands are:\tPING LIST HELLO QUIT") + try: + socket_obj.send(user_input.encode('ascii')) + + # Storing message which is sent from server + msg = socket_obj.recv(1024).decode('ascii') + # Printing message which is passed by another file on socket + sys.stdout.write(msg) + user_ask=input("\nDo you want to enter again??\nYES to Continue") + + if user_ask == "yes" or user_ask == "YES": + socket_obj.send(user_ask.encode('ascii')) + else: + break + except: + print("Can't communicate because not connected to server") + break + +# Close the connection +socket_obj.close() \ No newline at end of file diff --git a/Python_Assignment/Exercise_7/server.py b/Python_Assignment/Exercise_7/server.py new file mode 100644 index 0000000..6079973 --- /dev/null +++ b/Python_Assignment/Exercise_7/server.py @@ -0,0 +1,115 @@ +''' + + Create a simple client-server socket based command processing application. + There are two python files, one is server and other is client. + Python server is listening on some port on local machine and waiting for client connection. + Multiple client instances can make connection to the server. + Upon starting server, it should print on what port and IP it is listening on. + Default server port is defined inside server script and it can be overridden by passing command line parameter while starting server. + Client should accept server info as command-line parameters. + Upon connecting to server, client will print connected to server message. + Client then waits for user to input a command string. + This command string is then passed to server for processing and whatever server returns in response should be printed on client std-out. + Implement below command->response messages at server side. + Proper exception handing should be made while establishing client-server connection. + + COMMAND | RESPONSE + +------------------------------- + + PING | PING_OK + + LIST | LIST_OK + + HELLO | WORLD + + QUIT | QUIT_ERR + + | UNKNOWN_CMD + +''' +import socket +import sys +from socket import gethostbyname + +activer=True +def conn_client(client_socket): + + global activer + while activer: + try: + user_input = client_socket.recv(1024).decode('ascii') + except: + print("Old Connection closed") + activer=False + + if user_input == "PING": + msg = "PING_OK" + + elif user_input == "LIST": + msg = "LIST_OK" + + elif user_input == "HELLO": + msg = "WORLD" + + elif user_input == "QUIT": + msg = "QUIT_ERR" + + else: + msg = "UNKNOWN_CMD" + + try: + # Passing message to client_socket + client_socket.send(msg.encode('ascii')) + except: +# print("Error while sending to old Client") + activer=False + try: + user_choice = client_socket.recv(1024).decode('ascii') + except : +# print("Error while receiving to old Client") + activer=False + if user_choice == "yes" or user_choice == "YES": + print("It means you want to enter again") + # Checking commands with user entered command + else: + # Closing client-socket + client_socket.close() + + + +# creating socket object +socket_obj = socket.socket(socket.AF_INET, socket.SOCK_STREAM) + +# getting host name and setting port +host = socket.gethostname() +port = 200 + +try: + #Taking input from command line argument and assigning it to host and port + host = sys.argv[1] + port = sys.argv[2] +except: + print("no external port or host passed in command line argument") + +# binding host to the port +try: + print(host) + socket_obj.bind((host, int(port))) + print("server IP is:",gethostbyname(host),"Port is:",port) +except socket.gaierror: + print("Wrong IPaddress") +except: + print("Error while connecting") + +while True: + socket_obj.listen(3) + # Establishing connection + client_socket, adr = socket_obj.accept() + try: + obj = conn_client(client_socket) + activer=True + except: + print("Not connecting ....") + activer=False +socket_obj.close() diff --git a/Python_Assignment/Exercise_9/assignment9.xml b/Python_Assignment/Exercise_9/assignment9.xml new file mode 100644 index 0000000..20cab98 --- /dev/null +++ b/Python_Assignment/Exercise_9/assignment9.xml @@ -0,0 +1,10 @@ + + + + + http://maps.googleapis.com/maps/api/geocode/json?latlng=35.3573875,69.9718617,3z + + email_recipient@domain.com + + + \ No newline at end of file diff --git a/Python_Assignment/Exercise_9/nine.py b/Python_Assignment/Exercise_9/nine.py new file mode 100644 index 0000000..fc5555a --- /dev/null +++ b/Python_Assignment/Exercise_9/nine.py @@ -0,0 +1,111 @@ +''' +Below XML configuration file (config.xml) exists in current directory as the program. +Write a program which reads API_URL and EMAIL_ID from below xml file. +Take values of LATITUDE and LONGITUDE as a user input and replace them in API_URL. +This URL works as HTTP get request. +When proper values of latitude and longitude is provided it returns the json with information of that particular location. +Call this HTTP get request with the latitude and longitude values taken as an input from user. +If request is successful then send an email to address configured + in EMAIL_ID with " | | " information in the body and + subject as "Message from python script". + +xml file's code as follow + + + + + http://maps.googleapis.com/maps/api/geocode/json?latlng=LATITUDE,LONGITUDE + + email_recipient@domain.com + + +''' +import xml.etree.ElementTree as ET +import urllib3 +import smtplib +from smtplib import SMTPException +from geopy.geocoders import Nominatim +import json +#Fetching xml file +mytree=ET.parse('assignment9.xml') + +#Getting latitude and longitude from user +user_latitude=input("Enter latitude value") +user_longitude=input("Enter longitude value") + +#setting root_element to first tag of xml file +root_element=mytree.getroot() + +#for loop to iterate in all tags to find the map API URL +for x in root_element.iter("API_URL"): + #Set latitude and longitude values in URL + b=f"http://maps.googleapis.com/maps/api/geocode/json?latlng={user_latitude},{user_longitude}" + x.text=b + print(b) + +#Writing new URL to XML file +mytree.write('assignment9.xml') + +geolocator = Nominatim(user_agent="my-application") +location = geolocator.reverse(f"{user_latitude}, {user_longitude}") + +data=[] +#assigning value to city state and country + +city="City- "+location.raw["address"]["state_district"] +state="State- "+location.raw["address"]["state"] +country="Country- "+location.raw["address"]["country"] +data.append(city) +data.append(state) +data.append(country) + +with open('location.txt','w') as json_file: + json.dump(data,json_file) +# print(location.raw) +with open('location.txt') as json_read: + data=json.load(json_read) + for i in data: + print(i) + +#Calling the URL +http = urllib3.PoolManager() +respone_code = http.request('GET', b) + +#check if the area (i.e. given latitude and longitude) found or not +if(respone_code.status==200): + #If response code is 200 it means that found + for x in root_element.iter("EMAIL_ID"): + user_mail_id=x.text + user_mail_id=input("Enter your Email id") + x.text=user_mail_id + mytree.write('assignment9.xml') + #Sender's mail + from_user="ENTER YOUR MAIL ID" + + message = f"""Subject: Message from python script + + {city} + {state} + {country} + """ + #print is for if you want to see the message + #print(message) + + #setting host(Gmail) and its port value(587 for Gmail) + gmail_server = smtplib.SMTP('smtp.gmail.com',587) + try: + #gmail can't allow to send mail without encrypting so starttls method is written + gmail_server.starttls() + #Login to my gmail account to send mail + gmail_server.login("ENTER YOUR MAIL ID", "ENTER YOUR MAIL PASSWORD") + #send mail method sends mail and it has three arguments 1. sender 2. receiver 3. message + gmail_server.sendmail(from_user,user_mail_id,message) + #Just for acknowledgement for user + print("Sent Successfully") + #While sending if any error occur then it prints below statement rather than exiting + except SMTPException: + print("Not sent") + +#if response code is anything except 200 +else: + print(respone_code.status) \ No newline at end of file diff --git a/Python_Assignment/Shail's_Exercise/main.py b/Python_Assignment/Shail's_Exercise/main.py new file mode 100644 index 0000000..105dfcd --- /dev/null +++ b/Python_Assignment/Shail's_Exercise/main.py @@ -0,0 +1,137 @@ +""" +User enter the details of table to perform CRUD operations. +The main.py get only user input and calling the methods of another class Methods are for, +creating table, insert into table, Update table, Delete row, Delete/Drop Table, Print all data of a table. +Firstly when file run it should ask user to which database file he/she want to perform all operations, if that database dosen't exists then the con structor should make new database file. +Another file cosists only Methods. + +""" + +from pip._vendor.msgpack.fallback import xrange +from operations import sql_operations +import sqlite3 + +# Object of another file to call that functions +sql_obj = sql_operations() + +# Ask user if he/she wants to perform any operation +while True: + + # Variable to store user's choice + user_ask = 0 + try: + user_ask = int(input("1: Create table \n2: Insert into already exists table and exit \n3: Update table \n4: Delete row \n5: Delete whole table \n6: Print table data \n7: Close database")) + except: + print("Enter integer values only") + + # If user want to create table + if user_ask == 1: + tb_args = [] + tb_type = [] + # getting table details + new_tb_name = input("Enter table name:") + while True: + try: + tb_no_args = int(input("how many columns you want to enter")) + break + except: + print("Enter integer values only") + for i in xrange(tb_no_args): + tb_args.append(input("Enter columns and it's type separated with single white space")) + + # Calling function of another file to create table + sql_obj.create_tb(new_tb_name, tb_args) + # Clearing details if user need to create many tables at a time + tb_no_args = "" + tb_args = [] + + # If user want to insert into table + if user_ask == 2: + data_insrt = [] + # Ask user that how many data he/she want to enter + while True: + try: + no_data_insrt = 1 + tb_name = input("Enter table name:") + # Printing table data for user + sql_obj.sql_printit(tb_name) + no_data_insrt = int(input("How many row you want to insert?")) + + break + except sqlite3.OperationalError: + print("Enter valid table name") + + except ValueError: + print("Enter integer values only") + + # Getting columns name of given table + tb_args = sql_obj.get_column() + + # user inserts values of table + for i in xrange(no_data_insrt): + for j in tb_args: + print(f"Enter data of {j}") + data_insrt.append(input()) + + # Calling function of another file to insert values + sql_obj.insert_values(tb_name, data_insrt) + data_insrt = [] + + # If user want to update table + if user_ask == 3: + while True: + try: + # Getting all information from user required to update table + tb_name = input("Insert into (write table name)") + tb_column = input("SET (enter col_name)") + new_data = input("= (new value) ") + tb_column1 = input("WHERE (col_name)") + old_data = input("=(that col_data)") + # Calling function of another table to update table + sql_obj.sql_update(tb_name, tb_column, tb_column1, old_data, new_data) + break + except: + print("Update failed") + + # If user want to delete row + if user_ask == 4: + while True: + try: + # Getting info required to delete a particular row + tb_name = input("In which table you want to delete row") + tb_column = input("From which column you want to delete") + old_data = input("Write data which you want to delete") + sql_operator = input("Enter one operator like (==,>,<,>=,<=)") + sql_obj.sql_del_row(tb_name, tb_column, sql_operator, old_data) + break + except: + print("Delete operation failed") + + # If user want to drop table + if user_ask == 5: + while True: + try: + # Asks user to write table name which he/she want to delete + tb_name = input("Which table you want to delete") + # Calling function of another file to drop table + sql_obj.delte_tb(tb_name) + print("Table dropped or deleted") + break + except: + print("Drop operation failed") + + # If user want to print table data + if user_ask == 6: + while True: + try: + tb_name = input("Enter table name:") + # Calling function of another file to print all data of a table + sql_obj.sql_printit(tb_name) + break + except: + print("Enter table name again") + + # close open database + if user_ask == 7: + # calling function to close connection + sql_obj.db_close() \ No newline at end of file diff --git a/Python_Assignment/Shail's_Exercise/operations.py b/Python_Assignment/Shail's_Exercise/operations.py new file mode 100644 index 0000000..b899b73 --- /dev/null +++ b/Python_Assignment/Shail's_Exercise/operations.py @@ -0,0 +1,89 @@ +import sqlite3 + +class sql_operations: + + # Constructor for connection to database + def __init__(self): + db1 = input("Enter database file name") + self.db = sqlite3.connect(db1) + self.cur = self.db.cursor() + + # Function to add new table in database + def create_tb(self, tb_name, tb_args): + + sql = f'CREATE TABLE {tb_name} (' + ','.join(tb_args) + ')' + print(sql) + + try: + self.cur.execute(sql) + print("created") + tb_args = [] + tb_name = "" + except: + print("not created") + self.db.commit() + + def get_column(self): + + column_names = [i[0] for i in self.cur.description] + return column_names + + # Function to add data in table + def insert_values(self, tb_name, data_insrt): + + res = str(data_insrt) [1:-1] + f = f"INSERT INTO {tb_name} VALUES ({res})" + print(f) + try: + self.cur.execute(f) + except: + print("not inserted") +# self.db.commit() + + # Function for updating database + def sql_update(self, tb_name, tb_column, tb1_column, old_data, new_data): + + sql_qry = f"UPDATE {tb_name} SET {tb_column} = '{new_data}'\ + WHERE {tb1_column}='{old_data}' " + print(sql_qry) + + self.cur.execute(sql_qry) + self.db.commit() + + # Function to delete column from table + def sql_del_row(self, tb_name, tb_column, sql_operator, old_data): + + sql = f"DELETE FROM {tb_name} WHERE {tb_column} {sql_operator} '{old_data}'" + print(sql) + self.cur.execute(sql) + self.db.commit() + + # Function to remove table from database + def delte_tb(self, tb_name): + + sql = f"DROP TABLE {tb_name}" + print(sql) + self.cur.execute(sql) + self.db.commit() + + # Function to print table data database + def sql_printit(self, tb_name): + + sql = f"SELECT * FROM {tb_name}" + self.cur.execute(sql) + data = self.cur.fetchall() + column_names = [i[0] for i in self.cur.description] + + # Printing column names + print("TABLE:\n", column_names) + # Printing table rows + for i in data: + print(f"{i}\t") + + self.db.commit() + + # Function for closing connection of database + def db_close(self): + + self.db.close() + print("Database connection closed") diff --git a/Python_Assignment/eight.py b/Python_Assignment/eight.py new file mode 100644 index 0000000..6dd9c9b --- /dev/null +++ b/Python_Assignment/eight.py @@ -0,0 +1,62 @@ +''' +Create a thread class of which run method print numbers in sequence with a delay of n seconds. +Number starts with 0. It prints number prefixed with thread name. +Now create three thread instances one with 1 second delay, other with 1.5 seconds delay and third with 2 seconds delay. +Start each thread in the main program. +Upon running python file it should start all these threads and also it should expect a integer from user as input. +If user inputs 0 it should terminate all these three threads and terminate the program. +For any other input it does nothing. + +''' +import threading +import time + +#active variable to handle while loop +active=True + +#Thread class having method run +class threads(threading.Thread): + + def __init__(self,thread_name,delay): + + threading.Thread.__init__(self) + self.name=thread_name + self.delay=delay + + def run(self): + + count=0 + while active: + time.sleep(self.delay) + #Print thread name and counter value + print(self.name,"\t",count,"\n") + count+=1 + +#Function that gets user input +def wait_on_user(): + + global active + while True: + #try used because user can enter non integer value + try: + #Getting user input + user_interrupt = int(input()) + #If user enters zero then program will terminate + if user_interrupt==0: + #set active to false to stop the while loop + active=False + break + except: + print("") + +Thread1=threads("Thread-1",1) +Thread2=threads("Thread-2",1.5) +Thread3=threads("Thread-3",2) +#It calls the wait_on_user method +Thread4 =threading.Thread(target=wait_on_user) + +#Starting all threads one by one +Thread1.start() +Thread2.start() +Thread3.start() +Thread4.start() \ No newline at end of file diff --git a/Python_Assignment/four.py b/Python_Assignment/four.py new file mode 100644 index 0000000..97a8642 --- /dev/null +++ b/Python_Assignment/four.py @@ -0,0 +1,28 @@ +""" + Assignment 4: +Write a function which accepts an int count of a number of items. Function returns a string such that: +'Number of items: ', where is the number passed in. +However, if the count is 10 or more, then use the word 'many' instead of the actual count. +i.e. function(4) returns 'Number of items: 4' +and function(21) returns 'Number of items: many' +""" +#Function for count it returns many or the number itself +def count_int(user_input): + + if(user_input>=10): + return "many" + else: + return user_input +#getting user input +while True: + try: + user_input=int(input("Enter number of items")) + break + except ValueError: + print("Enter integers only") + +#calling the method count_int and passing the user entered value to that function +message=count_int(user_input) + +#printing the function's returned value +print("Number of items : ",message) \ No newline at end of file diff --git a/Python_Assignment/one.py b/Python_Assignment/one.py new file mode 100644 index 0000000..0e2a121 --- /dev/null +++ b/Python_Assignment/one.py @@ -0,0 +1,10 @@ +""" + Assignment 1: +Write a simple python program which will take one string input parameter as command line argument. +Verify if the last character of the string is Capital Letter. For e.g. If we pass “AbcD” as command line argument, +then output should be true and for “Abcd” output would be false. + +""" +print("Enter string") +user_input=input() +print(user_input[-1].isupper()) #print true if last character is in uppercase else print false diff --git a/Python_Assignment/three.py b/Python_Assignment/three.py new file mode 100644 index 0000000..6f15621 --- /dev/null +++ b/Python_Assignment/three.py @@ -0,0 +1,49 @@ +""" + Assignment 3: +Create a function which lists all the files in current directory. +Create another function to verify whether current python program file (.py) is listed in the above returned list of files. +Modify first function to accept two arguments, first – path to list the files from, +second – filter to limit the specific extension files +(i.e. function(“c:\test”, “*.txt”) should list all *.txt files from c:\test directory.) +""" + +import os + +# function for displaying particular path and containing files +def dirlist(path,filter): + dir_list = [] + is_file_found = 0 + + for file in os.listdir(path): + if file.endswith(filter): + is_file_found = 1 + # Prints the file name which are ending with given in filter + print(os.path.join(path, file)) + + # If file not found then + if is_file_found != 1: + print("No file found in this directory") + + dir_list.append(os.listdir(path)) + os.chdir(path) + return dir_list + +# This function checks if the currently working file is in file list or not +def checkfile(current_file, directory_list): + + # for loop is for list to find if the current working file is in this directory list or not + for i in range(len(directory_list)): + + if current_file in directory_list[i]: + print("\nCurrent working file is in list (", current_file, ")") + else: + print("\nCurrent working file doesn't exists in this list") + + + +path = input("\nEnter file path") +filter = input("\nEnter file extension") # getting extension from user +directory_list = dirlist(path, filter) # calling dirlist function and search for that ending extemsion file +# print(type(directory_list)) #uncomment for checking the type of directory_list +current_file = os.path.basename(__file__) # getting current working file name +checkfile(current_file, directory_list) \ No newline at end of file diff --git a/Python_Assignment/two.py b/Python_Assignment/two.py new file mode 100644 index 0000000..1c2821d --- /dev/null +++ b/Python_Assignment/two.py @@ -0,0 +1,85 @@ +""" + Exercise: 2 + Consider the following lists: + +Index_list = [1,2,3,4,5,6,7,8,9,10,11,12] + +Name_list = [‘Jan’, ‘Feb’, ‘Mar’, ‘Apr’, ‘May’, ‘Jun’, ‘Jul’, ‘Aug’, ‘Sep’, ‘Oct’, ‘Nov’, ‘Dec’] + +a. Create a dictionary with the above lists such that index_list is key and name_list is value. + +For e.g. {1:’Jan’, 2:’Feb’} and so on …. + +Now take an input number from user, validate it is between 1 and 12. +Using above dictionary print the corresponding month name for the user input number. + +b. Create a list of tuples with the above lists as shown below: + +[(1,’Jan’), (2,’Feb’), (3,’Mar’)] and so on… + +Now iterate through each tuple from above list and store them to a CSV file (month_names.csv) like below: + +id, month_num, month_name + +0, 1, Jan + +1, 2, Feb + +… + +11, 12, Dec +""" + + + +# A's Implementation + +import csv +Index_list = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12] +name_list = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"] +monthdict = {} + +#for loop to store index list as key and month list as value +for i in range(0, len(Index_list)): + monthdict[Index_list[i]] = name_list[i] +print(monthdict) + +#Getting user input +while True: + try: + getname = int(input("Enter a number between 1 to 12 to view month name")) + break; + except Exception: + print("Enter integers only and also don't include white spaces\n") + +#condition checks and print appropriate value if given number not found and print not found +if monthdict.get(getname) != None: + print(monthdict[getname],"\n") +else: + print("not found\n") + + +# B's Implementation + +monthlist = list(monthdict.items()) +print(monthlist) +monthlist_for_csv = [(index1, k, v) for index1, (k, v) in enumerate(monthlist)] +#storing list in csv file +with open ("months.csv", "w", newline="") as csfile: + + write = csv.writer(csfile) + write.writerow(['INDEX', 'MONTH NUMBER', 'MONTH NAME']) + write.writerows(monthlist_for_csv) + +#printing the csv file to view output +with open ("months.csv", "r") as csfile1: + + read = csv.reader(csfile1) + write_count = 0 + for rows in read: + if write_count == 0: + print('\n\t\t\t COLOUMN NAME\n') + print(f' \t\t{" ".join(rows)}') + write_count += 1 + else: + print(f'\t\t {rows[0]}\t\t{rows[1]}\t {rows[2]}') \ No newline at end of file