mirror of
				https://github.com/asterisk/asterisk.git
				synced 2025-10-31 02:37:10 +00:00 
			
		
		
		
	res_pjsip: chatty verbose messages
There are a lot of verbose messages about Endpoint and Contact status changes if there are many dynamic endpoints. The patch sets verbose level 2 for Endpoint status changes and verbose level 3 for Contact status changes. ASTERISK-26055 #close Change-Id: Ie64e261ddbbc41bfff0f0190241152cc123fe6d7
This commit is contained in:
		| @@ -131,7 +131,7 @@ static int persistent_endpoint_update_state(void *obj, void *arg, int flags) | ||||
| 			} | ||||
| 		} | ||||
|  | ||||
| 		ast_verb(1, "Endpoint %s is now Reachable\n", ast_endpoint_get_resource(endpoint)); | ||||
| 		ast_verb(2, "Endpoint %s is now Reachable\n", ast_endpoint_get_resource(endpoint)); | ||||
| 	} else { | ||||
| 		ast_endpoint_set_state(endpoint, AST_ENDPOINT_OFFLINE); | ||||
| 		blob = ast_json_pack("{s: s}", "peer_status", "Unreachable"); | ||||
| @@ -144,7 +144,7 @@ static int persistent_endpoint_update_state(void *obj, void *arg, int flags) | ||||
| 			} | ||||
| 		} | ||||
|  | ||||
| 		ast_verb(1, "Endpoint %s is now Unreachable\n", ast_endpoint_get_resource(endpoint)); | ||||
| 		ast_verb(2, "Endpoint %s is now Unreachable\n", ast_endpoint_get_resource(endpoint)); | ||||
| 	} | ||||
|  | ||||
| 	ast_free(regcontext); | ||||
| @@ -173,7 +173,7 @@ static void persistent_endpoint_contact_created_observer(const void *object) | ||||
|  | ||||
| 	contact_status->status = CREATED; | ||||
|  | ||||
| 	ast_verb(1, "Contact %s/%s has been created\n",contact->aor, contact->uri); | ||||
| 	ast_verb(2, "Contact %s/%s has been created\n",contact->aor, contact->uri); | ||||
|  | ||||
| 	ao2_callback(persistent_endpoints, OBJ_NODATA, persistent_endpoint_update_state, contact_status); | ||||
| 	ao2_cleanup(contact_status); | ||||
| @@ -192,7 +192,7 @@ static void persistent_endpoint_contact_deleted_observer(const void *object) | ||||
| 		return; | ||||
| 	} | ||||
|  | ||||
| 	ast_verb(1, "Contact %s/%s has been deleted\n", contact->aor, contact->uri); | ||||
| 	ast_verb(2, "Contact %s/%s has been deleted\n", contact->aor, contact->uri); | ||||
| 	ast_statsd_log_string_va("PJSIP.contacts.states.%s", AST_STATSD_GAUGE, | ||||
| 		"-1", 1.0, ast_sip_get_contact_status_label(contact_status->status)); | ||||
| 	ast_statsd_log_string_va("PJSIP.contacts.states.%s", AST_STATSD_GAUGE, | ||||
| @@ -220,7 +220,7 @@ static void persistent_endpoint_contact_status_observer(const void *object) | ||||
| 	} | ||||
|  | ||||
| 	if (contact_status->status != contact_status->last_status) { | ||||
| 		ast_verb(1, "Contact %s/%s is now %s.  RTT: %.3f msec\n", contact_status->aor, contact_status->uri, | ||||
| 		ast_verb(3, "Contact %s/%s is now %s.  RTT: %.3f msec\n", contact_status->aor, contact_status->uri, | ||||
| 			ast_sip_get_contact_status_label(contact_status->status), | ||||
| 			contact_status->rtt / 1000.0); | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user