Git Product home page Git Product logo

netty-springmvc's Introduction

netty 集成 spring mvc

将netty的HttpRequest和HttpResponse对象与servlet的对象进行相互转换。我采用了springtest提供的用来模拟HttpServletRequest和HttpServletResponse的类,这两个类也是它们的子类。 org.springframework.mock.web.MockHttpServletRequest; org.springframework.mock.web.MockHttpServletResponse;

项目功能

  • 支持spring mvc的controller中,注解方式获取参数
  • 支持返回json
  • 支持post请求

如何测试

如何打包并发布

  • 使用maven打包:mvn package
  • 启动jar:java -jar target/Netty-SpringMVC-1.0.0-SNAPSHOT.jar
  • 浏览器访问 http://localhost:8080/hello/foo, 如果返回结果,表示启动成功

如何添加自己的业务

  • 在org.springframework.sandbox.mvc.TestController中,你可以添加自己的方法

待添加的功能

  • 热部署(Hot deployment)
  • 集群(cluster)

版本信息

  • 0.0.2 : 集成mybatis
  • 0.0.1 : 实现netty+springMVC的集成

netty-springmvc's People

Contributors

leiguorui avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.