[Logo] Terracotta Discussion Forums (LEGACY READ-ONLY ARCHIVE)
  [Search] Search   [Recent Topics] Recent Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
[Expert]
Messages posted by: Admin  XML
Profile for Admin -> Messages posted by Admin [57] Go to Page: 1, 2, 3, 4 Next 
Author Message
This Licensing Forum and the other Terracotta forums (collectively, "the Forums") provide answers to commonly asked questions related to the Terracotta Public License ("TPL"). Content in the Forums regarding the TPL is provided for informational purposes only. It is not part of, nor does it modify, amend, or supplement the terms of the TPL. The TPL is a legal agreement that governs the rights granted with respect to material licensed under it, so please read it carefully. If there is any conflict between any content in the Forums and the TPL, the terms of the TPL shall govern. Content in the Forums should not be regarded as legal advice. If you need legal advice, you should contact your own attorney.
Note:

This FAQ is specifically intended for the Spring implementation of Terracotta which is built on top of Terracotta DSO. If you have DSO specific questions, you should read the DSO FAQ

For the most comprehensive list of answers to Frequently asked questions, please review the official FAQ. You can also find help to common problems by using the Troubleshooting Guide



============================================================
Q. Where do I get Terracotta?


A. From the .org site, listed below.

Org Site: http://www.terracotta.org
Download: http://wiki.terracotta.org/confluence/display/orgsite/Download

============================================================
Q. How much does Terracotta cost?


A. Terracotta is open source which means it is available for free. An enterprise version of Terracotta is available which provides Enterprise levels of support, for more details see http://www.terracottatech.com

============================================================
Q. Can Terracotta cluster standalone Spring applications, or just web apps?


A. Terracotta supports Spring whether standalone or as a web app.

============================================================
END OF FAQ


PLEASE EMAIL support@terracotta.org if you could not find an answer to your question.
Note:

This FAQ is specifically intended for the Sessions implementation of Terracotta which is built on top of Terracotta DSO. If you have DSO specific questions, you should read the DSO FAQ

For the most comprehensive list of answers to Frequently asked questions, please review the official FAQ. You can also find help to common problems by using the Troubleshooting Guide



============================================================
Q. Where do I get Terracotta?


A. From the .org site, listed below.

Org Site: http://www.terracotta.org
Download: http://wiki.terracotta.org/confluence/display/orgsite/Download

============================================================
Q. How much does Terracotta cost?


A. Terracotta is open source which means it is available for free. An enterprise version of Terracotta is available which provides Enterprise levels of support, for more details see http://www.terracottatech.com

============================================================
Q. What is the best place for me to get started?


A. Terracotta comes with sample applications and Tomcat pre-bundled.

1. Download the product
2. Run the welcome application
3. Select the "Sessions" tab
4. Run the configurator application to see sample web apps running with Tomcat and Terracotta

============================================================
Q. I've seen the sample applications, how do I install Terracotta for...


A. Tomcat:
http://www.terracotta.org/confluence/display/docs1/Troubleshooting+Guide#TroubleshootingGuide-HowdoIuseTCSessionswithTomcat%3F

A. JBoss Application Server:
http://www.terracotta.org/confluence/display/docs1/Troubleshooting+Guide#TroubleshootingGuide-HowdoIuseTCSessionswithJBossApplicationServer%3F

A. WebLogic Application Server:
http://www.terracotta.org/confluence/display/docs1/Troubleshooting+Guide#TroubleshootingGuide-HowdoIuseTCSessionswithWebLogicApplicationServer%3F

A. WebSphere Application Server:
WAS Support is coming in Terracotta Version 2.4! Stay tuned...


============================================================
END OF FAQ


PLEASE EMAIL support@terracotta.org if you could not find an answer to your question.
For the most comprehensive list of answers to Frequently asked questions, please review the official FAQ. You can also find help to common problems by using the Troubleshooting Guide
============================================================
Q. What is DSO?

Terracotta DSO is advanced distributed-computing technology aimed at meeting special clustering requirements.

============================================================
Q. Do I need DSO to run a Terracotta Server Array?

No. Terracotta products without the overhead and complexity of DSO meet the needs of almost every use case and clustering requirement. The standard Terracotta Server Array is faster, simpler, more flexible, and has many more features than DSO. To find documentation on non-DSO (standard) Terracotta products, see the Terracotta Documentation.

============================================================
Q. What should I do if I'm already using DSO?

If you are already using DSO but would like to migrate to standard Terracotta products, see Migrating From Terracotta DSO.

============================================================
END OF FAQ


PLEASE EMAIL support@terracotta.org if you could not find an answer to your question.


Bill,

Thank you for the above updates. I am basically trying to explore the features of DSO and see the extent of their flexibility.

Issue1: Not sure why all the change listeners are being notified of all the changes in cluster... wouldnt this result to more chattiness?? May be some sort of mapping between the objects in cluster and change listeners would be reasonable... or may be not if there is some other reason behind the actual functionality

