@@ -62,12 +62,12 @@ class FeedIndexMetadata
6262 /**
6363 * @var int
6464 */
65- private $ fullReindexDaysLimit ;
65+ private $ fullReindexSecondsLimit ;
6666
6767 /**
6868 * @var string
6969 */
70- private $ sourceTableFieldOnFullReIndexDaysLimit ;
70+ private $ sourceTableFieldOnFullReIndexLimit ;
7171
7272 /**
7373 * @param string $feedName
@@ -79,6 +79,8 @@ class FeedIndexMetadata
7979 * @param array $feedTableMutableColumns
8080 * @param int $batchSize
8181 * @param string|null $sourceTableIdentityField
82+ * @param int $fullReIndexSecondsLimit
83+ * @param string $sourceTableFieldOnFullReIndexLimit
8284 */
8385 public function __construct (
8486 string $ feedName ,
@@ -90,8 +92,8 @@ public function __construct(
9092 array $ feedTableMutableColumns ,
9193 int $ batchSize = 100 ,
9294 string $ sourceTableIdentityField = null ,
93- int $ fullReIndexDaysLimit = 0 ,
94- string $ sourceTableFieldOnFullReIndexDaysLimit = 'updated_at '
95+ int $ fullReIndexSecondsLimit = 0 ,
96+ string $ sourceTableFieldOnFullReIndexLimit = 'updated_at '
9597 ) {
9698 $ this ->feedName = $ feedName ;
9799 $ this ->sourceTableName = $ sourceTableName ;
@@ -102,8 +104,8 @@ public function __construct(
102104 $ this ->feedTableMutableColumns = $ feedTableMutableColumns ;
103105 $ this ->batchSize = $ batchSize ;
104106 $ this ->sourceTableIdentityField = $ sourceTableIdentityField ?? $ sourceTableField ;
105- $ this ->fullReindexDaysLimit = $ fullReIndexDaysLimit ;
106- $ this ->sourceTableFieldOnFullReIndexDaysLimit = $ sourceTableFieldOnFullReIndexDaysLimit ;
107+ $ this ->fullReindexSecondsLimit = $ fullReIndexSecondsLimit ;
108+ $ this ->sourceTableFieldOnFullReIndexLimit = $ sourceTableFieldOnFullReIndexLimit ;
107109 }
108110
109111 /**
@@ -197,20 +199,20 @@ public function getFeedTableMutableColumns(): array
197199 }
198200
199201 /**
200- * Determines the amount of days back when triggering a full reindex
201- * @return int the amount in days , 0 means no limit
202+ * Determines the amount of seconds back in time when triggering a full reindex
203+ * @return int the amount in seconds , 0 means no limit
202204 */
203- public function getFullReIndexDaysLimit (): int
205+ public function getFullReIndexSecondsLimit (): int
204206 {
205- return $ this ->fullReindexDaysLimit ;
207+ return $ this ->fullReindexSecondsLimit ;
206208 }
207209
208210 /**
209- * Table field name to use when full reindex is limited by days back (see fullReindexDaysLimit )
211+ * Table field name to use when full reindex is limited (see fullReindexSecondsLimit )
210212 * @return string the field name
211213 */
212- public function getSourceTableFieldOnFullReIndexDaysLimit (): string
214+ public function getSourceTableFieldOnFullReIndexLimit (): string
213215 {
214- return $ this ->sourceTableFieldOnFullReIndexDaysLimit ;
216+ return $ this ->sourceTableFieldOnFullReIndexLimit ;
215217 }
216218}
0 commit comments