[Design of Clustering on JBoss] - Re: JBAS-5703 - Make HA-JNDI use wait for first positive res
by bstansberry@jboss.com
"galder.zamarreno(a)jboss.com" wrote : Re: https://jira.jboss.org/jira/browse/JBAS-5703
|
| I've attached a patch containing fix for this. Few notes:
|
Great; thanks.
anonymous wrote : 1. I've tested this with a 3 node cluster (node1,node2 and node3) and two ejbs (ejbA and ejbB where ejbA calls ejbB via HAJNDI). Deployment wise, ejbA is deployed in node1 and ejbB is deployed in node3. I was able to make a call successfully via ejbA in node1 and was able to check via logs that once response from node3 was received, the lookup returned. Now, my question is, how to create a unit test around this? Not easy...
Testing can be done in layers:
a) Unit test your LookupSucceededFilter. That's really the key thing here.
b) Unit test RspFilterAdapter.
c) A test of ClusterPartition.callMethodOnCluster where ResponseFilter param is passed. One way to do that at least partially is to have a service that calls method public boolean echo(boolean arg), where response is whatever arg was. Call with a filter that only accepts "true". Invoke method twice, passing "true" then "false"; should get a response to first call, none to second call.
d) A full test of the HA-JNDI functionality. That can wait until we make ClusterPartition more of a POJO, something where a couple can be instantiated in a unit test the way JBC can. You can file a JIRA to add such a test.
anonymous wrote : 2. I noted this as a todo in the patch: ResponseFilter/RspFilter API: If needMoreResponses() took response and sender as well, class implementations could be Immutable and same instance could be passed to all lookups. As it is right now, they can't and new instances need to be generated for every lookup.
Having 2 methods lets you filter responses out of the response list while still accepting more responses. To get the same thing out of one method you'd have to change the return type to something beyond simple boolean, perhaps Boolean but better an enum. This would be a JGroups API change.
anonymous wrote : 3. Could response filtering done in ClusterPartition.processResponseList() be moved here? Any NoHandlerForRPC would be caught here immediately and could potentially avoid double processing. Thoughts?
Something to think about; could be done in RspFilterAdapter.
Hmm -- don't think it works well for the ordinary case where you want responses from everyone. To return properly from needMoreResponses() the RspFilterAdapter would have to know how many responses it is expecting and count how many it has gotten. And deal with suspicions/view changes that may occur in the meantime.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4223115#4223115
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4223115
17 years
[Design of Management Features on JBoss] - Re: JBAS-6672, null values and defaults
by scott.stark@jboss.org
"charles.crouch(a)jboss.com" wrote :
| So overall the most important thing is to have property.setRemoved() cause nothing to be persisted for the managed property, and that a default (if specified somewhere) is applied to the actual running instance. [This could just be letting the component itself choose the default, I don't think it has to come from the ManagedProperty annotation for CR1, though it would make sense in the future.] This is what I see as the core issue that needs resolving for CR1.
|
| If we don't have this function for managedproperty's which are primitives then that's not great, but I don't necessarily see it as a blocker since there probably not that many such properties.
That a removed property has no value applied to the metadata and the metadata simply defaults to a value will apply to all managed property types, including primitives. Is that the function you are questioning?
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4223090#4223090
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4223090
17 years
[Design of JBoss jBPM] - Re: jBPM 4 Email Question
by bradsdavis
>From my experience in the field, here are two features we should actively pursue.
1) Multiple email servers. Reason: a lot of companies have multiple SMTP servers. The reason is, generally one sends internally and one externally. I think we could accomplish this by having a configuration for the email servers in the mail configuration. This would be a list of servers, which could take simple domain filtering. For example servers could include "*jboss.org" and that would indicate the mail server can serve all jboss.org emails. We could also support pop or smtp mail pretty easily.
2) Email Attachments are often an interest for clients. An example would be sending an order in PDF format when the task to sign off on the order is produced.
We could create an email producer interface that we could use to make email producers plugable. It could take the environment context as a parameter, and return an email object [see apache email commons]. That would make the interface flexible enough to return either a simple text email, HTML email, or Multipart email with attachments.
The email producer that we could ship could target using jsr223 or velocity or freemarker. I have noticed all of those have been tossed around as possible templating.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4223089#4223089
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4223089
17 years