def METHOD_NAME(*args, **kwargs):
    # Get the redis connection
    connection = current_app.redis_connection
    requeue = kwargs.pop("requeue", False)
    # checking if force is an input argument of `func`
    force_new_job_creation = kwargs.pop("force_new_job_creation", False)
    # creating a hash from args and kwargs
    args_hash = (
        f"{queue}:{func.__name__}:{hash_function_arguments(args, kwargs)}"
    )
    # check the redis connection for whether the key hash exists
    if connection.exists(args_hash) and not force_new_job_creation:
        current_app.logger.info(
            f"The function {func.__name__} has been called already with the same arguments. Skipping..."
        )
        # get job id
        job_id = connection.get(args_hash).decode()
        # check if the job exists and, if it doesn't, skip fetching and generate new job
        if Job.exists(job_id, connection=connection):
            job = Job.fetch(
                job_id, connection=connection
            )  # get job object from job id
            # requeue if failed and requeue flag is true
            if job.is_failed and requeue:
                job.requeue()
            return job  # returning the same job regardless of the status (SUCCESS, FAILED, ...)
    # if the job description is new -> create job
    job = func(*args, **kwargs)  # create a new job
    # store function call in redis by mapping the hash of the function arguments to its job id
    connection.set(
        args_hash, job.id, ex=current_app.config["FLEXMEASURES_JOB_CACHE_TTL"]
    )
    return job