<context:component-scan base-package="com.mangofactory.swagger.controllers"/>
<context:component-scan base-package="com.mangofactory.swagger.configuration"/>
<context:annotation-config/>
<mvc:default-servlet-handler/>
<context:property-placeholder location="classpath:swagger.properties"/>
Marty then has two beans declared from his test project, DocumentationConfig and CustomExtensibilityModule, but they don't compile with swagger-springmvc-0.8.3. I'm thinking I need to do something here rather than just comment out the beans. I'm just not sure what those beans are doing and if they really are required. I see it's annotated with @PostConstruct, what is supposed to call SwaggerApiResourceListing#initialize?
Any ideas?I just found that when I commented out this block in my spring config:
<mvc:annotation-driven>
<mvc:message-converters>
<bean class="org.springframework.http.converter.json.MappingJackson2HttpMessageConverter">
<property name="prettyPrint" value="true"/>
</bean>
</mvc:message-converters>
</mvc:annotation-driven>
... that I get a startup error saying "error creating bean with name "springSwaggerConfig" because no bean was found to satisfy its "handlerMappings" autowired field, of type org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping". On a whim, I created a bean of that type but then just got a different error.
So two things:
1. Is <mvc:annotation-driven/> not compatible with <context:annotation-config/>?
2. Assuming I can find another way to declare pretty print that works
with <mvc:annotation-driven/>, what handlerMapping should I be declaring?
So the more I work on this the more I think my problem is that the SwaggerApiResourceListing#initialize, annotated with @PostConstruct, is not called even though I'm using:
<context:annotation-config/>
Any ideas why?
Craig
--
You received this message because you are subscribed to the Google Groups "Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to swagger-swaggers...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.