Examples of toNiceString()


Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

        for (TileLayer tileLayer : tileLayerDispatcher.getLayerList()) {
            String layerName = tileLayer.getName();
            Quota usedQuota = quotaStore.getUsedQuotaByLayerName(layerName);
            if (usedQuota.getBytes().compareTo(BigInteger.ZERO) > 0) {
                log.debug("Using saved quota information for layer " + layerName + ": "
                        + usedQuota.toNiceString());
            } else {
                log.debug(layerName + " has no saved used quota information,"
                        + "traversing layer cache to compute its disk usage.");
                cacheInfoBuilder.buildCacheInfo(tileLayer);
            }
View Full Code Here

Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

                limit = quotaResolver.getLimit();
                Quota usedQuota = quotaResolver.getUsed();
                if (excess.getBytes().compareTo(BigInteger.ZERO) > 0) {
                    log.warn("No more pages to expire, check if youd disk quota"
                            + " database is out of date with your blob store. Quota: "
                            + limit.toNiceString() + " used: " + usedQuota.toNiceString());
                }
                return;
            }
            if (log.isDebugEnabled()) {
                log.debug("Expiring tile page " + tilePage + " based on the global "
View Full Code Here

Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

            final Quota usedQuota = monitor.getUsedQuotaByLayerName(layerName);

            Quota excedent = usedQuota.difference(quota);
            if (excedent.getBytes().compareTo(BigInteger.ZERO) > 0) {
                log.info("Layer '" + layerName + "' exceeds its quota of " + quota.toNiceString()
                        + " by " + excedent.toNiceString() + ". Currently used: "
                        + usedQuota.toNiceString() + ". Clean up task will be performed"
                        + " using expiration policy " + policy);

                Set<String> layerNames = Collections.singleton(layerName);
                QuotaResolver quotaResolver;
View Full Code Here

Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

        Quota quota = quotaModel.getObject();
        String formattedQuota;
        if (null == quota) {
            formattedQuota = new ResourceModel("CachedLayersPage.quotaLimitNotSet").getObject();
        } else {
            formattedQuota = quota.toNiceString();
        }
        return new Label(id, formattedQuota);
    }

    private Component nameLink(String id, IModel<TileLayer> itemModel) {
View Full Code Here

Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

                        final GWC gwcFacade = GWC.get();
                        Quota usedQuota = gwcFacade.getUsedQuota(layerName);
                        if (usedQuota == null) {
                            usedQuota = new Quota();
                        }
                        final String usedQuotaStr = usedQuota.toNiceString();
                        IModel<String> model = new ParamResourceModel(
                                "CachedLayersPage.confirmTruncateMessage", CachedLayersPage.this,
                                layerName, usedQuotaStr);
                        Label confirmLabel = new Label(id, model);
                        confirmLabel.setEscapeModelStrings(false);// allow some html inside, like
View Full Code Here

Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

                GWC gwc = GWC.get();
                Quota usedQuota = gwc.getUsedQuota(originalLayerName);
                if (usedQuota == null) {
                    usedQuota = new Quota();
                }
                String usedQuotaStr = usedQuota.toNiceString();
                return new Label(id, new ParamResourceModel("confirmTileLayerRemoval",
                        GeoServerTileLayerEditor.this, usedQuotaStr));
            }

            @Override
View Full Code Here

Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

            return new Label(id, zoomLevels.toString());

        } else if (property == GridSetTableProvider.QUOTA_USED) {

            Quota usedQuota = (Quota) property.getModel(itemModel).getObject();
            String quotaStr = usedQuota == null ? "N/A" : usedQuota.toNiceString();
            return new Label(id, quotaStr);

        } else if (property == GridSetTableProvider.ACTION_LINK) {
            String gridSetName = (String) property.getModel(itemModel).getObject();
View Full Code Here

Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

                limit = quotaResolver.getLimit();
                Quota usedQuota = quotaResolver.getUsed();
                if (excess.getBytes().compareTo(BigInteger.ZERO) > 0) {
                    log.warn("No more pages to expire, check if youd disk quota"
                            + " database is out of date with your blob store. Quota: "
                            + limit.toNiceString() + " used: " + usedQuota.toNiceString());
                }
                return;
            }
            if (log.isDebugEnabled()) {
                log.debug("Expiring tile page " + tilePage + " based on the global "
View Full Code Here

Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

        for (String layerName : tileLayerDispatcher.getLayerNames()) {

            Quota usedQuota = quotaStore.getUsedQuotaByLayerName(layerName);
            if (usedQuota.getBytes().compareTo(BigInteger.ZERO) > 0) {
                log.debug("Using saved quota information for layer " + layerName + ": "
                        + usedQuota.toNiceString());
            } else {
                log.debug(layerName + " has no saved used quota information,"
                        + "traversing layer cache to compute its disk usage.");
                TileLayer tileLayer;
                try {
View Full Code Here

Examples of org.geowebcache.diskquota.storage.Quota.toNiceString()

            Quota excedent = usedQuota.difference(quota);
            if (excedent.getBytes().compareTo(BigInteger.ZERO) > 0) {
                if (log.isInfoEnabled()) {
                    log.info("Layer '" + layerName + "' exceeds its quota of "
                            + quota.toNiceString() + " by " + excedent.toNiceString()
                            + ". Currently used: " + usedQuota.toNiceString()
                            + ". Clean up task will be performed using expiration policy " + policy);
                }

                Set<String> layerNames = Collections.singleton(layerName);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.