[ 
https://issues.apache.org/jira/browse/FREEMARKER-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17289735#comment-17289735
 ] 

Dániel Dékány commented on FREEMARKER-177:
------------------------------------------

A possibility is just changing the return type of {{getSettings}} to 
{{Properties}}. (For that, we also should extend {{Properties}} to make a 
read-only version of it. Well, if we care that much, and maybe we shouldn't.)

I wonder if now the presence of {{setProperties(InputStream)}} will be a 
problem... Because these bean things tend to come up with some new corner cases 
time to time.

If everything else fails, there's still the possibility of providing explicit 
bean-info. (But then, some frameworks use their own ways of discovering bean 
properties, and might not implement the bean-info feature.)

> freemarker Configurable has a asymmetric settings get/set which causes spring 
> failure
> -------------------------------------------------------------------------------------
>
>                 Key: FREEMARKER-177
>                 URL: https://issues.apache.org/jira/browse/FREEMARKER-177
>             Project: Apache Freemarker
>          Issue Type: Bug
>    Affects Versions: 2.3.29
>            Reporter: Gray
>            Priority: Major
>         Attachments: trace.txt
>
>
> When I try to configure freemarker.template.Configuration in spring, it 
> throws the exception: 
> {{Caused by: org.springframework.beans.FatalBeanException: Failed to obtain 
> BeanInfo for class [freemarker.template.Configuration]; nested exception is 
> java.beans.IntrospectionException: type mismatch between read and write 
> methods}}
> The problem is that setSettings(...) takes a Properties and getSettings() 
> returns a Map.  The get has been deprecated forever.   Can it please be 
> fixed?  The alternative is having to do some spring hackery.
> See: [https://github.com/apache/freemarker/pull/74]
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to