@RequestMapping("/updatescore.do")
	public String updateScore(@RequestParam String date) {
		String baseUrl = "http://mobile.9188.com/zlk/jsbf/jc/onerounddata/%s.xml?rn=1000";
		HttpClient client = new DefaultHttpClient();
		HttpGet request = null;
		int maxSize = 500;
		for (int i = 1; i < maxSize; i++) {
			String id = date + getFormatString(i);
			System.out.println(id);
			Match match = matchMapper.selectMatch(Integer.parseInt(id));
			if (match==null) {
				break;
			}
			if (match != null && match.getClose() == null) {
				String url = String.format(baseUrl, id);
				System.out.println(url);
				request = new HttpGet(url);
				HttpResponse response = null;
				try {
					response = client.execute(request);
					int statusCode = response.getStatusLine().getStatusCode();
					if (statusCode != HttpStatus.SC_OK) {
						System.out.println("request " + url + " failed");
						break;
					}
					InputStream input = response.getEntity().getContent();
					String content = IOUtils.toString(input);
					System.out.println(content);
					ScoreHandler handler = new ScoreHandler();
					XMLReader reader = XMLReaderFactory.createXMLReader();
					reader.setContentHandler(handler);
					// reader.parse(content);
					reader.parse(new InputSource(new StringReader(content)));
					String half = handler.getHalf();
					String close = handler.getClose();
					matchMapper.updateBifen(half, close, Integer.parseInt(id));
				} catch (IOException e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				} catch (SAXException e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
			}
		}
		return "success";
	}