블로그 이미지

calendar

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 31
  • total
  • today
  • yesterday
2023. 3. 21. 09:50 JAVA오픈소스/Spring
posted by 천상의날개
2022. 8. 23. 14:59 JAVA오픈소스/Spring

  ApplicationContextProvider  
  

  사용법  
  

posted by 천상의날개
2022. 7. 19. 16:33 JAVA오픈소스/Spring

(String) request.getAttribute("javax.servlet.forward.request_uri")

posted by 천상의날개
2020. 7. 13. 16:34 JAVA오픈소스/Spring

HttpServletRequest req = ((ServletRequestAttributes)RequestContextHolder.getRequestAttributes()).getRequest();

 

http://dveamer.github.io/backend/SpringRequestContextHolder.html

posted by 천상의날개
2020. 5. 28. 16:24 JAVA오픈소스/Spring

로깅할 문자의 {}에 차례대로 값이 들어감

logger.info("test:{} test1:{}","testlg","testlg1")

결과 : test : testlg test1:testlg1

posted by 천상의날개
2020. 1. 17. 17:59 JAVA오픈소스
posted by 천상의날개
2016. 12. 20. 15:34 JAVA오픈소스/Spring

public String test(HttpServletRequest request, Model model, @RequestParam MultiValueMap<String, Object> multiParams){

List<Object> ischks = multiParams.get("ischk");
for(int i=0; i < ischks.size() ; i++){

String testCd = multiParams.get("test_cd").get(i);

}

}

posted by 천상의날개
2016. 3. 25. 17:30 JAVA오픈소스/mybatis
플러그인 소스
spring context xml 설정
http://javafactory.tistory.com/entry/Mybatis%EC%9D%98-PlugIn%EC%9D%84-%EC%9D%B4%EC%9A%A9%ED%95%9C-SQL%EB%AC%B8-%ED%8C%8C%EB%9D%BC%EB%AF%B8%ED%84%B0-%EB%B0%94%EC%9D%B8%EB%94%A9-%EB%A1%9C%EA%B7%B8-%EC%B6%9C%EB%A0%A5 참조

'JAVA오픈소스 > mybatis' 카테고리의 다른 글

마이바티스 프로시져 사용법  (0) 2015.11.18
posted by 천상의날개
2016. 1. 28. 15:46 JAVA오픈소스/Spring
ApplicationContextManager java
application-context.xml 에 추가
사용법
posted by 천상의날개
2015. 12. 4. 15:18 JAVA오픈소스/Spring

Multiple Transaction Managers with @Transactional

Most Spring applications only need a single transaction manager, but there may be situations where you want multiple independent transaction managers in a single application. The value attribute of the @Transactional annotation can be used to optionally specify the identity of the PlatformTransactionManager to be used. This can either be the bean name or the qualifier value of the transaction manager bean. For example, using the qualifier notation, the following Java code

public class TransactionalService {

    @Transactional("order")
    public void setSomething(String name) { ... }

    @Transactional("account")
    public void doSomething() { ... }
}

could be combined with the following transaction manager bean declarations in the application context.

<tx:annotation-driven/>

    <bean id="transactionManager1" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
        ...
        <qualifier value="order"/>
    </bean>

    <bean id="transactionManager2" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
        ...
        <qualifier value="account"/>
    </bean>

In this case, the two methods on TransactionalService will run under separate transaction managers, differentiated by the "order" and "account" qualifiers. The default <tx:annotation-driven> target bean name transactionManager will still be used if no specifically qualified PlatformTransactionManager bean is found.

 

참조 URL : https://www.lesstif.com/pages/viewpage.action?pageId=20774954

posted by 천상의날개