You are right this is how it works. prune will remove everything except what is in whitelist_names array and the way to maintain tags (if any) is to e.g.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.