Hi All, I written one cron job to read the CSV file from data directory. In cron job implementation I am calling the service for Raw item , canonical and publication as follows.
POST - http://localhost:8080/datahub-webapp/v1/data-feeds/DEFAULT_FEED/items/RawProduct and
POST - http://localhost:8080/datahub-webapp/v1/pools/GLOBAL/compositions and POST - http://localhost:8080/datahub-webapp/v1/pools/GLOBAL/publications
Sometimes The product is coming immediately but some times it is not processing immediately product data. At that time I am getting the publication status success from the response. The records are inserting in the Raw Item, Canonical but not In the publication table and also there no record in the publication error and publication retry table also.
How to process the data immediately when I run the cron job using CSV Web Service Extension
Thanks
Check if the feed is completed before triggering the composition.
Check if the composition is completed before triggering the publication.
You can do GET requests on the feed and composition to know their status. Continuously do GET requests until the status is not IN_PROGRESS
.
You can also write event listeners on the data hub to be more immediate on triggering the next transformation phase.
Add a comment