2012-02-25 5 views
0

우리의 앱에서 몇 가지 사항을 업그레이드했는데 이제 Akamai에 대한 비누 요청이 실행되지 않습니다. 단위 테스트 대신 여기에 아카 마이 클래스의 RuntimeError: Assert: unknown array definition레일 3 : Soap4r이 akamai 요청에 대해 "Assert : unknown array definition"을 반환했습니다.

의 반환을 일으킬 : 나는 나는 우리의 업그레이드 지점에 추가 한 새로운 보석 될 줄 알았는데

require 'rexml/document' 

class Akamai 
    def self.purge_cache(url) 
    require 'soap/wsdlDriver' 
    factory = SOAP::WSDLDriverFactory.new('https://ccuapi.akamai.com/ccuapi-axis.wsdl') 
    driver = factory.create_rpc_driver 
    driver.purgeRequest(
     'our-username', # username 
     'our-password', # password 
     '', # network; deprecated 
     [], # options 
     [url] 
    ) 
    end 
end 

,하지만 두 개의 추가는 Gemfile에만있다 :

gem 'libxml-ruby', '1.1.4' 
gem 'nokogiri' 

문제를 해결한다고해서 문제가 해결되지는 않습니다. 여기에 오류가 분출입니다 :

test_unsuccessful_purge(AkamaiTest): 
RuntimeError: Assert: Unknown array definition. 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/wsdl/soap/complexType.rb:122:in `find_arytype' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/wsdl/soap/complexType.rb:161:in `content_arytype' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/wsdl/soap/complexType.rb:55:in `child_type' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/wsdlencodedregistry.rb:168:in `array2soap' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/wsdlencodedregistry.rb:145:in `complexobj2soap' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/wsdlencodedregistry.rb:121:in `obj2typesoap' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/wsdlencodedregistry.rb:38:in `obj2soap' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/mapping.rb:135:in `_obj2soap' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/mapping.rb:54:in `block (2 levels) in objs2soap' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/mapping.rb:52:in `upto' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/mapping.rb:52:in `block in objs2soap' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/mapping.rb:560:in `block in protect_mapping' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/mapping.rb:533:in `protect_threadvars' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/mapping.rb:549:in `protect_mapping' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/mapping/mapping.rb:51:in `objs2soap' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/rpc/proxy.rb:475:in `request_rpc_enc' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/rpc/proxy.rb:457:in `request_rpc' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/rpc/proxy.rb:412:in `request_body' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/rpc/proxy.rb:127:in `call' 
    /Users/kevin/.rvm/gems/[email protected]/gems/soap4r-ruby1.9-2.0.3/lib/soap/rpc/driver.rb:151:in `call' 
    (eval):6:in `purgeRequest' 
    /Users/kevin/code/medialytics/app/models/akamai.rb:8:in `purge_cache' 
    test/unit/akamai_test.rb:12:in `block in <class:AkamaiTest>' 

답변

0

내가 더 최근에 업데이트 된 이후, 모두 함께 soap4r-ruby1.9 덤핑 및 Savon로가는 결국 더 나은 넣어-함께 할 것으로 보인다.

+0

동의 함. Savon은 훨씬 쉽습니다. – revolver