Cache Cache component is used to reduce page load time by caching the content in a global cache after the initial rendering. Various cache providers are supported like ehcache and hazelcast. In this example, toolbar component is cached and output would be retrieved from cache.
    <p:cache region="testcache" key="toolbar">
            <p:toolbarGroup align="left">
                <p:commandButton type="button" value="New" icon="ui-icon-document" />

                <p:commandButton type="button" value="Open" icon="ui-icon-folder-open"/>

                <p:separator />

                <p:commandButton type="button" title="Save" icon="ui-icon-disk"/>
                <p:commandButton type="button" title="Delete" icon="ui-icon-trash"/>
                <p:commandButton type="button" title="Print" icon="ui-icon-print"/>

            <p:toolbarGroup align="right">
                <p:commandButton type="button" value="Quit" icon="ui-icon-close"/>
PrimeTek, Copyright © 2017
All rights reserved.
Running PrimeFaces-6.2 on Mojarra-2.3.2.