Hi Tom,
after downloading the release-0.6 tag and playing a little with TWiST and the basic tWSDL API I have some doubts as how to proceed further.
First of all checking the environment sourcing init.tcl with nstclsh I get the following error:
[24/Feb/2007:11:59:47][4792.3083896496][-main-] Error: TWS:no server
while executing
"ns_info $option"
("foreach" body line 2)
invoked from within
"foreach option {address hostname name server servers config} {
log Notice "---->\[ns_info $option\] = '[ns_info $option]'"
}"
(in namespace eval "::wsdl::server" script line 3)
invoked from within
"namespace eval ::wsdl::server {
variable hostHeaderNames
foreach option {address hostname name server servers config} {
log Notice "---->\[ns..."
(file "/usr/local/aolserver_45_r0/servers/server1/modules/tcl/twsdl/packages/wsdl/tcl/wsdl-server-init.tcl" line 7)
invoked from within
"::source /usr/local/aolserver_45_r0/servers/server1/modules/tcl/twsdl/packages/wsdl/tcl/wsdl-server-init.tcl"
("uplevel" body line 1)
invoked from within
"uplevel ::source "$file""
(procedure "::tws::sourceFile" line 4)
invoked from within
"::tws::sourceFile [file normalize [file join [file dirname [info script]] "wsdl-server-init.tcl"]]"
(file "./packages/wsdl/tcl/wsdl-init.tcl" line 11)
invoked from within
"::source ./packages/wsdl/tcl/wsdl-init.tcl"
("uplevel" body line 1)
invoked from within
"uplevel ::source "$file""
(procedure "::tws::sourceFile" line 4)
invoked from within
"::tws::sourceFile [::tws::util::package::directory [file join $packageName tcl ${packageName}-init.tcl]]"
(procedure "init" line 4)
invoked from within
"init $package" PACKAGE wsdl
[24/Feb/2007:11:59:47][4792.3083896496][-main-] Notice: TWS:Package xml: Initializing...
Note that this error don't show up during aolserver startup, which however continues to exhibit the previosly posted error.
Regarding the basic tWSDL API I finally built a working sample service which accepts a user_id and returns the name and the email of the user.
So doing I learned how to build complex types, how to define an operation and associate to it a tcl proc and now I'd like to comlicate the matters a little, but I don't know how to populate my complex types within my tcl proc.
Given the following definitions:
eval [::wsdl::elements::modelGroup::sequence::new $usersns oneUser {
{name userdecoder::name}
{email userdecoder::email}}]eval [::wsdl::elements::modelGroup::sequence::new $usersns Users {
{oneUser userdecoder::oneUser}}]
how do I put the values pulled from the db into the Users structure?
A few other questions.
Is it possible to view the generated WSDL, like in TWiST?
When you define a ::wsdl::operations::new each parameter of the tcl proc is followed by the string 'Value': what is its meaning? Is it mandatory?
TIA,
Claudio