dev@glassfish.java.net

Re: Network config questions

From: Kim Haase <Camilla.Haase_at_Sun.COM>
Date: Tue, 28 Jul 2009 16:20:55 -0400

On 07/28/09 15:05, Justin Lee wrote:
> Kim Haase wrote:
>> I'm working on the GFv3 Admin Console online help for network
>> configuration and related elements -- network listeners, protocols,
>> thread pools, virtual servers. June Parks's draft of the Domain File
>> Format Reference, available at
>> http://wiki.glassfish.java.net/Wiki.jsp?page=AdministrationReference,
>> has been extremely helpful. However, I'm wondering about what order an
>> administrator needs to create these objects in.
>>
>> The draft Domain File Format Reference entry on the protocol attribute
>> of the network-listener element is a bit confusing -- it says,
>>
>> "Specifies the name of the protocol associated with this network
>> listener. Although this attribute is required, a protocol is
>> automatically created with the same name as the network listener when
>> you use the asadmin create-http-listener command to create a network
>> listener."
>>
>> Actually the command to create a network listener is of course
>> create-network-listener, and it does not seem to create a protocol
>> automatically. Should it? (Whether it should or not, there are some
>> ramifications both for the command line and the Admin Console, but I
>> can file issues depending on what ought to happen.)
>>
>> So if you want to create a network listener, do you have to create a
>> protocol first? Do you have to have a unique protocol for each network
>> listener and vice versa? This seems to be the case for the ones that
>> are created by default.
>>
> There are actually 2 different ways to create a network listener. The
> comment in June's document is correct. create-http-listener will create
> the required referenced elements. This command was kept around and
> refitted for the new layout to preserve compatibility with v2. The new
> command create-network-listener as you've correctly noted does *not*
> create these elements and they must be created first. Note that there
> will almost never be a reason to run create-threadpool as in almost all
> cases, you'll want to use an existing thread pool definition.

Thanks very much, Justin, for clarifying all this.

I was wondering about thread pools, actually. I see there are by default
2 created: http-thread-pool with a limit on the number of threads in the
queue and a small max pool size, and thread-pool-1 with no limit on the
queue threads and a large max pool size. The 3 default network listeners
all use http-thread-pool. Under what circumstances might a user specify
the other one?

>> Also, is it correct that a virtual server is normally associated with
>> one or more network listeners, but that you can create a virtual
>> server that isn't associated with any network listener, then create
>> the network listener, then edit the virtual server to specify that
>> network listener?
> That is correct. Though it'd save you a step to create the
> network-listener first, I'd think.

Thanks, that may be worth mentioning. I notice the Admin Guide doesn't
cover this area just yet -- probably this kind of information is worth
including there, too.

So with the Admin Console anyway, you'd want to create a protocol,
create a network listener, then create a virtual server that uses the
network listener.

Kim

>>
>> Thanks very much,
>> Kim Haase
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
>> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>