Issue3: Again, I cant see a reason why DSO internal objects changes are being treated same as the user object changes? Would this be of any help? Would you please update on this.

Issue4: Yes Bill. I get the point that change listeners are not needed for the changes to roots to be propagated through the cluster. Again, as I said, I am just trying different things.

Thanks Again!!
tc,

Thanks for sending me your config file and your sample code. Looking at your config, you have specified the same field as both a root and a change listener. There's nothing specifically in the documentation about it, but that isn't supported. I'll request a documentation change to mention it.

The original intent of the change listener functionality was to allow a change listener to be notified of object changes so that business data in a database can be updated accordingly. From your sample code, it isn't immediately clear why you need to use either the change listener feature or the distributed method invocation feature-- unless you are just testing out these features.

Perhaps you could tell me a little more about what you are trying to accomplish with the change listener feature?

In general, the best way to use DSO is to write your application as if it were a plain multi-threaded application.

Let me go through your questions in detail:

Issue 1:

The answer to this question is that all of the change listener objects in the change listener collection are notified of every change that happens in the entire cluster.

Issue 2:

You have definitely exercised a bug in the change listener functionality. If a transaction is committed without any changes in it (which can happen if there are waits or notifies in the transaction but no object changes), the assertion error you cited will be thrown. We're working on a fix for it now.

Issue 3:

DSO uses distributed objects internally. Because all of the change listener objects are notified of every change, they will be notified of the DSO internal object changes as well as the user object changes.

Issue 4:

If I understand your question correctly, you want to be able to update the object that is also a change listener based on the contents of the change notification. You don't need to have a change listener for changes to distributed objects to propagate through the cluster. Again, if you could describe what you are looking to accomplish using the change listener, I might be of more assistance.

_________________
Bill Chever
Product Support Manager
Terracotta, Inc.
stc,

We think that part of the problem you are encountering maybe a bug, but at this point we are not certain. There is also a question of how you are using the changeListener and DMI features.

Can I request you send the xml config file for this application, and if possible, a code example of what you are trying to accomplish?

You can send them directly to me rather than attaching them here.

wchever@terracottatech.com

Thanks!

_________________
Bill Chever
Product Support Manager
Terracotta, Inc.
Hi,

I am trying to test the change listeners and DMI features of DSO.

I just created three roots of which root1 is List<obj1> and has distributed method. root2 is Collection<obj2> and has change listener and root3 is List<obj2>.

I declared the change listener only for root2 but not root3 in tc-config.xml.

Here are the issues which I am not clear of why they are happening:

1. When I add obj2 to root3, change listener is inovked ???

2. When I call the distributed method of root1 for the first time, change listener of obj2 is invoked and the below exception is thrown

com.tc.util.TCAssertionError: Assertion failed: No changes present
at com.tc.util.Assert.failure(Assert.java:39)
at com.tc.util.Assert.eval(Assert.java:48)
at com.tc.object.tx.ClientTransactionManagerImpl.fireChangeEvent(ClientTransactionManagerImpl.java:344)
at com.tc.object.tx.ClientTransactionManagerImpl.commit(ClientTransactionManagerImpl.java:252)
at com.tc.object.tx.ClientTransactionManagerImpl.commit(ClientTransactionManagerImpl.java:207)
at com.tc.object.event.DistributedMethodCallManagerImpl.commit(DistributedMethodCallManagerImpl.java:161)
at com.tc.object.event.DistributedMethodCallManagerImpl.distributedInvoke(DistributedMethodCallManagerImpl.java:92)
at com.tc.object.bytecode.ManagerImpl.distributedInvoke(ManagerImpl.java:463)
at com.tc.object.bytecode.ManagerImpl.distributedMethodCall(ManagerImpl.java:371)
at com.tc.object.bytecode.ManagerUtil.distributedMethodCall(ManagerUtil.java:74)

3. When I call the distributed method of root1 for the first time, change listener of obj2 is invoked 2/3 times before the actual distributed method is invoked ???

4. As per the TC Product Guide (page28) contract for root2 (declared as above), which is enabled as a change listener, my app should not call any methods other than the add and remove. If that is the case, how would I be able to change the objects already added to the Collection??? so that the changeListener method is invoked??? In trying to do this, when I iterated through the collection using the Iterator, TC doesnt throw any exceptions... If I understand correctly, when the contract says that the app should not call any other methods other than add() and remove() and the app is trying to call something else, then I guess that TC should through some sort of exception (UnSupportedOperationException)....

Any clarifications of the above questions would be greatly appreciated.

Thank You
- stc
stc,

Yes, the Java util classes are special cases that cannot be named locked. Instead of placing the write lock on the actual add method of the java.util.ArrayList class, put the lock on the methods that are calling the add().

Bill

_________________
Bill Chever
Product Support Manager
Terracotta, Inc.
am trying to test the clustering of List objects. So, I declared a List object as a shared root in my class and is trying to add some objects to the ArrayList. But, I get the following exception inspite of declaring a named write lock on add() method (or infact all the methods) of ArrayList....

Exception in thread "main" com.tc.object.tx.UnlockedSharedObjectException: Thread [main] has attempted to access a shared object (an instance of java.util.ArrayList) without first getting a shared lock. Please specifiy a lock for this access via your Terracotta configuration
at com.tc.object.tx.ClientTransactionManagerImpl.getTransaction(ClientTransactionManagerImpl.java:185)
at com.tc.object.tx.ClientTransactionManagerImpl.logicalInvoke(ClientTransactionManagerImpl.java:465)
at com.tc.object.TCObjectImpl.logicalInvoke(TCObjectImpl.java:261)
at com.tc.object.bytecode.ManagerImpl.logicalInvoke(ManagerImpl.java:390)
at com.tc.object.bytecode.ManagerUtil.logicalInvoke(ManagerUtil.java:70)
at java.util.ArrayList.add(ArrayList.java)

would this be because of TC using its own ArrayList as part of its instrumented classes???
Please help on what is causing this...

Thank You in advance
-stc
axwack,

Yes, we do propagate ONLY the object changes at the field level.

Can you explain more about what you are looking for in terms of "pure messaging like semantics"?

_________________
Bill Chever
Product Support Manager
Terracotta, Inc.
I'm looking at a solution that is able to do more pure messaging like semantics. Can you do delta propgation at a field level?
Hi Patrick,

Thank you for the update. I thought that I tried setting <honor-transient> to true before. Well, I did this again and it works now.

Thank You!!!
Hi. Very sorry about that - the tutorial is actually missing a critical step. We're working on getting a new version of it posted soon.

In the meantime, you can workaround it by simply editing this part of the configuration:

<include>
<class-expression>javax.swing.DefaultBoundedRangeModel</class-expression>
<honor-transient>false</honor-transient>
</include>

to be like this:

<include>
<class-expression>javax.swing.DefaultBoundedRangeModel</class-expression>
<honor-transient>true</honor-transient>
<call-constructor-on-load>true</call-constructor-on-load>
</include>

The short explanation that there are some listeners in the range model that are getting shared which should not be - setting <hone-transient> to true ensures that this happens.

As I say, we're fixing the tutorial to add the step that tells you to configure this. Sorry for confusion, and let me know if there's anything else I can do to help.

Cheers,
-p

_________________
Patrick Calahan
Director, Product Management
Terracotta, Inc.
just started to look into TC-DSO and is trying to build and run the slider demo. I did follow the steps given in eclipse plugin DSO tutorial. But, when I try to run the demo, I get an exception when I run the second client as TC-DSO application. Not sure where exactly I went wrong...

Exception and config file details are as below and the code is same as the one in the DSO tutorial:

Exception in thread "main" java.lang.NullPointerException
at javax.swing.DefaultBoundedRangeModel.addChangeListener(Unknown Source)
at javax.swing.JSlider.setModel(Unknown Source)
at javax.swing.JSlider.<init>(Unknown Source)
at demo.Slider.<init>(Slider.java:18)
at demo.Slider.main(Slider.java:11)

<con:tc-config xmlns:con="http://www.terracottatech.com/config-v1">
<system>
<configuration-model>development</configuration-model>
<dso-enabled>true</dso-enabled>
<jdbc-enabled>false</jdbc-enabled>
</system>
<servers>
<server name="localhost">
<dso-port>9510</dso-port>
<jmx-port>9520</jmx-port>
<http-port>9515</http-port>
<data>terracotta/server-data</data>
<logs>terracotta/server-logs</logs>
</server>
</servers>
<clients>
<logs>terracotta/client-logs</logs>
</clients>
<application>
<dso>
<instrumented-classes>
<include>
<class-expression>demo.Slider</class-expression>
<honor-transient>false</honor-transient>
</include>
<include>
<class-expression>javax.swing.DefaultBoundedRangeModel</class-expression>
<honor-transient>false</honor-transient>
</include>
</instrumented-classes>
<additional-boot-jar-classes>
<include>javax.swing.DefaultBoundedRangeModel</include>
</additional-boot-jar-classes>
<roots>
<root>
<field-name>demo.Slider.rangeModel</field-name>
</root>
</roots>
<locks>
<named-lock>
<method-expression>void javax.swing.DefaultBoundedRangeModel.setRangeProperties(int, int, int, int, boolean)</method-expression>
<lock-name>NewLock</lock-name>
<lock-level>write</lock-level>
</named-lock>
</locks>
<distributed-methods>
<method-expression>void javax.swing.DefaultBoundedRangeModel.fireStateChanged()</method-expression>
</distributed-methods>
<transient-fields>
<field-name>javax.swing.DefaultBoundedRangeModel.listenerList</field-name>
</transient-fields>
</dso>
</application>
</con:tc-config>

Thanks in advance for any help!!!
 
Profile for Admin -> Messages posted by Admin [57] Go to Page: 1, 2, 3, 4 Next 
Go to:   
Powered by JForum 2.1.7 © JForum Team