Skip to content

Commit

Permalink
[#10077] Remove duplicate spring beans.
Browse files Browse the repository at this point in the history
  • Loading branch information
emeroad committed Jun 26, 2023
1 parent 545dcca commit faf3b35
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 37 deletions.
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
package com.navercorp.pinpoint.common.server;

import com.navercorp.pinpoint.common.server.bo.codec.stat.AgentStatDataPointCodec;
import com.navercorp.pinpoint.common.server.bo.serializer.stat.config.AgentStatSerializeConfiguration;
import com.navercorp.pinpoint.common.server.bo.serializer.stat.config.ApplicationStatSerializeConfiguration;
import com.navercorp.pinpoint.common.server.bo.serializer.trace.v2.config.SpanSerializeConfiguration;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
Expand All @@ -22,10 +20,5 @@
"com.navercorp.pinpoint.common.server.dao.hbase.mapper",
})
public class CommonsHbaseConfiguration {
@Bean
public AgentStatDataPointCodec agentStatDataPointCodec() {
return new AgentStatDataPointCodec();
}


}
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,10 @@
"com.navercorp.pinpoint.web.mapper",
"com.navercorp.pinpoint.web.filter",
"com.navercorp.pinpoint.web.view",
"com.navercorp.pinpoint.web.applicationmap"
"com.navercorp.pinpoint.web.applicationmap",

"com.navercorp.pinpoint.web.controller",
"com.navercorp.pinpoint.web.util"
})
public class PinpointWebModule {
@Bean
Expand Down
3 changes: 2 additions & 1 deletion web/src/main/resources/application.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
spring:
main:
allow-bean-definition-overriding: true
allow-bean-definition-overriding: false
mvc:
pathmatch:
matching-strategy: ant_path_matcher
use-suffix-pattern: true
profiles:
active: release

Expand Down
6 changes: 0 additions & 6 deletions web/src/main/resources/applicationContext-web.xml
Original file line number Diff line number Diff line change
Expand Up @@ -38,19 +38,13 @@
</constructor-arg>
</bean>

<bean id="agentEventMessageDeserializerV1" class="com.navercorp.pinpoint.common.server.util.AgentEventMessageDeserializerV1"/>


<bean id="annotationKeyRegistryService" class="com.navercorp.pinpoint.loader.service.DefaultAnnotationKeyRegistryService">
<constructor-arg ref="typeLoaderService"/>
</bean>

<bean id="apiParserProvider" class="com.navercorp.pinpoint.common.server.trace.ApiParserProvider">
</bean>

<bean id="spanServiceImpl" class="com.navercorp.pinpoint.web.service.SpanServiceImpl">
</bean>

<bean id="hbaseSqlMetaDataDao" class="com.navercorp.pinpoint.web.dao.hbase.HbaseSqlMetaDataDao">
</bean>

Expand Down
22 changes: 0 additions & 22 deletions web/src/main/resources/servlet-context-web.xml
Original file line number Diff line number Diff line change
@@ -1,32 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:tx="http://www.springframework.org/schema/tx"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd
http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc.xsd">

<mvc:annotation-driven>
<!--
Turn off useSuffixPatternMatching by default
https://github.com/spring-projects/spring-framework/issues/23915
-->
<mvc:path-matching suffix-pattern="true"/>
</mvc:annotation-driven>

<tx:annotation-driven/>

<context:component-scan base-package="com.navercorp.pinpoint.web.controller, com.navercorp.pinpoint.web.util"/>

<bean id="jsonView" class="org.springframework.web.servlet.view.json.MappingJackson2JsonView"/>

<bean id="viewResolver" class="org.springframework.web.servlet.view.BeanNameViewResolver"/>

<bean class="org.springframework.web.servlet.view.InternalResourceViewResolver"/>

<mvc:interceptors>
<bean id="webContentInterceptor" class="org.springframework.web.servlet.mvc.WebContentInterceptor">
<property name="cacheSeconds" value="0"/>
Expand Down

0 comments on commit faf3b35

Please sign in to comment.