public static void generateDocumentation(List<NamespaceMetaData> namespaceMetaDataList,
                                             String documentationBaseDirectory, String documentationVersion,
                                             Log logger, String siddhiVersion, String mavenProjectGroupId)
            throws MojoFailureException {
        // Generating data model
        Map<String, Object> rootDataModel = new HashMap<>();
        rootDataModel.put("metaData", namespaceMetaDataList);
        rootDataModel.put("formatDescription", new FormatDescriptionMethod());
        rootDataModel.put("latestDocumentationVersion", documentationVersion);
        rootDataModel.put("siddhiVersion", siddhiVersion);
        rootDataModel.put("siddhiDocVersion", findSiddhiDocVersion(siddhiVersion, documentationVersion));
        rootDataModel.put("repositoryOwner", findRepositoryOwner(mavenProjectGroupId));

        String outputFileRelativePath = Constants.API_SUB_DIRECTORY + File.separator + documentationVersion
                + Constants.MARKDOWN_FILE_EXTENSION;

        generateFileFromTemplate(
                Constants.MARKDOWN_DOCUMENTATION_TEMPLATE + Constants.MARKDOWN_FILE_EXTENSION
                        + Constants.FREEMARKER_TEMPLATE_FILE_EXTENSION,
                rootDataModel, documentationBaseDirectory, outputFileRelativePath
        );
    }
Generate documentation related files using metadata

@param namespaceMetaDataList      Metadata in this repository
@param documentationBaseDirectory The path of the directory in which the documentation will be generated
@param documentationVersion       The version of the documentation being generated
@param logger                     The logger to log errors
@param siddhiVersion              Siddhi Core version
@param mavenProjectGroupId        Project Group ID
@throws MojoFailureException if the Mojo fails to find template file or create new documentation file
modules/siddhi-doc-gen/src/main/java/io/siddhi/doc/gen/core/utils/DocumentationUtils.java