Send Netdot-devel mailing list submissions to
        [email protected]

To subscribe or unsubscribe via the World Wide Web, visit
        https://osl.uoregon.edu/mailman/listinfo/netdot-devel
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-devel digest..."


Today's Topics:

   1. [Netdot - Bug #1738] (In Progress) REST host      resource does
      not return propper HTTP status codes ([email protected])
   2. [SCM] Netdot branch master updated.       netdot-1.0.4-64-g92f5160
      ([email protected])


----------------------------------------------------------------------

Message: 1
Date: Wed, 15 May 2013 12:48:35 -0700
From: [email protected]
Subject: [Netdot-devel] [Netdot - Bug #1738] (In Progress) REST host
        resource does not return propper HTTP status codes
To: [email protected], [email protected]
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8


Issue #1738 has been updated by Anton Berezin.

Status changed from New to In Progress

Fixed in 
https://github.com/tobez/Netdot/commit/14a284256138ea7fac86c425725e12e0cb0b1495 
, which will hopefully get merged into the main branch.
----------------------------------------
Bug #1738: REST host resource does not return propper HTTP status codes
https://osl.uoregon.edu/redmine/issues/1738#change-3075

Author: Matej Vadnjal
Status: In Progress
Priority: Normal
Assignee: 
Category: 
Target version: 
Resolution: 


If I do a request for something that does not exist, the response gets a HTTP 
status code OK. This is with Wireshark sees:

<pre>
GET /netdot/rest/host?rrid=5690 HTTP/1.1
Host: <removed>.arnes.si
Connection: keep-alive
Accept: text/xml; version=1.0
Cookie: Apache2::SiteControl_Netdot=<removed>;

HTTP/1.1 200 OK
Date: Tue, 19 Feb 2013 09:19:37 GMT
Server: Apache/2.2.15 (CentOS)
Connection: close
Transfer-Encoding: chunked
Content-Type: text/html; charset=UTF-8

c
RR not found
0
</pre>

Status code 200 is returned no mater what kind of exception is thrown in 
@netdot/htdocs/rest/host@. The generic REST resources like Device and Ipblock 
return proper status code.

Looking at the code I think you should be catching exceptions thrown in 
@netdot/htdocs/rest/host@ and then calling @$m->clear_and_abort();@ like you do 
@netdot/htdocs/rest/dhandler@.



-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://osl.uoregon.edu/redmine/my/account


------------------------------

Message: 2
Date: Wed, 15 May 2013 12:55:25 -0700
From: [email protected]
Subject: [Netdot-devel] [SCM] Netdot branch master updated.
        netdot-1.0.4-64-g92f5160
To: [email protected]
Message-ID: <[email protected]>

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Netdot".

The branch, master has been updated
       via  92f5160f12dfcaec085cf506e47e476cf81a4e13 (commit)
       via  b8b053839e99fb022617a4ec74ef310a5ab0edb6 (commit)
       via  2dfeab5c261f5104dce72b092a895924eba6b627 (commit)
       via  0d4a8b1246c89aeb7c023a98a398790db0ae4eff (commit)
       via  81e67dd4f6139d2cb862a1b855a28c8547e36b16 (commit)
       via  c8fb4e5a2eaf376f582135e03c428f13158712ca (commit)
       via  3cfa3a0d69d41e758cfc68f4057f688f8ba33af2 (commit)
       via  0c8fe91e3a35f61d487dae7446f3dae069bc7d97 (commit)
      from  ca6e8bc97712d24650af4d0ebb25a3b9d57c3bbe (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 etc/netdot.meta                  |   12 ++++++------
 lib/Netdot/Exporter.pm           |   18 ++++++++++++++++++
 lib/Netdot/Exporter/BIND.pm      |    2 ++
 lib/Netdot/Exporter/Nagios.pm    |   18 +++++++++++++-----
 lib/Netdot/Exporter/Smokeping.pm |   11 ++++++++---
 lib/Netdot/Exporter/Sysmon.pm    |    3 ++-
 lib/Netdot/Model/Device.pm       |   11 +++++++----
 lib/Netdot/Model/DhcpScope.pm    |    2 ++
 8 files changed, 58 insertions(+), 19 deletions(-)


hooks/post-receive
-- 
Netdot


------------------------------

_______________________________________________
Netdot-devel mailing list
[email protected]
https://osl.uoregon.edu/mailman/listinfo/netdot-devel


End of Netdot-devel Digest, Vol 74, Issue 7
*******************************************

Reply via email to