[aerogear-dev] [aerogear-controller] Configuration

Daniel Bevenius daniel.bevenius at gmail.com
Tue Nov 13 11:15:20 EST 2012


To help clarify the options here the following gist contains examples of
the two suggestions provided so far:
https://gist.github.com/4066691




On 13 November 2012 16:49, Daniel Bevenius <daniel.bevenius at gmail.com>wrote:

> >i dislike xml configuration files,  so i would vote for an Annotation.
> Yeah, I agree and we are avoiding any xml right now.
> So, how about we provide some hopefully good defaults for CORS and then
> users can provide there own @Producer. We will provide at builder api to
> create the config instance so it won't be a lot of work for users.
>
> Should CORS be enabled by default?
>
>
> On 13 November 2012 13:35, Lucas Holmquist <lholmqui at redhat.com> wrote:
>
>>
>> On Nov 13, 2012, at 4:18 AM, Daniel Bevenius <daniel.bevenius at gmail.com>
>> wrote:
>>
>> I'm working on adding CORS support there are several things that can be
>> configured in this case. Below is an example of the options that are
>> currently available:
>>
>> public interface CorsConfiguration {
>>
>>     public abstract boolean isCorsSupportEnabled();
>>
>>     public abstract boolean exposeHeaders();
>>
>>     public abstract String getExposeHeaders();
>>
>>     public abstract boolean anyOrigin();
>>
>>     public abstract boolean allowCookies();
>>
>>     public abstract boolean hasMaxAge();
>>
>>     public abstract long getMaxAge();
>>
>>     public abstract Set<String> getValidRequestMethods();
>>
>>     public abstract Set<String> getValidRequestHeaders();
>>
>> }
>>
>> How do we want users to configure these configuration options? Using a
>> CDI annotation with "sensible" default values or specify them in web.xml?
>>
>>
>> i dislike xml configuration files,  so i would vote for an Annotation.
>>  but thats personal preference
>>
>>
>> cheers,
>>
>> /Dan
>>
>>
>>
>> _______________________________________________
>> aerogear-dev mailing list
>> aerogear-dev at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/aerogear-dev
>>
>>
>>
>> _______________________________________________
>> aerogear-dev mailing list
>> aerogear-dev at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/aerogear-dev
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/aerogear-dev/attachments/20121113/6df74538/attachment-0001.html 


More information about the aerogear-dev mailing list