/** * Creates a new producer for this thread and stores it in the thread local. * @param req The portlet request * @param resp The portlet response * @param config The portlet config */ public static void setPrecursors(PortletRequest req, PortletResponse resp, PortletConfig config) { PortletArtifactProducer pap = getPAP(); pap.req = req; pap.resp = resp; pap.config = config; if (isTrace) { StringBuilder txt = new StringBuilder(80); txt.append("Set precursors."); txt.append(" ThreadId=").append(Thread.currentThread().getId()); txt.append(", Portlet name: ").append(config == null ? "null" : config.getPortletName()); LOG.trace(txt.toString()); } }