1
0
mirror of https://github.com/kataras/iris.git synced 2026-01-13 15:05:57 +00:00

Commit Graph

  • 254a4ede95 add explanation why the 'globalVisitorsController' example is a Singleton, because it was not clear for new gophers previously. Gerasimos (Makis) Maropoulos 2017-12-20 18:09:31 +02:00
  • 2042fddb66 Another new feature: websocket controller, for real Gerasimos (Makis) Maropoulos 2017-12-20 17:56:28 +02:00
  • b78698f6c0 fix all _examples to the newest mvc, add comments to those examples and add a package-level .Configure in order to make it easier for new users. Add a deprecated panic if app.Controller is used with a small tutorial and future resource link so they can re-write their mvc app's definitions Gerasimos (Makis) Maropoulos 2017-12-20 08:33:53 +02:00
  • fd0f3ed6cb fix check for singleton on fillStruct - no problem let's set all the static values on the first value although it may never be needed if request-scoped/stateless (No Singleton di.State) Gerasimos (Makis) Maropoulos 2017-12-20 00:09:17 +02:00
  • 6285622cfa controller's struct: if unexported field(s) is set-ed manually (binder cannot do that) and no other dynamic dependency(depends on context) then tag the controller as singleton, use a single controller instance to serve all clients (the controller's methods are per-request of course but its(controller's) fields will be 'global'- users should be careful because parallel access of those fields are up to them by using mutex or atomic or values that are safe for concurrent access. Gerasimos (Makis) Maropoulos 2017-12-20 00:01:50 +02:00
  • c15763c556 ok make it cleaner, it's working well and blazing fast but I have to do a lot cleaning and commenting and docs as well before push it to master --- hope at christmas day, also thinking some internal ideas - the whole code is not ready to be readen by a third person yet. Gerasimos (Makis) Maropoulos 2017-12-19 23:40:42 +02:00
  • 5d08049ac6 Merge pull request #843 Gerasimos (Makis) Maropoulos 2017-12-19 15:00:12 +02:00
  • 43444ebe12 Merge pull request #845 Gerasimos (Makis) Maropoulos 2017-12-19 14:57:40 +02:00
  • fef59c4c0b Merge commit '67341251b8439e2064b3f8cc987313822bed23d0 [formerly c88b33d218dadc9f2e9b60366c39ba2049e68e3b]' into wing Wing Gao 2017-12-18 20:11:28 +08:00
  • 835e2f8c08 fix another minor typo Cody Oss 2017-12-18 00:25:57 -06:00
  • 4261b5784a Merge branch 'master' into dev Gerasimos (Makis) Maropoulos 2017-12-18 07:28:52 +02:00
  • 67341251b8 Be prepared, 2018 is the year of Iris. Note on README Gerasimos (Makis) Maropoulos 2017-12-18 07:28:38 +02:00
  • d95304148e Merge branch 'master' into dev Gerasimos (Makis) Maropoulos 2017-12-18 07:25:00 +02:00
  • d88e49abaf Last year we had HTTP/2 at Christmas, this year I will give you even better gift Gerasimos (Makis) Maropoulos 2017-12-18 07:22:55 +02:00
  • 20ba72aecf fix typo Gerasimos (Makis) Maropoulos 2017-12-18 06:47:05 +02:00
  • e4aa414add fix a typo Cody Oss 2017-12-17 21:45:11 -06:00
  • 4fb46bf1f3 fix mvc/ideas/1/main.go->AfterActivation Gerasimos (Makis) Maropoulos 2017-12-18 02:24:53 +02:00
  • d5a38a0cd6 more checks about creating new instance of controller on each request - this time if all bindings are static then set them to the initial-devpassed controller and if the total number of lengths are equal with these static dependencies then we ignore the injector and use the initial controller on each request - maximize the performance when simple controller is used - need more cleanup before new release but I hope until Christmas iris developers will be amazed Gerasimos (Makis) Maropoulos 2017-12-18 00:16:10 +02:00
  • 40b40fa7d3 don't create new controller instance when all fields are set-ed by the end-dev - but we keep show those fields' values as Dependencies on the BeforeActivate in order to the future custom controllers authors to be able to check if something is added as dependecy or even manually set-ed before bind their own dependecies, otherwise they could override the manually set-ing Gerasimos (Makis) Maropoulos 2017-12-17 06:34:16 +02:00
  • 6120e755e8 update mvc/README.md Gerasimos (Makis) Maropoulos 2017-12-16 23:27:04 +02:00
  • e67621b8ec grammar fixes(?) Gerasimos (Makis) Maropoulos 2017-12-16 23:12:49 +02:00
  • 68cc6641d4 Add session.Destroy (before I've added: Increment & Decrement entry helpers as well) | Improve the debug messages for the controllers Gerasimos (Makis) Maropoulos 2017-12-16 23:09:00 +02:00
  • b8cafce6b9 add simple tests for _examples/mvc/hello-world and session-controller Gerasimos (Makis) Maropoulos 2017-12-16 21:27:20 +02:00
  • a25c0557de don't create a new controller instance if it doesn't have struct dependencies and the fields length is 0 - 0.4MB/s difference from the raw handlers now. Gerasimos (Makis) Maropoulos 2017-12-16 17:57:20 +02:00
  • 34664aa311 OK, my dream-idea is implemented. TODO: Some examples and doc.go is not updated yet, comments on the mvc/di subpackage, the tutorial/vuejs-todo-mvc is running but not finished yet (it's using browser's localstorage and it should be replaced by the http requests that are registered via iris mvc Gerasimos (Makis) Maropoulos 2017-12-16 06:38:28 +02:00
  • 55dfd195e0 remove the old 'mvc' folder - examples are not changed yet - add the 'di' package inside the mvc2 package - which will be renamed to 'mvc' on the next commit - new mvc.Application and some dublications removed - The new version will be version 9 because it will contain breaking changes (not to the end-developer's controllers but to the API they register them) - get ready for 'Christmas Edition' for believers Gerasimos (Makis) Maropoulos 2017-12-15 20:28:06 +02:00
  • c6b12ab754 need a better way to replace an existed cookie Wing Gao 2017-12-15 22:42:18 +08:00
  • 859a62bf01 fix cookie expire equals to -1 when call UpdateExpiration Wing Gao 2017-12-15 21:46:18 +08:00
  • 4e15f4ea88 create one generic package for dependency injection which can be used outside of Iris too - worked but unfished Gerasimos (Makis) Maropoulos 2017-12-14 23:04:42 +02:00
  • a5fac270cf Merge branch 'master' into dev Gerasimos (Makis) Maropoulos 2017-12-14 14:21:03 +02:00
  • 434b07675e add example for the simple context#WriteGzip Gerasimos (Makis) Maropoulos 2017-12-14 14:15:29 +02:00
  • 3349fd5c91 Merge branch 'master' into dev Gerasimos (Makis) Maropoulos 2017-12-14 06:16:01 +02:00
  • 22504f01ef add a simple hero template example as requested at https://github.com/kataras/iris/issues/840 Gerasimos (Makis) Maropoulos 2017-12-14 06:11:37 +02:00
  • 0b2dcc76f5 start of the vue + mvc example and a simple session binding Gerasimos (Makis) Maropoulos 2017-12-14 05:56:23 +02:00
  • d72c649441 add test for binding a whole function as an input argument on the handler's function - worked Gerasimos (Makis) Maropoulos 2017-12-14 03:30:39 +02:00
  • 43c330f338 Merge branch 'master' into dev Gerasimos (Makis) Maropoulos 2017-12-13 14:46:45 +02:00
  • ea863914dc update the vendor json library which is used when 'WithOptimizations' passed on 'app.Run' and resolve https://github.com/kataras/iris/pull/839#issuecomment-351374343 Gerasimos (Makis) Maropoulos 2017-12-13 14:37:02 +02:00
  • 8dcbdc0741 performance close to handlers if no bindings but even if bindings except service (new feature is that we can bind functions as well) is x1.1 faster than the previous mvc implementation - make BaseController (so and C) optionally but not break the existing APIs that using iris.C or mvc.C Gerasimos (Makis) Maropoulos 2017-12-13 06:17:28 +02:00
  • 257f1318c9 add some comments but I just released that we may not need controller's input field and we can bind directly via the targetStruct binder, next step is to implement that behavior Gerasimos (Makis) Maropoulos 2017-12-12 14:33:39 +02:00
  • 689b671bf9 split the controller's method lexer and parser to another file to simplify the code, we need more steps to simplify it enough before pushing to master Gerasimos (Makis) Maropoulos 2017-12-11 06:51:52 +02:00
  • 297c581e30 add an overview of the new semantics at the mvc2/README.md Gerasimos (Makis) Maropoulos 2017-12-11 06:24:55 +02:00
  • aa18b62f64 add a ridiculous simple 'context#String' func which will return a very simple string representatin of the current request Gerasimos (Makis) Maropoulos 2017-12-10 07:26:01 +02:00
  • ed79f0c3cd ok the new mvc system works great, all tests done and almost x3 smaller LOC used plus new three awesome features:) - next commit will be commenting out and replace the mvc package with the new mvc2 Gerasimos (Makis) Maropoulos 2017-12-10 07:00:51 +02:00
  • e02da3d442 Add context#IsMobile kataras 2017-12-04 08:13:45 +02:00
  • 20f68416a7 add context#IsMobile kataras 2017-12-04 08:12:34 +02:00
  • 2d80d73ad7 Merge branch 'master' into dev kataras 2017-12-04 05:08:10 +02:00
  • a7b2a90e3b cm kataras 2017-12-04 05:08:05 +02:00
  • 7043f352d9 made it work but looking for another approach kataras 2017-12-04 05:06:03 +02:00
  • 27097df7b4 Merge pull request #828 from honux/master Gerasimos (Makis) Maropoulos 2017-12-04 04:59:15 +02:00
  • c15b7725da Merge pull request #2 from honux/honux-patch-2 honux 2017-12-03 23:21:46 -02:00
  • 412c513e5f Fix subfolder templating issue honux 2017-12-03 23:21:11 -02:00
  • 3dd9854e70 Merge pull request #1 from honux/honux-patch-1 honux 2017-12-02 18:02:39 -02:00
  • 9197fd7349 Fixed a bug on router/path honux 2017-12-02 17:45:43 -02:00
  • 988cb2cab6 Merge pull request #826 from jerson/patch-7 Gerasimos (Makis) Maropoulos 2017-12-02 16:20:10 +02:00
  • 80b86136f4 Websocket: added OnPing to Connection Gerson Alexander Pardo Gamez 2017-12-01 17:48:37 -05:00
  • dd5de52f34 implement a way to add controller functions as handlers with the existing rules respected but it's a bit dirty I will change the implementation and move the mvc2 to mvc and make the api builder's PartyFunc to be a critical part of the controller and the mvc2.Mvc bind values should be also respected to the controller and more kataras 2017-11-27 21:39:57 +02:00
  • 9d63e3194f implement a simple path param binder kataras 2017-11-25 14:04:35 +02:00
  • 4818d184b1 remove codesponsor as http://mailchi.mp/f9b57b5ea377/code-sponsor-is-shutting-down-on-december-8 kataras 2017-11-24 20:13:10 +02:00
  • 2448a60e04 remove codesponsor as http://mailchi.mp/f9b57b5ea377/code-sponsor-is-shutting-down-on-december-8 kataras 2017-11-24 20:11:32 +02:00
  • 5a3be2ab58 simplify by join the bind registration(ctx-transformer-to-something-func-binder and service one, which just sets the struct as it's) to one named 'In' and create a 'Child' which will return a new mvc instance with binders inheritanced from the parent one and add a simple test to the mvc_test.go - will have more later on kataras 2017-11-24 17:34:35 +02:00
  • 29835d9a8e black-box the MakeHandler, works perfectly. kataras 2017-11-24 15:10:30 +02:00
  • bfec1d174f implement the makeHandler and structure the high-level mvc's API kataras 2017-11-24 12:32:35 +02:00
  • 3a46102d4d I, think, that binders are done, both dynamic functions with different results every time (based on the context) and static services (interface as input(to give the devs the chance make better and most testable code) and struct or both are structs) kataras 2017-11-23 22:36:47 +02:00
  • de69b2fba2 start the new mvc - binder kataras 2017-11-23 12:43:29 +02:00
  • 907ba28f84 give some more control over request params and their entries for the end-developers kataras 2017-11-23 12:30:13 +02:00
  • 56871ce4d7 update test to cover the multi files per language new feature - requested at: https://github.com/kataras/iris/issues/815 kataras 2017-11-22 01:08:26 +02:00
  • 42e7faec52 update the vendor of the new iris-contrib/i18n to support multi locale files as requested at: https://github.com/kataras/iris/issues/815 kataras 2017-11-22 01:01:45 +02:00
  • 53ed4f3a4e add support for multi languages, without change the API, separated by commas as requested at: https://github.com/kataras/iris/issues/815 kataras 2017-11-22 00:57:29 +02:00
  • f16d398136 Merge pull request #819 from speedwheel/patch-3 Gerasimos (Makis) Maropoulos 2017-11-21 11:42:42 +02:00
  • b46b32be87 Merge pull request #818 from speedwheel/patch-2 Gerasimos (Makis) Maropoulos 2017-11-21 11:42:27 +02:00
  • 8d659d3589 move csrf middleware example kataras 2017-11-21 11:38:55 +02:00
  • 1a595d4ece update benchmarks and use throng on expressjs for better performance Gerasimos (Makis) Maropoulos 2017-11-21 11:35:31 +02:00
  • 006a09f68a update benchmarks and use throng on expressjs for better performance-- 21 Nov 2017 with linux ubuntu and latest mainline kernel 4.14 kataras 2017-11-21 11:34:04 +02:00
  • c745a028d9 Update README.md Edward Marinescu 2017-11-20 20:16:59 +02:00
  • c16d1c476c Update CONTRIBUTING.md Edward Marinescu 2017-11-20 20:15:22 +02:00
  • d1cc5599b6 Fix NodeJS benchmark Quentin Homareau 2017-11-19 13:02:48 +01:00
  • f4b4742eca Merge pull request #811 from PPACI/patch-1 Gerasimos (Makis) Maropoulos 2017-11-18 09:52:04 +02:00
  • 8d0ba9a0d0 more example in example Pierre PACI 2017-11-17 21:22:27 +01:00
  • 3b572eb23b Add an example for CSRF Protection kataras 2017-11-14 10:48:57 +02:00
  • e67346b459 Merge pull request #808 from speedwheel/patch-1 Gerasimos (Makis) Maropoulos 2017-11-10 20:09:39 +02:00
  • 9c07ab3f03 Rename README_CN.md to README_ZH.md Edward Marinescu 2017-11-10 20:05:54 +02:00
  • b32583c004 Merge branch 'master' of https://github.com/kataras/iris kataras 2017-11-10 16:16:08 +02:00
  • 9640f59961 app. SPA from router wrapper to a simple handler, works faster now. Iris' router respects wildcards with other paths as well (unique) for almost a half year now... so we don't need a whole wrapper for those things anymore, fixes https://github.com/kataras/iris/issues/807 kataras 2017-11-10 16:15:47 +02:00
  • 65cda65c6f Merge pull request #806 from yale8848/master Gerasimos (Makis) Maropoulos 2017-11-10 14:01:30 +02:00
  • 3b8553cd28 Update README_CN.md Yale 2017-11-10 15:19:10 +08:00
  • 9e668b30ea Update README_CN.md Yale 2017-11-10 15:14:38 +08:00
  • 346cd1ffc2 Update README_CN.md Yale 2017-11-10 15:10:45 +08:00
  • ccf5cc4d5e Update README_CN.md Yale 2017-11-10 14:50:00 +08:00
  • 1110bec979 Update README_CN.md Yale 2017-11-10 14:45:51 +08:00
  • a7f62c94f1 Update README_CN.md Yale 2017-11-10 14:40:30 +08:00
  • abba1ca4a0 Update README_CN.md Yale 2017-11-10 14:30:07 +08:00
  • 79a9b67a85 Update README_CN.md Yale 2017-11-10 14:22:14 +08:00
  • 512f7c3cf1 Update README_CN.md Yale 2017-11-10 12:06:48 +08:00
  • bae8cad58e Update README_CN.md Yale 2017-11-10 12:05:04 +08:00
  • 8d33fd670e Update README_CN.md Yale 2017-11-10 12:01:43 +08:00
  • c963e91cea Update README_CN.md Yale 2017-11-10 11:44:20 +08:00
  • d9708e1dc3 Update README_CN.md Yale 2017-11-10 10:29:10 +08:00
  • 91a02b7bac Update README_CN.md Yale 2017-11-09 21:08:36 +08:00
  • d6b2a68734 Update README_CN.md Yale 2017-11-09 20:57:03 +08:00
  • f971686123 Update README_CN.md Yale 2017-11-09 20:40:59 +08:00