ADF - REST连接器 - 分页规则 - 动态内容 [英] ADF - REST Connector - Pagination Rules - Dynamic Content

查看:57
本文介绍了ADF - REST连接器 - 分页规则 - 动态内容的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是ADF的新手,正在探索从使用REST连接器分页的RESTful API中提取数据。我可以从第一个结果页面中提取数据,但我似乎无法弄清楚如何正确配置分页以拉回返回的完整数据
set。部分挑战是所使用的API不符合ADF REST如何根据文档操作的基本假设。我一直在浏览ADF文档,MSDN论坛,O'Reilly学习平台和谷歌,但在我的问题中找不到任何
的有用答案。 



我正在尝试使用增量导出端点从Zendesk Support API提取数据:



https://developer.zendesk.com/rest_api/docs/support/incremental_export #pagination



此端点有助于提供"next_page"URL的返回值,该值可以传递到分页规则下的AbsoluteURL变量中,但是,当它到达时,不会返回null在最后一页,它返回用于下一次计划导出的URL。
ADF REST文档状态:'连接器将在获取HTTP状态代码204(无内容)或"paginationRules"中的任何JSONPath表达式时停止迭代。返回null。'实际上,我对Zendesk API的调用陷入无限循环,然后是
错误。我可以使用另一个返回值'count'来确定返回的页面是完整的还是部分的。如果返回部分页面,则此信号退出条件。 
$


我试图为AbsoluteURL创建一个动态表达式,如果返回完整页面则返回'next_page' null,如果是partial。我好像不知道怎么做。这甚至可能吗?我还可以尝试其他方法吗?似乎有一些建议
使用ForEach与HTTP连接器,但这假设我有一个项目列表传递给ForEach,我没有(并且还没有找到一种方法来动态创建这个其他可用的Zendesk API endoints)。 
$


任何指针都会非常感激。 

Hi, I'm new to ADF and am exploring pulling data from a RESTful API that uses pagination using REST connector. I can pull data from the first result page, but I don't seem to be able to work out how to correctly configure pagination to pull the full data set returned. Part of the challenge is that the API used does not conform to basic assumptions of how ADF REST operates according to documentation. I've been through ADF documentation, MSDN forums, O'Reilly Learning platform and Google and could not find any useful answers to my question. 

I'm trying to pull data from Zendesk Support API using Incremental Export endpoint:

https://developer.zendesk.com/rest_api/docs/support/incremental_export#pagination

This endpoint helpfully provides a return value of 'next_page' URL that could be passed into AbsoluteURL variable under Pagination Rules, however, instead of returning null when it reaches the last page, it returns URL to be used for next scheduled export. ADF REST docs state: 'The connector will stop iterating when it gets HTTP status code 204 (No Content), or any of the JSONPath expression in "paginationRules" returns null.' Effectively my call to Zendesk API gets stuck in an endless loop and then errors. I could use another return value 'count' to determine if the returned page is full or partial. If a partial page is returned, this signals exit condition. 

I was trying to create a dynamic expression for AbsoluteURL to return 'next_page' if full page returned and null if partial. I don't seem to figure out how to do this. Is this even possible? Are there any other approaches I can try? There seem to be some suggestions of using ForEach with HTTP Connector, but this assumes I have a list of items to pass into ForEach, which I don't (and haven't yet found a way to dynamically create this from other available Zendesk API endoints). 

Any pointers would be much appreciated. 

推荐答案

Hello InsightDudeUK。 感谢您提请我们注意。 我将调查此问题,并在收到更多信息时进行回复。
Hello InsightDudeUK.  Thank you for bringing this to our attention.  I will investigate the issue and reply when I have more information.


这篇关于ADF - REST连接器 - 分页规则 - 动态内容的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