atlas-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Apoorv Naik (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (ATLAS-1778) Incorrect error code returned in V2 APIs when updating an entity with invalid values using PUT/POST
Date Wed, 10 May 2017 22:24:04 GMT

     [ https://issues.apache.org/jira/browse/ATLAS-1778?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Apoorv Naik updated ATLAS-1778:
-------------------------------
    Attachment: 0001-ErrorCode-fixes-and-bad-request-when-invalid-attribu.patch

> Incorrect error code returned in V2 APIs when updating an entity with invalid values
using PUT/POST
> ---------------------------------------------------------------------------------------------------
>
>                 Key: ATLAS-1778
>                 URL: https://issues.apache.org/jira/browse/ATLAS-1778
>             Project: Atlas
>          Issue Type: Bug
>          Components:  atlas-core
>    Affects Versions: 0.8-incubating, 0.9-incubating
>            Reporter: Sharmadha Sainath
>            Assignee: Apoorv Naik
>         Attachments: 0001-ErrorCode-fixes-and-bad-request-when-invalid-attribu.patch
>
>
> Entity Update using PUT /POST with wrong values for attributes throws 404 Not Found exception
. Expected is 400 Bad Request .
> {code}
> curl -v -u  admin:admin -H "Content-Type: application/json" -d @entity.json -X POST "http://ctr-e133-1493418528701-6996-01-000006.hwx.site:21000/api/atlas/v2/entity"
> *   Trying 172.27.14.75...
> * Connected to ctr-e133-1493418528701-6996-01-000006.hwx.site (172.27.14.75) port 21000
(#0)
> * Server auth using Basic with user 'admin'
> > POST /api/atlas/v2/entity HTTP/1.1
> > Host: ctr-e133-1493418528701-6996-01-000006.hwx.site:21000
> > Authorization: Basic YWRtaW46YWRtaW4=
> > User-Agent: curl/7.43.0
> > Accept: */*
> > Content-Type: application/json
> > Content-Length: 937
> >
> * upload completely sent off: 937 out of 937 bytes
> < HTTP/1.1 404 Not Found
> < Date: Fri, 05 May 2017 06:09:21 GMT
> < Set-Cookie: ATLASSESSIONID=1e65za9f72n3n7dcxp6bsgf2o;Path=/;HttpOnly
> < Expires: Thu, 01 Jan 1970 00:00:00 GMT
> < X-Frame-Options: DENY
> < Content-Type: application/json; charset=UTF-8
> < Transfer-Encoding: chunked
> < Server: Jetty(9.2.12.v20150709)
> <
> * Connection #0 to host ctr-e133-1493418528701-6996-01-000006.hwx.site left intact
> {"errorCode":"ATLAS-404-00-007","errorMessage":"Invalid instance creation/updation parameters
passed : entity_type_VNsAA.type_date=str: invalid value for type date"}
> {code}
> *V1 APIs return 400 Bad Request*



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message