Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Seeding query

When defining the "Seeding query" in a job involving a JDBC connector, MCF introduce two usefull variables to deal with delta crawls:

  • $STARTTIME : Which represents the timestamp in MILLISECONDS of the start time of the last FINISHED run of the job. It means that the first time you will run the job, this variable will be equals to 0 and will have a value only when the job will have run (and have finished with a "done" status) at least once.
  • $ENDTIME : Which represents the timestamp in MILLISECONDS of the end time of the last FINISHED run of the job. It means that the first time you will run the job, this variable will be equals to 0 and will have a value only when the job will have run (and have finished with a "done" status) at least once.

Usually, those variables are very usefull to compare them to the timestamp of the last modified date of a document. But be careful, the timestamp provided is expressed in milliseconds and not in seconds like a standard Unix timestamp ! Keep it in mind cause in most cases you will need to adjust either the timestamp on the Database side or divide the timestamp provided by MCF by 1000 to converti it into a Unix format !


Version check query

This query is very important because it will generate a VERSIONCOLUMN variable for each crawled document that will be associated to the doc ID and will be used by MCF to determine during a delta crawl if the document needs to be re-indexed or not. Basically the best practice is to bind the VERSIONCOLUMN to a table column of a document that is updated each time a modification is performed on the document. If you cannot have such a column in your DB schema, what we advise is to create a function on Database side that will generate a hash for a document, based on each column value. With such a function, if any of the values of a DB document changes, the hash will also change. Now if you set this DB function as the VERSIONCOLUMN, MCF will know the document has to be re-indexed. 

  • No labels