Send Netdot-users mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
https://osl.uoregon.edu/mailman/listinfo/netdot-users
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Netdot-users digest..."
Today's Topics:
1. Error in REST-Script (Andreas Kunberger)
2. Re: Error in REST-Script (Andreas Kunberger)
----------------------------------------------------------------------
Message: 1
Date: Fri, 24 Apr 2015 11:31:48 +0200
From: Andreas Kunberger <[email protected]>
Subject: [Netdot-users] Error in REST-Script
To: [email protected] <[email protected]>
Message-ID: <[email protected]>
Content-Type: text/plain; charset="windows-1252"
Today I started an old rest script which suddenly throws an error.
?
Undeclared entity [Ln: 9, Col: 2454746274]
?
A search for the error text in all perl modules gives only XML::SAX which
didn?t help me.
?
The script excerpt was:
?
#!/usr/bin/perl -w
use Netdot::Client::REST;
my $netdot = Netdot::Client::REST->new(
server=>'http://net-dot.ditf.de/netdot',? username=>'admin',
password=>'secret',?? );
?
my $closet = $ARGV[0] || die 'No Closet';;
?
my (undef,$closets) = %{$netdot->get('/Closet?depth=1')};
?
exit;
?
?
Kind regards
?
Andreas Kunberger
?
--
?
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://osl.uoregon.edu/pipermail/netdot-users/attachments/20150424/9d5bf381/attachment-0001.html
------------------------------
Message: 2
Date: Fri, 24 Apr 2015 11:56:11 +0200
From: Andreas Kunberger <[email protected]>
Subject: Re: [Netdot-users] Error in REST-Script
To: [email protected] <[email protected]>
Message-ID: <[email protected]>
Content-Type: text/plain; charset="utf-8"
Some more infos:
Calling http://net-dot.ditf.de/netdot/rest/closet/
<http://net-dot.ditf.de/netdot/rest/closet/> which my browser gives:
error:? ? Can't locate object method "remote_ip" via package
"Apache2::Connection" at /usr/local/netdot/lib/Netdot/REST.pm line 126.
context:? ???????????
...? ?????????
122:? ????
123:? ???? # Get relevant HTTP headers from request object
124:? ???? my $headers = $self->{request}->headers_in;
125:? ????
126:? ???? $logger->info(sprintf("Netdot::REST::handle_resource: %s request for
%s?%s from %s (%s)",
127:? ???? $self->{request}->method,
128:? ???? $resource,
129:? ???? $self->{request}->args,
130:? ???? $self->{request}->connection->remote_ip,
...? ?????????
code stack:? ?????? /usr/local/netdot/lib/Netdot/REST.pm:126
/usr/local/netdot/htdocs/rest/dhandler:35
/usr/local/netdot/htdocs/rest/autohandler:27
/usr/local/netdot/htdocs/autohandler:76
?
From: [email protected]
[mailto:[email protected]] On Behalf Of Andreas Kunberger
Sent: Friday, April 24, 2015 11:32 AM
To: [email protected]
Subject: [Netdot-users] Error in REST-Script
?
Today I started an old rest script which suddenly throws an error.
?
Undeclared entity [Ln: 9, Col: 2454746274]
?
A search for the error text in all perl modules gives only XML::SAX which
didn?t help me.
?
The script excerpt was:
?
#!/usr/bin/perl -w
use Netdot::Client::REST;
my $netdot = Netdot::Client::REST->new(
server=>'http://net-dot.ditf.de/netdot',? username=>'admin',
password=>'secret',?? );
?
my $closet = $ARGV[0] || die 'No Closet';;
?
my (undef,$closets) = %{$netdot->get('/Closet?depth=1')};
?
exit;
?
?
Kind regards
?
Andreas Kunberger
?
--
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://osl.uoregon.edu/pipermail/netdot-users/attachments/20150424/9f590ec1/attachment-0001.html
------------------------------
_______________________________________________
Netdot-users mailing list
[email protected]
https://osl.uoregon.edu/mailman/listinfo/netdot-users
End of Netdot-users Digest, Vol 77, Issue 2
*******************************************