[LNT] r306594 - Where possible, use plural names in API endpoints

Chris Matthews via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 28 13:45:02 PDT 2017


Author: cmatthews
Date: Wed Jun 28 13:45:02 2017
New Revision: 306594

URL: http://llvm.org/viewvc/llvm-project?rev=306594&view=rev
Log:
Where possible, use plural names in API endpoints

Modified:
    lnt/trunk/lnt/server/ui/api.py

Modified: lnt/trunk/lnt/server/ui/api.py
URL: http://llvm.org/viewvc/llvm-project/lnt/trunk/lnt/server/ui/api.py?rev=306594&r1=306593&r2=306594&view=diff
==============================================================================
--- lnt/trunk/lnt/server/ui/api.py (original)
+++ lnt/trunk/lnt/server/ui/api.py Wed Jun 28 13:45:02 2017
@@ -331,11 +331,11 @@ class Regression(Resource):
 
 
 def load_api_resources(api):
-    api.add_resource(Machines, ts_path("machines"))
-    api.add_resource(Machine, ts_path("machine/<int:machine_id>"))
-    api.add_resource(Runs, ts_path("run/<int:run_id>"))
+    api.add_resource(Machines, ts_path("machines/"))
+    api.add_resource(Machine, ts_path("machines/<machine_id>"))
+    api.add_resource(Runs, ts_path("runs/<int:run_id>"))
     api.add_resource(SampleData, ts_path("samples"))
-    api.add_resource(Order, ts_path("order/<int:order_id>"))
+    api.add_resource(Order, ts_path("orders/<int:order_id>"))
     graph_url = "graph/<int:machine_id>/<int:test_id>/<int:field_index>"
     api.add_resource(Graph, ts_path(graph_url))
     regression_url = "regression/<int:machine_id>/<int:test_id>/<int:field_index>"




More information about the llvm-commits mailing list