centreon-plugins icon indicating copy to clipboard operation
centreon-plugins copied to clipboard

Update 3CX plugin for last v18 updates

Open UrBnW opened this issue 2 years ago • 5 comments

Hi,

Description

This patch fixes 3CX plugin, which was broken since v18 update 5. 3CX current version is now v18 update 9.

It then fixes #4083. It also fixes #4608.

Thx 👍

Type of change

  • [x] Patch fixing an issue (non-breaking change)
  • [ ] New functionality (non-breaking change)
  • [ ] Breaking change (patch or feature) that might cause side effects breaking part of the Software

Target serie

  • [ ] 22.04.x
  • [ ] 22.10.x
  • [ ] 23.04.x
  • [x] 23.10.x
  • [x] 24.04.x (master)

How this pull request can be tested ?

You need a 3CX server to do so. I tested the plugin against many (more than 10) 3CX servers.

Checklist

Community contributors & Centreon team

  • [x] I have followed the coding style guidelines provided by Centreon
  • [x] I have commented my code, especially new classes, functions or any legacy code modified. (docblock)
  • [x] I have commented my code, especially hard-to-understand areas of the PR.
  • [x] I have rebased my development branch on the base branch (master, maintenance).

UrBnW avatar Dec 01 '23 10:12 UrBnW

@sdepassio Is it possible to accept this PR? I also tested its operation in its environment, and everything works perfectly. Thanks

Bettiol avatar Feb 04 '24 21:02 Bettiol

Hi @UrBnW, With delay, thanks a lot for your contribution :100: If I understand correctly, this code change will make the plugin work with 3CX in versions >= 18. But this solution seems to be available on-premise, so I fear this change may break the monitoring of older versions. Am I wrong? I'm asking this to determine whether this PR must be merged in the current plugin or it must be added as a variant (with a new monitoring connector/pack) to enable the monitoring of both recent and old 3CX systems. What do you think?

Regards,

omercier avatar Feb 05 '24 08:02 omercier

Hi @omercier, thank you for your feedback 👍 You're right, this plugin gets rid of 3CX v16 support. But IMO it does not matter, as it is totally outdated, no more supported, since months (years ?) now. Everybody (should) now run 3CX v18, and 3CX v20 will be released in a couple of days. Thank you again !

UrBnW avatar Feb 05 '24 08:02 UrBnW

(@omercier some time has passed since my last commit here, has @garnier-quentin left this repo ? :)

UrBnW avatar Feb 05 '24 08:02 UrBnW

This repo, maybe not once and for all, but he has left the company.

omercier avatar Feb 06 '24 22:02 omercier

Hi @UrBnW, I have created a PR #5093 to handle both versions prior and after 3CX 18.0.5 (and probably future versions). Can you test the code in branch https://github.com/centreon/centreon-plugins/tree/CTOR-360-Community-PR-New-supported-versions-3CX-v18 ? Thanks a lot for your contribution!

omercier avatar Jul 04 '24 14:07 omercier

@grosbedos can you try it as well and confirm if it fixes your issue?

omercier avatar Jul 04 '24 15:07 omercier

Hi, i have tested the branch https://github.com/centreon/centreon-plugins/tree/CTOR-360-Community-PR-New-supported-versions-3CX-v18 and it's working as expected !

Thanks for your work.

grosbedos avatar Jul 24 '24 14:07 grosbedos

Thanks for your feedback @grosbedos :100:

omercier avatar Jul 26 '24 06:07 omercier

Hi @omercier, Sorry for my late reply... I then just gave #5093 a try, it works perfectly fine 👌 Thank you very much for your rework 👍

UrBnW avatar Jul 26 '24 17:07 UrBnW

No problem @UrBnW and thanks for the feedback. 👍🏻 In order to be able to list the tested versions in our documentation, can you tell me chat version of 3CX you tested the plugin with?

@grosbedos I assume you're still using version 18.0.9.20

omercier avatar Aug 02 '24 15:08 omercier

Tested here with 18.0.9.20. To be fair, I'm pretty sure 16.x is not used anymore :)

UrBnW avatar Aug 02 '24 20:08 UrBnW

Yes, probably, but just in case... And we may have to do some other changes with the future versions, so this option will still be useful.

omercier avatar Aug 05 '24 09:08 omercier

Sure, the version option will be really useful for future versions (best example is current v20, I'll be back later on regarding this).

UrBnW avatar Aug 05 '24 09:08 UrBnW