---
title: "启动多个线程测试 代码中的"
author: "程序员是怎么炼成的"
date: "2015-10-16T16:27:40Z"
tags: []
categories: ["编程语言"]
slug: "untitled"
draft: false
lastmod: "2015-10-16T16:27:40Z"
id: 2249668
url: "https://95028410.iteye.com/blog/2249668"
---

- public static void main(String\[] args) {
- ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("application-root-bean.xml");
- final InfluxTransactionWS influxTransactionWS = (InfluxTransactionWS) context.getBean("influxTransactionWS");
- for (int i = 0; i &lt; 400; i++) {
- final int t=i;
- new Thread()
- {
- //调用业务代码
- }.start();
- }
- }