mirror of
				https://github.com/open5gs/open5gs.git
				synced 2025-11-03 21:43:25 +00:00 
			
		
		
		
	[SBI] SearchResult.validityPeriod 3600->30s (#3210)
The validity time for NF Instances obtained through NF Discovery was not properly implemented. Since the validity was 3600 seconds(1 hour), which caused 5G Core to not work properly after 3600 seconds(1 hour). There was an issue where an NF Instance should be deleted when its validity time expired, but it was not working correctly due to incorrect use of reference count. Therefore, I have modified the Validity of NF Instances obtained through NF Discovery to work properly. I also changed the default value of valdityPeriod to 30 seconds.
This commit is contained in:
		@@ -57,6 +57,19 @@ extern "C" {
 | 
			
		||||
        OGS_OBJECT_REF(__pClient); \
 | 
			
		||||
        ((__cTX)->client) = (__pClient); \
 | 
			
		||||
        ogs_debug("CLIENT Ref [%d]", (__pClient)->reference_count); \
 | 
			
		||||
        if ((__pClient)->fqdn) { \
 | 
			
		||||
            ogs_info("NF EndPoint(fqdn) setup [%s:%d]", \
 | 
			
		||||
                    (__pClient)->fqdn, (__pClient)->fqdn_port); \
 | 
			
		||||
        } \
 | 
			
		||||
        if ((__pClient)->addr) { \
 | 
			
		||||
            ogs_info("NF EndPoint(addr) setup [%s:%d]", \
 | 
			
		||||
                OGS_ADDR((__pClient)->addr, buf), OGS_PORT((__pClient)->addr)); \
 | 
			
		||||
        } \
 | 
			
		||||
        if ((__pClient)->addr6) { \
 | 
			
		||||
            ogs_info("NF EndPoint(addr6) setup [%s:%d]", \
 | 
			
		||||
                OGS_ADDR((__pClient)->addr6, buf), \
 | 
			
		||||
                OGS_PORT((__pClient)->addr6)); \
 | 
			
		||||
        } \
 | 
			
		||||
    } while(0)
 | 
			
		||||
 | 
			
		||||
typedef int (*ogs_sbi_client_cb_f)(
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user