GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - Dior222/thrift-spring

BranchesTags
Open more actions menu
 
 

Latest commit

 

History

17 Commits
17 Commits

Folders and files

NameName
Last commit message
Last commit date
src
src
 
 
README.md
README.md
 
 
pom.xml
pom.xml
 
 

Repository files navigation

thrift-spring

实现thrift服务端集成spring,采用TThreadPoolServer同步线程池做默认服务,传输协议采用默认的TBinaryProtocol 调用方式参考test中的示例 #集成spring步骤(参考test示例)
1)spring配置中配置

<context:component-scan base-package="com.upsoft.thrift"></context:component-scan>  
<bean class="com.xjkwq1qq.core.ThriftServiceApplication" />

2)在服务实现类上添加注解@ThriftService 如示例中所示:

@ThriftService("HelloService")
public class HelloServiceImpl implements HelloService.Iface {
	@Override
	public String getNode() throws TException {
		return "HelloWorld";
	}
}

3)thrift服务的端口配置 在配置文件thrift-spring.properties中设置

#port default 9090;
thrift.port=9091

如果不设置默认是9090端口 服务端便启动完成

About

No description, website, or topics provided.

Resources

Readme
Activity

Stars

1 star

Watchers

1 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.