Jsoup으로 xml 열심히 파싱하고 있었는데...텍스트 파일 하나가 1.2G.. MemoryOutOfException이 발생하여 검색을 하니 StAX(Streaming API for XML) 를 쓰면 해결이 될거라고...다만 StAX로 다하려니 파싱해서 데이터 넣기가 너무 불편해 ㅠㅠ 블록별로 변수에 넣어서 Jsoup으로 파싱! 결과적으론 1.2G 끄떡없다! ㅎㅎ 윤나무27정동화28...public static void data() {XMLInputFactory xmlInputFactory = XMLInputFactory.newInstance();try {String file = "data/bigFile.xml";XMLEventReader eventReader = xmlInputFactory.creat..
spring에서는 application.propertiesspring.datasource.url=jdbc:mysql://localhost:3306/sample?uniCode=true&characterEncoding=utf8 python에서는 import pymysqlconn = pymysql.connect(host='localhost', port=3306, user='root', passwd='password', db='sample')cur = conn.cursor()cur.execute("select current_timestamp() from dual")print(cur.fetchone())cur.close() conn.close()
MySql 설치하느라 이렇게 고생할 줄이야...... dmg로 깔고 지우고 깔고 지우고 homebew로 깔고 지우고 다시 깔고... 윈도우에 프로그램 관리가 그리워진...... osx el-capitan에서는 homebrew로 설치하세요! (하위버전은 안써봐서 뭐라 할말이... ) ※ homebrew란? http://brew.sh/index_ko.html $ brew install mysql $ sudo mysql -uroot$ unset TMPDIR $ mysql_install_db --verbose --user=`whoami` --basedir="$(brew --prefix mysql)" --datadir=/usr/local/var/mysql --tmpdir=/tmp$ mysql.server star..
- Total
- Today
- Yesterday
- tomcat
- 서버 환경변수
- timestamp
- could not initialize proxy - no Session
- JoinColumn
- ojdbc7
- StAX
- cloudsearch 비용
- Python
- 계층형
- JPA
- aws cloudsearch
- JPA 오류
- CloudSearch
- 단축키
- db connect
- #csvreader
- iTerm
- OneToMany
- org.hibernate.LazyInitializationException
- 엘라스틱서치
- Big xml 파싱
- oracle12
- Elasticsearch
- getdate
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |