Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,463,633
Community Members
 
Community Events
176
Community Groups

Bitbucket Server attempts to add AD user to group twice

We are using Windows AD with Bitbucket server and saw a set of errors caused when a new user was added to AD.

Bitbucket is attempting to add the new user to a group (based on the AD group), but for some reason the user already exists in that group but with a different id (primary key).  The attempt to insert fails as a result of violating the unique constraints.

Here is the SQL statement that fails (names have been changed):

insert into
cwd_membership (parent_id,
child_id,
membership_type,
group_type,
parent_ name,
lower_parent_name,
child_name,
lower_child_name,
created_date,
directory_id,
id)
Values (295004,
1540097,
'GROUP_USER',
'GROUP',
'Employees',
'employees',
'john.doe',
'john.doe',
'2021-07-28 13:17:41.355-04',
229379,
1572876)

A record for this user already exists in the table, with the same information, but with a different id (primary key).
The existing record has an id of 1572868, while the record being inserted has an id of 1572876.

I'm not sure where (or how) Bitbucket is determining the id to use for inserting into the table.

Can anyone explain why Bitbucket is trying to add this user to the group TWICE?

Should I update the existing record to match the new id Bitbucket is trying to use?

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS

Atlassian Community Events