Skip to content

Commit

Permalink
Allow to specify good keys in smart vertex collections.
Browse files Browse the repository at this point in the history
  • Loading branch information
neunhoef committed Oct 21, 2016
1 parent cf0ffe5 commit 5e743a2
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 0 deletions.
1 change: 1 addition & 0 deletions js/common/bootstrap/errors.js
Expand Up @@ -262,6 +262,7 @@
"ERROR_NO_SMART_COLLECTION" : { "code" : 4000, "message" : "collection is not smart" },
"ERROR_NO_SMART_GRAPH_ATTRIBUTE" : { "code" : 4001, "message" : "smart graph attribute not given" },
"ERROR_CANNOT_DROP_SMART_COLLECTION" : { "code" : 4002, "message" : "cannot drop this smart collection" },
"ERROR_KEY_MUST_BE_PREFIXED_WITH_SMART_GRAPH_ATTRIBUTE" : { "code" : 4003, "message" : "in smart vertex collections _key must be prefixed with the value of the smart graph attribute" },
"ERROR_AGENCY_INFORM_MUST_BE_OBJECT" : { "code" : 20011, "message" : "Inform message must be an object." },
"ERROR_AGENCY_INFORM_MUST_CONTAIN_TERM" : { "code" : 20012, "message" : "Inform message must contain uint parameter 'term'" },
"ERROR_AGENCY_INFORM_MUST_CONTAIN_ID" : { "code" : 20013, "message" : "Inform message must contain string parameter 'id'" },
Expand Down
1 change: 1 addition & 0 deletions lib/Basics/errors.dat
Expand Up @@ -373,6 +373,7 @@ ERROR_MODULE_FAILURE,3103,"failed to invoke module","Failed to invoke the module
ERROR_NO_SMART_COLLECTION,4000,"collection is not smart","The requested collection needs to be smart, but it ain't"
ERROR_NO_SMART_GRAPH_ATTRIBUTE,4001,"smart graph attribute not given","The given document does not have the smart graph attribute set."
ERROR_CANNOT_DROP_SMART_COLLECTION,4002,"cannot drop this smart collection","This smart collection cannot be dropped, it dictates sharding in the graph."
ERROR_KEY_MUST_BE_PREFIXED_WITH_SMART_GRAPH_ATTRIBUTE,4003,"in smart vertex collections _key must be prefixed with the value of the smart graph attribute","In a smart vertex collection _key must be prefixed with the value of the smart graph attribute."

################################################################################
## Agency errors
Expand Down
1 change: 1 addition & 0 deletions lib/Basics/voc-errors.cpp
Expand Up @@ -258,6 +258,7 @@ void TRI_InitializeErrorMessages () {
REG_ERROR(ERROR_NO_SMART_COLLECTION, "collection is not smart");
REG_ERROR(ERROR_NO_SMART_GRAPH_ATTRIBUTE, "smart graph attribute not given");
REG_ERROR(ERROR_CANNOT_DROP_SMART_COLLECTION, "cannot drop this smart collection");
REG_ERROR(ERROR_KEY_MUST_BE_PREFIXED_WITH_SMART_GRAPH_ATTRIBUTE, "in smart vertex collections _key must be prefixed with the value of the smart graph attribute");
REG_ERROR(ERROR_AGENCY_INFORM_MUST_BE_OBJECT, "Inform message must be an object.");
REG_ERROR(ERROR_AGENCY_INFORM_MUST_CONTAIN_TERM, "Inform message must contain uint parameter 'term'");
REG_ERROR(ERROR_AGENCY_INFORM_MUST_CONTAIN_ID, "Inform message must contain string parameter 'id'");
Expand Down
15 changes: 15 additions & 0 deletions lib/Basics/voc-errors.h
Expand Up @@ -614,6 +614,9 @@
/// - 4002: @LIT{cannot drop this smart collection}
/// This smart collection cannot be dropped, it dictates sharding in the
/// graph.
/// - 4003: @LIT{in smart vertex collections _key must be prefixed with the value of the smart graph attribute}
/// In a smart vertex collection _key must be prefixed with the value of the
/// smart graph attribute.
/// - 20011: @LIT{Inform message must be an object.}
/// The inform message in the agency must be an object.
/// - 20012: @LIT{Inform message must contain uint parameter 'term'}
Expand Down Expand Up @@ -3254,6 +3257,18 @@ void TRI_InitializeErrorMessages ();

#define TRI_ERROR_CANNOT_DROP_SMART_COLLECTION (4002)

////////////////////////////////////////////////////////////////////////////////
/// @brief 4003: ERROR_KEY_MUST_BE_PREFIXED_WITH_SMART_GRAPH_ATTRIBUTE
///
/// in smart vertex collections _key must be prefixed with the value of the
/// smart graph attribute
///
/// In a smart vertex collection _key must be prefixed with the value of the
/// smart graph attribute.
////////////////////////////////////////////////////////////////////////////////

#define TRI_ERROR_KEY_MUST_BE_PREFIXED_WITH_SMART_GRAPH_ATTRIBUTE (4003)

////////////////////////////////////////////////////////////////////////////////
/// @brief 20011: ERROR_AGENCY_INFORM_MUST_BE_OBJECT
///
Expand Down

0 comments on commit 5e743a2

Please sign in to comment.