aries-auto / ariesautomotive

Aries Automotive Website
MIT License
1 stars 3 forks source link

ARIES Look Up Populating Part Duplicates #263

Closed mcrandell closed 7 years ago

mcrandell commented 7 years ago

When you look a 2016 Chevrolet Silverado 2500 HD. And you look at 6" Ovals. The results are being duplicated 4 times. image

The data isn't duplicated in the godzilla database from what i can see. image

dgallegos commented 7 years ago

I'm on it.

mcrandell commented 7 years ago

@dgallegos looks like the replication is also on the part page for a parts application data: image

Parts brought to my attention: 4084, 4084-2, P4084

dgallegos commented 7 years ago

@mcrandell, I verified the parts are fixed. I'm not sure where that link is to the application guides. Can you send me a link to those application guides.

mcrandell commented 7 years ago

@dgallegos the duplicates were removed on my end. I asked Jesse Bauer in Product Management to look as well. Once he confirms we can close the ticket.

mcrandell commented 7 years ago

@dgallegos Jesse Bauer confirmed issue is resolved. I'm closing this ticket.

davidvthecoder commented 7 years ago

The problem was in the IAPI endpoint for importing app data from the Product Desk CSV. The endpoint was taking longer than 30 seconds (expected) and Nginx was timing the response out and trying it again after 30 seconds. This would cause an overlap and duplicate processes from running. Traditionally any process that took longer than 15 seconds we would wrap in a go-routine so it would not block and would come back with a response. This was not the case for this endpoint so I implemented it and it fixed the duplication issue.

There is still a low risk of that endpoint could be called multiple times by us Developers, and I will create a separate issue for that problem.

dgallegos commented 7 years ago

http://ariesautomotive.com/vehicle/2008/JEEP/WRANGLER

This appears to still be occurring. Check all products under "Modular Bumpers"

davidvthecoder commented 7 years ago

the duplicates have been removed. Still investigating any potential causes for this.

davidvthecoder commented 7 years ago

Update: The cause was the App Import was running multiple times due to a retry policy. We still want this expected behavior so I instead added a logger that logs every app data import and its progress. It stores that information in MongoDB. It also prevents the App Data import process from running multiple times in a 6 hour time period. This prevents future duplicates cause from the import process.