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

avoid crawler to obtain a thread with a remanant context #2859

Closed
wants to merge 1 commit into from
Closed

avoid crawler to obtain a thread with a remanant context #2859

wants to merge 1 commit into from

Conversation

cmangeat
Copy link
Collaborator

@cmangeat cmangeat commented Jun 7, 2018

as team programmed

@cmangeat
Copy link
Collaborator Author

cmangeat commented Jun 7, 2018

@josegar74 @juanluisrp as said before.

@cmangeat
Copy link
Collaborator Author

Relates to #2827

@josegar74 josegar74 added this to the 3.4.3 milestone Jun 11, 2018
@josegar74 josegar74 requested a review from fxprunayre June 11, 2018 10:10
@josegar74
Copy link
Member

@fxprunayre as you worked in https://github.com/geonetwork/core-geonetwork/pull/2859/files#diff-104af28d3030368a152d64430caa944b, would you mind to take a look to the fix.

We tested using a threadpool size of 1 to reproduce easily the issue and without the fix the problem described by @cmangeat occurred, while with the fix worked fine.

Checked other cases, like using the new API services or Jeeves services not handled as a crawler requests and seemed fine as the Jeeves ServiceManager/new API managed to update the proper ServiceContext in the request threadpool.

@josegar74
Copy link
Member

@cmangeat can you make the PR to master branch instead of 3.4.x? We discussed to apply fixes first to master and the cherry-pick to 3.4.x. I'll manage about this, thanks.

@juanluisrp
Copy link
Contributor

juanluisrp commented Jun 15, 2018

Any idea about why the test are failing in Travis?

Running jeeves.server.dispatchers.ServiceManagerIntegratedTest
Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 56.402 sec <<< FAILURE! - in org.fao.geonet.DataManagerWorksWithoutTransactionIntegrationTest
testDataManagerCutpoints(org.fao.geonet.DataManagerWorksWithoutTransactionIntegrationTest)  Time elapsed: 15.088 sec  <<< FAILURE!
java.lang.AssertionError: null
	at org.junit.Assert.fail(Assert.java:92)
	at org.junit.Assert.assertTrue(Assert.java:43)
	at org.junit.Assert.assertTrue(Assert.java:54)
	at org.fao.geonet.GeonetTestFixture.assertRequiredSchemas(GeonetTestFixture.java:222)
	at org.fao.geonet.GeonetTestFixture.initSchemaManager(GeonetTestFixture.java:215)
	at org.fao.geonet.GeonetTestFixture.setup(GeonetTestFixture.java:138)
	at org.fao.geonet.AbstractCoreIntegrationTest.setup(AbstractCoreIntegrationTest.java:145)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
...
Running org.fao.geonet.kernel.AccessManagerTest
Tests run: 2, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 2.834 sec <<< FAILURE! - in org.fao.geonet.kernel.AccessManagerTest
testIsIntranetBackwardCompatibility(org.fao.geonet.kernel.AccessManagerTest)  Time elapsed: 2.192 sec  <<< ERROR!
java.lang.NullPointerException: null
	at org.fao.geonet.kernel.SchemaManager.configureFrom(SchemaManager.java:171)
	at org.fao.geonet.GeonetTestFixture.configureNewSchemaManager(GeonetTestFixture.java:189)
	at org.fao.geonet.GeonetTestFixture.setup(GeonetTestFixture.java:158)
	at org.fao.geonet.AbstractCoreIntegrationTest.setup(AbstractCoreIntegrationTest.java:145)
...

@cmangeat cmangeat closed this Jun 27, 2018
@cmangeat cmangeat deleted the avoid_crawler_to_reuse_others_user_session branch June 27, 2018 07:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants