2012-02-13 4 views
0

그래서 http://www.teamliquid.net/video/streams/?filter=live&xml=1에 API를 사용하여 YQL 테이블을 설정하려고하지만 몇 가지 문제가 있습니다.YQL 테이블이 작동하는 데 문제가 발생했습니다.

<?xml version="1.0" encoding="UTF-8"?> 
<query xmlns:yahoo="http://www.yahooapis.com/v1/base.rng" 
    yahoo:count="0" yahoo:created="2012-02-13T22:14:48Z" yahoo:lang="en-US"> 
    <diagnostics> 
     <publiclyCallable>true</publiclyCallable> 
     <url execution-start-time="1" execution-stop-time="33" 
      execution-time="32" proxy="DEFAULT"><![CDATA[store://q5awkFLmEqteFVOTUJbQ6h]]></url> 
     <url execution-start-time="35" execution-stop-time="232" 
      execution-time="197" http-status-code="406" 
      http-status-message="Not Acceptable" proxy="DEFAULT"><![CDATA[http://www.teamliquid.net/video/streams/?xml=1&filter=live]]></url> 
     <user-time>232</user-time> 
     <service-time>258</service-time> 
     <build-version>25247</build-version> 
    </diagnostics> 
    <results/> 
</query> 

난 정말이 작동하지 않는 이유를 알아낼 수 없습니다 :

<?xml version="1.0" encoding="UTF-8"?> 
<table xmlns="http://query.yahooapis.com/v1/schema/table.xsd"> 
    <meta> 
     <author>TL.net</author> 
     <description>TL.net's streams</description> 
     <documentationURL>none</documentationURL> 
     <sampleQuery>select * from {table}</sampleQuery> 
    </meta> 
    <bindings> 
     <select itemPath="streamlist" produces="XML"> 
      <urls> 
       <url>http://www.teamliquid.net/video/streams/?xml=1</url> 
      </urls>   
      <inputs> 
       <key id="filter" type="xs:string" paramType="query" /> 
      </inputs> 
     </select> 
    </bindings> 
</table> 

use "store://q5awkFLmEqteFVOTUJbQ6h" as tl; select * from tl where filter="live"를 실행하면 다음과 같은 오류를 얻을 :

여기 내 테이블 정의합니다.

답변

1

디버그 문에서 YQL이 소스 URL (http://www.teamliquid.net/video/streams/?xml=1&filter=live)을 읽고 있지만 HTTP 406 Not Acceptable 오류 메시지를 수신하고 있음을 알 수 있습니다.

HTTP 406은 서버가 요청 된 (Accept 헤더) 형식으로 응답 할 수없는 경우를 포함합니다.

  1. YQL 서버가 요청하지 않는 데이터 : 나는 두 가지 중 하나 의심

    gzip encoding is required, please also send a valid User-Agent with the name of your application/site and contact info. This page and the XML are updated every five minutes, please do not poll more frequently than every five minutes or you may risk being IP banned. If you have any questions, please PM R1CH.

    : 즉,이 경우에 적용하는 방법을 모르겠어요,하지만 teamliquid.net 소스는 다음과 같은 언급 GZIP 또는 압축 된 형식

  2. 의 teamliquid.net 서버 나뿐만 아니라 gzip으로 문제를 의심 YQL
+0

을 차단하고, 감사합니다! – Tony

관련 문제