@Override
	public int doStartTag() throws JspException {
		handleEventualEvictCache();

		RestletResourceFactory factory = new RestletResourceFactory();

		Logger logger = Context.getCurrentLogger();


		String fullSearchUri = buildSearchUriToUse();

		logger.log(Level.FINEST, "fullSearchUri: " + fullSearchUri);

		List<PackageMeta> packageMetaList = null;

		// retrieving eventual data from cache
		if (caching) {
			packageMetaList = retrieveFromCache(fullSearchUri);
		}

		if (packageMetaList == null) {
			SearchResultMetaRestletResource restletResource = factory
					.createSearchResultMetaResource(fullSearchUri);

			logger.log(Level.FINEST,
					"restletResource: " + restletResource.toString());

			SearchResultMeta listOfFoundPackagesResult = restletResource.get();

			logger.log(Level.FINEST, "listOfFoundPackagesResult: "
					+ listOfFoundPackagesResult);

			packageMetaList = new ArrayList<PackageMeta>();

			for (String packageName : listOfFoundPackagesResult.getResults()) {
				packageMetaList.add(retrievePackageMeta(packageName, factory));
			}

			logger.log(Level.FINEST, "packageMetaList: " + packageMetaList);

			if (caching) {
				storeInCache(fullSearchUri, packageMetaList);
			}
		} else {
			logger.log(Level.FINEST, "packageMetaList retrieved from cache : "
					+ packageMetaList);
		}

		pageContext.setAttribute(getVar(), packageMetaList);
		pageContext.setAttribute("searchUri", fullSearchUri);

		return SKIP_BODY;
	}