Skip to content

Conversation

@findingrish
Copy link
Contributor

No description provided.

@findingrish findingrish requested a review from a team December 14, 2020 18:23
createAttributeValue(path));
}
entityBuilder.putIdentifyingAttributes(RawSpanConstants.getValue(Sql.SQL_DB_TYPE),
entityBuilder.putAttributes(RawSpanConstants.getValue(Sql.SQL_DB_TYPE),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't this burn us a while ago in prod?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you mean?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this isn't an identifying attribute for BACKEND entity, it should be fine.

rs0:PRIMARY> db.entity_types.find({name:"BACKEND"}).pretty()
{
	"_id" : "__root:BACKEND",
	"_lastUpdateTime" : ISODate("2020-08-06T17:36:06.202Z"),
	"attributeType" : [
		{
			"name" : "BACKEND_HOST",
			"valueKind" : "TYPE_STRING",
			"identifyingAttribute" : true
		},
		{
			"name" : "BACKEND_PORT",
			"valueKind" : "TYPE_STRING",
			"identifyingAttribute" : true
		},
		{
			"name" : "BACKEND_PATH",
			"valueKind" : "TYPE_STRING"
		},
		{
			"name" : "BACKEND_PROTOCOL",
			"valueKind" : "TYPE_STRING",
			"identifyingAttribute" : true
		}
	],
	"createdTime" : NumberLong("1596656818940"),
	"name" : "BACKEND",
	"tenantId" : "__root"
}

@buchi-busireddy
Copy link
Contributor

@rish691 i'm just curious about what kind of issues this was causing?

@findingrish
Copy link
Contributor Author

@rish691 i'm just curious about what kind of issues this was causing?

This causes exception while registering backend entity.
java.lang.IllegalArgumentException: Received and expected identifying attributes differ. Received: [BACKEND_PROTOCOL, BACKEND_HOST, BACKEND_PORT, sql.db_type] . Expected: [BACKEND_HOST, BACKEND_PROTOCOL, BACKEND_PORT]`

@findingrish findingrish merged commit 8a8e32f into main Dec 15, 2020
@findingrish findingrish deleted the jdbc-backend-update-identifying-attribute branch December 15, 2020 04:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants