Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle Tx Recovery log bundle startup variations #5121

Merged
merged 2 commits into from Jan 29, 2019

Conversation

neilgsyoung
Copy link
Contributor

@neilgsyoung neilgsyoung commented Sep 18, 2018

fixes #5119

The Changes under this PR include:

1/ KEY CHANGE The TMRecoveryService class was introduced to support a new Declarative Service to break a potential circular reference between the TransactionManagerService and jdbc's DataSourceService which are mutually dependent.

The mutual dependency arises in the situation where the Transaction service is logging to an RDBMS. The DataSourceService (actually related Connection Manager Services) require a Transaction Manager, the Transaction Manager requires a DataSourceService through which to write its logs.

The new TMRecoveryService requires that the TransactionManagerService is available (as does the DataSourceService). Once it is available, Transaction Recovery can proceed as the DataSourceService can, if necessary be activated. Previously, intermittently, DS would attempt to activate the DataSourceService in the context of TransactionManagerService activation. That would fail with a DS Circular Reference error.

2/ Some classes have merely been reformatted. They were changed during the course of investigative work but the change to standard OL Java formatting is retained. The classes are,
SQLNonTransactionalDataSource.java, CustomLogProperties.java, FileSharedServerLeaseLog.java, RecoveryAgent.java, RecoveryLogManager.java, RecoveryLogManagerImpl.java, LocalTranTest.java, com.ibm.rls.jdbc.bnd

3/ There is a requirement to lookup the DS Services Registry during recovery (see XARecoveryDataHelper.lookupXAResourceFactory()). Any bundle context will do for the lookup so allow getBundleContext() method in TxTMHelper to be overridden in the EmbeddedTMHelper class in the ws.tx.embeddable bundle so that if that bundle has started before the tx.jta bundle then Services can be found. In testing, I found that sometimes the tx.jta bundle had not started wheras the ws.tx.embeddable bundle had started.

4/ Make TxTMHelper (and the ws.tx.embeddable bnd.bnd) the focus for DS Service availability for recovery, thus allowing it to control when recovery starts based on Service availability.

5/ Make RecLogServiceImpl the implementor of the DS RecoveryLog Service and allow it to determine that the Recoverylog bundle is ready to start recovery. Previously this was only part OSGi bundlerised and recovery could be started before the Recoverylog bundle had started.

6/ Add a new waitForRecovery test (note the flag is currently set to FALSE).

7/ Add the ported cloud sim FAT tests ported from Commercial Liberty.

@LibbyBot
Copy link

Code analysis and actions

DO NOT DELETE THIS COMMENT.
  • 22 product code files were changed.

  • Please describe in a separate comment how you tested your changes.

  • 1 FAT files were changed, added, or removed.

  • Check that the build did not break the affected FAT suite(s).

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_PaQIQLtTEeieisOzGH_nZQ

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

The build neilgsyoung-5121-20180918-1608
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_PaQIQLtTEeieisOzGH_nZQ
completed and has errors or failures.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_SWhwIMAJEei9re3pB293Wg

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

The build neilgsyoung-5121-20180924-1602
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_SWhwIMAJEei9re3pB293Wg
completed and has errors or failures.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_beJ-wMDUEei9re3pB293Wg

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

The build neilgsyoung-5121-20180925-1616
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_beJ-wMDUEei9re3pB293Wg
completed successfully!

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_AB2SAMGBEei9re3pB293Wg

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

The build neilgsyoung-5121-20180926-1250
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_AB2SAMGBEei9re3pB293Wg
completed and has errors or failures.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_Rs8QIMJEEei9re3pB293Wg

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

The build neilgsyoung-5121-20180927-1208
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_Rs8QIMJEEei9re3pB293Wg
completed and has errors or failures.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

LibbyBot commented Oct 2, 2018

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_XypgoMZWEeiA6ZPkBDHUqw

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

LibbyBot commented Oct 2, 2018

The build neilgsyoung-5121-20181002-1634
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_XypgoMZWEeiA6ZPkBDHUqw
completed and has errors or failures.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

LibbyBot commented Oct 2, 2018

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_QnyukMZ5EeiA6ZPkBDHUqw

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

LibbyBot commented Oct 2, 2018

The build neilgsyoung-5121-20181002-2034
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_QnyukMZ5EeiA6ZPkBDHUqw
completed and has errors or failures.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

LibbyBot commented Oct 3, 2018

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_FxejUMbcEeiA6ZPkBDHUqw

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

LibbyBot commented Oct 3, 2018

The build neilgsyoung-5121-20181003-0822
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_FxejUMbcEeiA6ZPkBDHUqw
completed and has errors or failures.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

LibbyBot commented Oct 3, 2018

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_Wj1qQMb9EeiA6ZPkBDHUqw

Target locations of links might be accessible only to IBM employees.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_34iBsAOQEemkvu7GUlsKfw

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

The build neilgsyoung-5121-20181219-1431
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_34iBsAOQEemkvu7GUlsKfw
completed and has errors or failures.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_3kD2oAPJEemkvu7GUlsKfw

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

The build neilgsyoung-5121-20181219-2115
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_3kD2oAPJEemkvu7GUlsKfw
completed and has errors or failures.

@neilgsyoung neilgsyoung force-pushed the 5119-txreclogbundles branch 2 times, most recently from ea6bfce to 3b8831d Compare December 20, 2018 13:46
@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_hu8e4ARVEemkvu7GUlsKfw

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

The build neilgsyoung-5121-20181220-1416
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_hu8e4ARVEemkvu7GUlsKfw
completed and has errors or failures.

@jonhawkes
Copy link
Member

#build

@LibbyBot
Copy link

LibbyBot commented Jan 2, 2019

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_VDr9UA5SEemzked6cGmzzw

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

LibbyBot commented Jan 2, 2019

The build neilgsyoung-5121-20190102-0702
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_VDr9UA5SEemzked6cGmzzw
completed and has errors or failures.

@LibbyBot
Copy link

LibbyBot commented Jan 3, 2019

The build neilgsyoung-5121-20190103-1229
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_3AQdsA9IEemzked6cGmzzw
completed and has errors or failures.

Copy link
Member

@jonhawkes jonhawkes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

None of the build failures are caused by anything touched by this PR.

@jonhawkes
Copy link
Member

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_H2-IMBo2EemsU9nTXOm12w

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

The build neilgsyoung-5121-20190117-1008
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_H2-IMBo2EemsU9nTXOm12w
completed and has errors or failures.

@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_FIBrAB4uEemxE4V1kbLZCQ

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

Your Open Liberty build results are at http://public.dhe.ibm.com/ibmdl/export/pub/software/openliberty/runtime/personal/_FIBrAB4uEemxE4V1kbLZCQ. There might be a brief delay before results are available.

More rework on data source access

even more rework of data source access

Rework data source access stage 4

Rework data source access stage 5

Rework data source access stage 6

Rework data source access stage 7

Rework data source access stage 8

Rework data source access stage 9

Rework data source access stage 10

Rework data source access stage 11

Rework data source access stage 12

Rework data source access stage 13

Rework data source access stage 14

Rework data source access stage 15

Rework tx bundle startup

Fix intermittent test issues and simplify JTMConfigurationProvider

move service ref activate to setDataSourceFactory method

correct unsetDataSourceFactory method
@neilgsyoung
Copy link
Contributor Author

#build

@LibbyBot
Copy link

Your personal build request is at https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_mA88MiAYEemxE4V1kbLZCQ

Target locations of links might be accessible only to IBM employees.

@LibbyBot
Copy link

Your Open Liberty build results are at http://public.dhe.ibm.com/ibmdl/export/pub/software/openliberty/runtime/personal/_mA88MiAYEemxE4V1kbLZCQ. There might be a brief delay before results are available.

@LibbyBot
Copy link

The build neilgsyoung-5121-20190124-2150
https://wasrtc.hursley.ibm.com:9443/jazz/resource/itemOid/com.ibm.team.build.BuildResult/_mA88MiAYEemxE4V1kbLZCQ
completed and has errors or failures.

@neilgsyoung neilgsyoung merged commit 2177d13 into OpenLiberty:integration Jan 29, 2019
@neilgsyoung neilgsyoung deleted the 5119-txreclogbundles branch January 29, 2019 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Transaction Recovery Log bundle startup sequence needs refinement
3 participants