34 lines
1.2 KiB
Java
34 lines
1.2 KiB
Java
package it.acxent.cc;
|
|
|
|
import it.acxent.art.Articolo;
|
|
import it.acxent.art.ArticoloCR;
|
|
import it.acxent.common.CrontabInterface;
|
|
import it.acxent.db.ApplParmFull;
|
|
import it.acxent.db.DBAdapter;
|
|
import it.acxent.db.ResParm;
|
|
import it.acxent.util.Timer;
|
|
|
|
public class CCCronIndexNowGiornaliero implements CrontabInterface {
|
|
public ResParm crontabJob(ApplParmFull ap) {
|
|
ResParm rp = new ResParm(true);
|
|
Timer timer = new Timer();
|
|
timer.start();
|
|
System.out.println("CCCronIndexNowGiornaliero start...");
|
|
StringBuffer msg = new StringBuffer("\n################# Inizio crontab INDEXNOW CC (" +
|
|
DBAdapter.getNow().toString() + ")\n#################");
|
|
Articolo bean = new Articolo(ap);
|
|
ArticoloCR CR = new ArticoloCR();
|
|
CR.setFlgOrderBy(10L);
|
|
CR.setFlgEscludiWeb(0L);
|
|
CR.setFlgReadyForWeb(1L);
|
|
CR.setLangReadyForWeb("it");
|
|
rp = bean.callIndexNow(CR);
|
|
msg.append(rp.getMsg());
|
|
msg.append("\n################# Fine crontab INDEXNOW CC (" + DBAdapter.getNow().toString() + ")\n#################");
|
|
timer.stop();
|
|
msg.append("Durata aggiornamento: " + timer.getDurataHourMin() + "\n");
|
|
rp.setMsg(msg.toString());
|
|
System.out.println(msg.toString());
|
|
return rp;
|
|
}
|
|
}
|