diff mbox series

[ovs-dev,1/2] ovn-northd: Add IDL memory usage information.

Message ID 167113950683.704727.12111724306408038262.stgit@dceara.remote.csb
State Accepted
Headers show
Series Add automatic memory trimming to northd. | expand

Checks

Context Check Description
ovsrobot/apply-robot success apply and check: success
ovsrobot/github-robot-_ovn-kubernetes success github build: passed
ovsrobot/github-robot-_Build_and_Test fail github build: failed

Commit Message

Dumitru Ceara Dec. 15, 2022, 9:25 p.m. UTC
Signed-off-by: Dumitru Ceara <dceara@redhat.com>
---
 northd/ovn-northd.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Ales Musil Jan. 13, 2023, 10:29 a.m. UTC | #1
On Thu, Dec 15, 2022 at 10:29 PM Dumitru Ceara <dceara@redhat.com> wrote:

> Signed-off-by: Dumitru Ceara <dceara@redhat.com>
> ---
>  northd/ovn-northd.c |    3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/northd/ovn-northd.c b/northd/ovn-northd.c
> index 82d2874d66..3a575b02a5 100644
> --- a/northd/ovn-northd.c
> +++ b/northd/ovn-northd.c
> @@ -849,7 +849,8 @@ main(int argc, char *argv[])
>          if (memory_should_report()) {
>              struct simap usage = SIMAP_INITIALIZER(&usage);
>
> -            /* Nothing special to report yet. */
> +            ovsdb_idl_get_memory_usage(ovnnb_idl_loop.idl, &usage);
> +            ovsdb_idl_get_memory_usage(ovnsb_idl_loop.idl, &usage);
>              memory_report(&usage);
>              simap_destroy(&usage);
>          }
>
> _______________________________________________
> dev mailing list
> dev@openvswitch.org
> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
>
>
Looks good to me, thanks.

Acked-by: Ales Musil <amusil@redhat.com>
Dumitru Ceara Jan. 17, 2023, 4:10 p.m. UTC | #2
On 1/13/23 11:29, Ales Musil wrote:
> On Thu, Dec 15, 2022 at 10:29 PM Dumitru Ceara <dceara@redhat.com> wrote:
> 
>> Signed-off-by: Dumitru Ceara <dceara@redhat.com>
>> ---
>>  northd/ovn-northd.c |    3 ++-
>>  1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/northd/ovn-northd.c b/northd/ovn-northd.c
>> index 82d2874d66..3a575b02a5 100644
>> --- a/northd/ovn-northd.c
>> +++ b/northd/ovn-northd.c
>> @@ -849,7 +849,8 @@ main(int argc, char *argv[])
>>          if (memory_should_report()) {
>>              struct simap usage = SIMAP_INITIALIZER(&usage);
>>
>> -            /* Nothing special to report yet. */
>> +            ovsdb_idl_get_memory_usage(ovnnb_idl_loop.idl, &usage);
>> +            ovsdb_idl_get_memory_usage(ovnsb_idl_loop.idl, &usage);
>>              memory_report(&usage);
>>              simap_destroy(&usage);
>>          }
>>
>> _______________________________________________
>> dev mailing list
>> dev@openvswitch.org
>> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
>>
>>
> Looks good to me, thanks.
> 
> Acked-by: Ales Musil <amusil@redhat.com>
> 

Thanks, I applied this to the main branch!
diff mbox series

Patch

diff --git a/northd/ovn-northd.c b/northd/ovn-northd.c
index 82d2874d66..3a575b02a5 100644
--- a/northd/ovn-northd.c
+++ b/northd/ovn-northd.c
@@ -849,7 +849,8 @@  main(int argc, char *argv[])
         if (memory_should_report()) {
             struct simap usage = SIMAP_INITIALIZER(&usage);
 
-            /* Nothing special to report yet. */
+            ovsdb_idl_get_memory_usage(ovnnb_idl_loop.idl, &usage);
+            ovsdb_idl_get_memory_usage(ovnsb_idl_loop.idl, &usage);
             memory_report(&usage);
             simap_destroy(&usage);
         }