-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🎉 New Source: Netsuite #13086
🎉 New Source: Netsuite #13086
Conversation
The acceptance tests are failing because of timeouts. I think this is due to the connector dynamically pulling all of the objects and schemas for Netsuite, which takes a long time. This is necessary since the schemas are Netsuite instance specific. Netsuite allows the addition of custom fields and record types, which are captured in the dynamic schemas generated by Netsuite, but couldn't be with hard coded schemas. Any ideas on how to fix the timeout issues while still pulling the schemas dynamically? |
70a43f9
to
75cb328
Compare
I added an array property where users can specify the record types they want. This leads to a better user experience as it speeds up the source retrieval process dramatically and makes navigating the available streams much simpler. Setting this before running the integration tests resolves the timeout issue. Closing this PR for now, though, as there are some other issues with the source that need to be addressed. |
All the issues with the acceptance tests have been addressed. |
Thanks for this amazing contributon @wjwatkinson ! I'll ask the team to review it. |
record_types: | ||
type: array | ||
items: | ||
type: string | ||
description: The API names of the Netsuite objects you want to sync. Setting this speeds up the connection setup process by limiting the number of schemas that need to be retrieved from Netsuite. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so you need to specify what schema/streams do you want to sync? maybe give the option to sync aditional streams BUT the connector need the default ones.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you do not specify anything the connector will pull all objects present in the user's Netsuite instance. This takes a really long time, though, which is not a great experience and caused acceptance tests to fail.
35e1b1c
to
4974465
Compare
FWIW I realized recently that there is an Airbyte JDBC source framework (I missed it because it's not in the CDK documentatin). This is likely a cleaner and faster way to retrieve Netsuite data. I'm open to renaming this connector to |
Hello @wjwatkinson sorry the delay in return to you. I'll ask the connector team to review and validate your contribution. |
Thanks @marcosmarxm! Hi @wjwatkinson, thank you so much for your contribution. Our team was actually also looking at creating this connector so I'm tagging in @drrest who was looking at it so he can not only review your contribution but can also make suggested updates based on the research we've done on our end. |
Has this been overtaken by #16093? |
Closing this, as of #16093 was merged already. |
Unfortunate that #16093 has the same architecture as I used here and therefore the same limitations in performance and schema retrieval. |
Are you able to specify the performance and schema retrieval limitations you ran into? This is helpful feedback for us to keep improving the connector during the alpha period @wjwatkinson cc: @YowanR |
I mentioned this to @YowanR and others in a slack thread where I was helping with Netsuite auth. The Netsuite REST API query returns only record ids, so you have to make 1 request per record to Netsuite to get the data. This results in very slow extraction. There are further performance issues mentioned in this PR to do with retrieving schemas. I resolved these by passing in an array of object names, so fewer schemas are retrieved, but it's annoying. It looks like this same approach was taken in the merged source. Netsuite offers a JDBC connector and it looks like Airbyte has a JDBC source framework, which I mentioned in a comment here, that seems like it would have better performance, but I am not very familiar with the technology. |
I agree the SOAP or REST approaches are weak in terms of performance in general, REST allows us to fetch all possible objects and use them as streams of data. Probably the JDBC approach will give us the opportunity to work with Netsuite as Database, if so - the schema retrieval should be much faster, not sure about the streaming performance, but definitely worth trying. |
Generally I have found the performance of JSON APIs performant enough for us, but they return 100+ records per call making them 100+x more efficient than the Netsuite API. |
@wjwatkinson |
Netsuite's queries only return record ids, so you have to make an additional request per record. 1000 records = 1001 requests. All of the other APIs I work with through Airbyte return the data directly in the query, so one request returns 100 records. 1000 records = 10 requests. If you're asking what I mean by JSON APIs I just mean APIs that return JSON data. REST has a specific definition JSON APIs generally don't meet, although I think Netsuite's REST API does. |
What
Netsuite Connector
How
Add Netsuite Connector using python cdk
Pre-merge Checklist
Expand the relevant checklist and delete the others.
New Connector
Community member or Airbyter
airbyte_secret
./gradlew :airbyte-integrations:connectors:<name>:integrationTest
.README.md
bootstrap.md
. See description and examplesdocs/SUMMARY.md
docs/integrations/<source or destination>/<name>.md
including changelog. See changelog exampledocs/integrations/README.md
airbyte-integrations/builds.md
Airbyter
If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.
/test connector=connectors/<name>
command is passing/publish
command described hereTests
Unit
Integration
Put your integration tests output here.
Acceptance