auth::sync::get_doc::http::GetDocument (private)

 auth::sync::get_doc::http::GetDocument parameters

Defined in packages/acs-authentication/tcl/sync-procs.tcl

Retrieve the document by HTTP

Parameters:
parameters (required)

Partial Call Graph (max 5 caller/called nodes):
%3 test_sync_http_get_document sync_http_get_document (test acs-authentication) auth::sync::get_doc::http::GetDocument auth::sync::get_doc::http::GetDocument test_sync_http_get_document->auth::sync::get_doc::http::GetDocument util::http::get util::http::get (public) auth::sync::get_doc::http::GetDocument->util::http::get AcsSc.auth_sync_retrieve.getdocument.httpget AcsSc.auth_sync_retrieve.getdocument.httpget (private) AcsSc.auth_sync_retrieve.getdocument.httpget->auth::sync::get_doc::http::GetDocument auth::sync::get_doc::http::register_impl auth::sync::get_doc::http::register_impl (private) auth::sync::get_doc::http::register_impl->auth::sync::get_doc::http::GetDocument

Testcases:
sync_http_get_document
Source code:
    array set result {
        doc_status failed_to_conntect
        doc_message {}
        document {}
        snapshot_p f
    }

    array set param $parameters

    if { ($param(SnapshotURL) ne "" && [clock format [clock seconds] -format "%d"] eq "01")
         || $param(IncrementalURL) eq ""
     } {
        # On the first day of the month, we get a snapshot
        set url $param(SnapshotURL)
        set result(snapshot_p) "t"
    } else {
        # All the other days of the month, we get the incremental
        set url $param(IncrementalURL)
    }

    if { $url eq "" } {
        error "You must specify at least one URL to get."
    }

    set dict [util::http::get -url $url]
    set result(document) [dict get $dict page]

    set result(doc_status) "ok"

    return [array get result]
Generic XQL file:
packages/acs-authentication/tcl/sync-procs.xql

PostgreSQL XQL file:
packages/acs-authentication/tcl/sync-procs-postgresql.xql

Oracle XQL file:
packages/acs-authentication/tcl/sync-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: