Skip to content

Question regarding idempotency in Check Point data center query modules #198

@serValentin

Description

@serValentin

Hi,

I would like to raise a question regarding the design of the following modules:

  • cp_mgmt_add_data_center_query
  • cp_mgmt_data_center_query_facts
  • cp_mgmt_set_data_center_query
  • cp_mgmt_delete_data_center_query

From my understanding, these modules do not fully align with Ansible’s philosophy of idempotency.

In Ansible, modules are generally expected to be idempotent—meaning that running the same task multiple times should not result in changes if the desired state is already achieved. However, the behavior of these modules appears to require explicit action-based operations (add/set/delete), rather than ensuring a desired state declaratively.

This raises a few questions:

Is there a specific reason these modules were not designed to be idempotent?
Are there technical limitations in the Check Point API that prevent this?
Would it be possible to introduce a more state-driven approach (e.g., state: present/absent) to better align with Ansible standards?

I believe aligning these modules with Ansible’s idempotent design principles would improve usability, consistency, and reliability in automation workflows.

Looking forward to your insights.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions