Skip to content

Conversation

@hpatel41
Copy link

@hpatel41 hpatel41 commented May 9, 2022

Description of change

TDL-18878: Updated Endpoint for checklists stream

  • Updated endpoint for checklists stream as per suggested in the community

NOTE: We created this PR from TDL-16246-make-max-api-response-size-configurable-for-cards so all the changes are covered in this PR itself.

Manual QA steps

Risks

Rollback steps

  • revert this branch

@hpatel41 hpatel41 changed the base branch from master to TDL-16246-make-max-api-response-size-configurable-for-cards May 9, 2022 09:07
def __init__(self, client, config, state, catalog):
super().__init__(client, config, state, catalog)

# check is 'checklists' stream is selected
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
# check is 'checklists' stream is selected
# check if 'checklists' stream is selected

Copy link
Author

Choose a reason for hiding this comment

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

Updated.


# check is 'checklists' stream is selected
self.is_checklists_selected = self.catalog.get_stream('checklists').is_selected()
# if it is selected, then create 'CheckLists' object
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
# if it is selected, then create 'CheckLists' object
# if checklists stream is selected, then create the 'CheckLists' object

Copy link
Author

Choose a reason for hiding this comment

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

Updated.

@hpatel41 hpatel41 requested a review from savan-chovatiya May 9, 2022 10:32
}
}
},
"email": {
Copy link
Author

@hpatel41 hpatel41 May 11, 2022

Choose a reason for hiding this comment

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

Added email field for cards, as this stream was missing the field. As per this failure.

@hpatel41 hpatel41 changed the base branch from TDL-16246-make-max-api-response-size-configurable-for-cards to master May 11, 2022 08:45
Comment on lines +294 to +299
elif stream == 'checklists':
# NOTE: We updated the endpoint for checklists stream
# as a result we will not replicate this 2 fields
# Please refere card: https://jira.talendforge.org/browse/TDL-18878 for more details
expected_fields.remove('limits')
expected_fields.remove('creationMethod')
Copy link
Contributor

Choose a reason for hiding this comment

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

If these fields are not going to ever be replicated, they should be removed from the schema. Another option would be to mark them as unsupported in metadata. I am not sure which solution makes the most sense here.

Copy link
Author

Choose a reason for hiding this comment

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

@kspeer825 We have done changes for one customer as they are getting this error and it's got resolved with the alpha release.
That customer was fine if these two fields are not replicated with a newer approach so not sure if this change will be applied to all customers or not.
We can confirm it with Krishnan and also we will discuss like should we remove these fields from the schema or mark it as unsupported in metadata.

Copy link
Contributor

Choose a reason for hiding this comment

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

Is there any update on this?

Copy link
Author

Choose a reason for hiding this comment

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

No, @kspeer825 we will discuss with Krishnan in the next sync-up.

Copy link
Author

@hpatel41 hpatel41 Jun 2, 2022

Choose a reason for hiding this comment

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

@kspeer825 Krishnan suggested us to mark these fields as unsupported.

Copy link
Contributor

Choose a reason for hiding this comment

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

In that case I think the discovery test will need to be updated to check that those fields are marked as unsupported in metadata.

Copy link
Author

Choose a reason for hiding this comment

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

@kspeer825 The discovery test was not as per the standard, thus we updated the discovery test.

@hpatel41 hpatel41 requested a review from kspeer825 May 18, 2022 08:45
# mark unsupported fields as 'unsupported' in the metadata
for field_name in stream.unsupported_fields:
metadata.write(mdata, ('properties', field_name), 'inclusion', 'unsupported')
metadata.write(mdata, ('properties', field_name), 'unsupported-description', \
Copy link
Author

Choose a reason for hiding this comment

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

As per this code, we added description of unsupported fields.

Comment on lines +294 to +299
elif stream == 'checklists':
# NOTE: We updated the endpoint for checklists stream
# as a result we will not replicate this 2 fields
# Please refere card: https://jira.talendforge.org/browse/TDL-18878 for more details
expected_fields.remove('limits')
expected_fields.remove('creationMethod')
Copy link
Contributor

Choose a reason for hiding this comment

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

In that case I think the discovery test will need to be updated to check that those fields are marked as unsupported in metadata.

@hpatel41 hpatel41 requested a review from kspeer825 June 16, 2022 12:06
Copy link
Contributor

@kspeer825 kspeer825 left a comment

Choose a reason for hiding this comment

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

Great work on the testing

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.

7 participants