cancel
Showing results for 
Search instead for 
Did you mean: 

Deadlock In commerce cloud Telco OOTB initialization

rayman245
Participant
574

Hi All,

Today I performed a build of the telco, media and utilities accelerator ootb, And deployed it to the commerce cloud development container with initialization. After about an hour, Kibana shows that the sync job has encountered a deadlock and the same cronjob keeps repeating. I have tried the following methods none of which worked:

1) Redeploy without migration, entering into hac and performing initialization -> Unfortunately this causes a dump to occur on the hac before the initialization takes place.
2) Tried redeploying the build but with system update -> This seems to work out, but upon entering backoffice or any site I am required to initialize the system which brings us back to the problem in (1).

The system was running a b2c_acc_plus build previously, not sure if that may have something to do with what's going on right now since I am re initializing.

The error message that is received from Kibana is this:{\"timeMillis\":1582042774028,\"thread\":\"main\",\"level\":\"INFO\",\"loggerName\":\"de.hybris.platform.catalog.jalo.synchronization.CatalogVersionSyncMaster\",\"message\":\"8558. pass, 0 (+1) of 1 items processed (0 %), 0.75 items/sec, 1 (+1, deadlocks:1) items dumped.\",\"endOfBatch\":false,\"loggerFqcn\":\"de.hybris.platform.util.logging.HybrisLogger\",\"contextMap\":{\"CronJob\":\"(000000CZ) \",\"Tenant\":\"\"},\"threadId\":1,\"threadPriority\":5}

Thanks,
Raymond

alex_alvarez
Product and Topic Expert
Product and Topic Expert
0 Kudos

What version are you running? Are you on the latest patch?

rayman245
Participant
0 Kudos

Yes, 1905 for commerce and 1911 for the telco media and utils extension pack.

nicolabeghin-2
Advisor
Advisor

I'm beginning to think it's a bug of latest Commerce 1905 patch 11

Accepted Solutions (1)

Accepted Solutions (1)

rayman245
Participant
0 Kudos

Just an update to this question,

The issue was related to the database server disconnected or in deadlock mode. Needed SAP's help to fix this one.

Cheers.

Answers (2)

Answers (2)

stephen_spalding
Contributor

Hi Raymond,

When initializing the B2B PowerTools accelerator, I also got lots of deadlock errors. I installed this locally on a Windows laptop, using SQL Server locally as well. I had missed a step of the SQL Server installation process which said to run the following commands:

ALTER DATABASE <hybris> SET READ_COMMITTED_SNAPSHOT ON;
ALTER DATABASE <hybris> SET ALLOW_SNAPSHOT_ISOLATION ON;

Replace <hybris> in the commands above with the name of your SQL Server db. I got those commands from this page:

https://help.sap.com/viewer/a74589c3a81a4a95bf51d87258c0ab15/1905/en-US/8c10641f86691014ab1ad4f02d3b...

After running these commands in my database, my deadlock problems went away.

Not sure if this is similar to your problem, but I hope this helps.

Thanks!

Stephen Spalding

rayman245
Participant
0 Kudos

Hi Stephen,

Thank you for the quick response, because this is on the cloud I am not sure how to perform the above to the database.

I have contacted SAP via incident, hoping to get it fixed soon.

On another note are there any documents that explain how to connect to the cloud database and perform the above. Or if there is any way of delete/restart the database server in case of deadlock issues?

Thanks,

stephen_spalding
Contributor
0 Kudos

Hi Raymond,

I'm still kind of new to SAP Commerce and am not familiar with connecting to the cloud database. Hopefully SAP support will be able to help you through this.

-StephenS

alex_alvarez
Product and Topic Expert
Product and Topic Expert
0 Kudos

Can you try the following:

DELETE FROM itemsynctimestamps c WHERE c.p_targetitem IS null;

DELETE FROM itemsynctimestamps c

WHERE c.p_sourceitem IN (
SELECT pk FROM productfeatures
)
AND c.p_targetitem NOT IN (
SELECT pk FROM productfeatures
);

then clear the cache from /hac
and run full sync again