ab -k -c 1 -n 400 -H "Accept: application/json" http://ghanozjson.ap01.aws.af.cm/events
This is ApacheBench, Version 2.3 <$Revision: 1373084 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
ab -k -c 500 -n 1000 -H "Accept: application/json" http://ghanozjson.ap01.aws.af.cm/events
This is ApacheBench, Version 2.3 <$Revision: 1373084 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/
Benchmarking ghanozjson.ap01.aws.af.cm (be patient)
apr_pollset_poll: The timeout specified has expired (70007)
Title: Event List request should return response in JSON
Client->Web API\nRouters: Request Event List\nwith max. 15 items on the list\n(Accept: application/json)
Note right of Web API\nRouters: Is requested\n format accepted?\nYes!
Web API\nRouters->Data Access: Get Event List
Note right of Data Access: Retrieve the actual\n data on DB
Data Access->Web API\nRouters: Return raw data
Note right of Web API\nRouters: Populate resource\n in JSON
Web API\nRouters->Client: Send response\n(Content-Type: application/json)
/** | |
* A middleware to check the requested content type. | |
*/ | |
module.exports.acceptedFormat = function () { | |
return function (req, res, next) { | |
res.format({ | |
'application/json': function () { | |
next(); |
Loosely ordered with the commands I use most towards the top. Sublime also offer full documentation.
Ctrl+C | copy current line (if no selection) |
Ctrl+X | cut current line (if no selection) |
Ctrl+⇧+K | delete line |
Ctrl+↩ | insert line after |
Currently, I interested to use Sublime Text to working on a Wordpress project. It seems a bit late if I just use Sublime Text lately. So today I'm googling to find the most useful Wordpress extension/plugin for Sublime Text 2 and here it is:
In step 0 I learn how the AngularJS use the ng-app directive to flag an element which Angular should consider to be the root element of our application. By doing this, it gives us a freedom to tell Angular if the entire html page or only a portion of it should be treated as the Angular application.
Example 1:
<!doctype html>
<html lang="en" ng-app>
<head>
the real nature of each AngularJS service; services are singletons, so there is only one instance of each service… and this allow to share data between different views, controller, directives, filters, and others services, without the need to overpopulate the global scope. http://blog.brunoscopelliti.com/deal-with-users-authentication-in-an-angularjs-web-app