Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change in syntax for URI param 'q' #1751

Closed
kzangeli opened this issue Feb 2, 2016 · 6 comments
Closed

Change in syntax for URI param 'q' #1751

kzangeli opened this issue Feb 2, 2016 · 6 comments
Assignees
Labels
Milestone

Comments

@kzangeli
Copy link
Member

kzangeli commented Feb 2, 2016

Attribute Exists & Not Exists, right now use '+' and '-' in the URI param 'q':

GET /v2/entities?q=+attr1;-attr2

However, the '+' is decoded to a SPACE by MHD and a decision has been made to change the syntaxis, using 'no prefix' for EXISTS and '!' for NOT EXISTS:

GET /v2/entities?q=attr1;!attr2

We also use '+/-' for TYPE EXISTS:

GET /v2/entities?q=+type

That syntaxis must be changed the same way, to:

GET /v2/entities?q=type       # Get entities that have a type
GET /v2/entities?q=!type      # Get entities that DO NOT have a type

Actions to be taken:

  1. Change the source code (qStringFilters in MongoGlobal.cpp)
  2. Modify existing functests that use the old syntaxis
  3. (if not fully covered), new functests
  4. Modify documentation (.apib ngsiv2), including changing examples in the doc using the old syntax

Related issues:
#1589
#1587

@kzangeli kzangeli self-assigned this Feb 2, 2016
@kzangeli kzangeli added this to the 0.28.0 milestone Feb 2, 2016
@fgalan
Copy link
Member

fgalan commented Feb 2, 2016

Maybe #1587 is also related (at least partially)

@fgalan
Copy link
Member

fgalan commented Feb 2, 2016

In addition, after completing this issue the following .test need to be enabled (after modifications):

  • 1587_q_query_has_type/q_query_has_type.test
  • 1589_query_entities_with_specific_attributes/query_entities_with_specific_attributes.test.pending1675.DISABLED

@fgalan
Copy link
Member

fgalan commented Feb 4, 2016

Fixed by PR #1756 (mainly) and #1760 (two disabled .test).

@fgalan fgalan closed this as completed Feb 4, 2016
@iariasleon iariasleon modified the milestones: QATestPending, 0.28.0 Apr 4, 2016
@iariasleon
Copy link
Contributor

Reopen because is pending to test by QA

@iariasleon iariasleon reopened this Apr 4, 2016
@iariasleon
Copy link
Contributor

LGTM

@fgalan fgalan modified the milestones: 0.28.0, QATestPending Jul 20, 2016
@fgalan
Copy link
Member

fgalan commented Jul 20, 2016

Changed milestone to 0.28.0, the one in which this will really fixed (see https://github.com/telefonicaid/fiware-orion/releases/tag/0.28.0 and look for "1751").

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants