Details
-
Bug
-
Resolution: Duplicate
-
Medium
-
None
-
4.4
-
4.04
-
Description
If a gadget subcription is not reachable by JIRA, JIRA will not be able to load the gadget directory. There is no other way to delete a gadget subscription other than from the gadget directory itself (oops!)
Steps to reproduce
- In JIRA instance A, add gadget subscription, say http://localhost:8090
- Export JIRA instance A to XML
- In JIRA instance B, restore XML backup from instance A. Make sure instance A is not reachable from instance B (important to reproduce this problem)
- In JIRA instance B, try adding gadget to dashboard. JIRA will throw browser prompt:
The Gadget Directory failed to load
Diagnosis:
- Set "com.atlassian.gadgets.directory" logging to DEBUG
- Reproduce, the following stack trace appears in log:
2012-01-06 09:46:24,529 TP-Processor8 DEBUG testuser 583x1195x3 1dymzqi 211.24.247.39,207.223.247.45 /rest/config/1.0/directory.json [gadgets.directory.internal.HttpCache$1] ThreadSafeClientConnManager.getConnection: HttpRoute[{}->http://localhost:8090], timeout = 0 2012-01-06 09:46:24,528 TP-Processor12 DEBUG testuser 580x1121x2 1dymzqi 211.24.247.39,207.223.247.45 /rest/config/1.0/directory.json [gadgets.directory.internal.GadgetSpecProviderHelper$GadgetSpecProviderToEntriesFunction] Unable to get the contents of the GadgetSpecProvider org.codehaus.httpcache4j.HTTPException: org.apache.http.conn.HttpHostConnectException: Connection to http://localhost:8090 refused at org.codehaus.httpcache4j.cache.HTTPCache.handleResolve(HTTPCache.java:178) at org.codehaus.httpcache4j.cache.HTTPCache.unconditionalResolve(HTTPCache.java:167) at org.codehaus.httpcache4j.cache.HTTPCache.getFromCache(HTTPCache.java:144) at org.codehaus.httpcache4j.cache.HTTPCache.doCachedRequest(HTTPCache.java:104) at org.codehaus.httpcache4j.cache.HTTPCache.doCachedRequest(HTTPCache.java:80) at com.atlassian.gadgets.directory.internal.GadgetFeedsSpecProvider$FeedSpecProvider$LazyFeedReference.create(GadgetFeedsSpecProvider.java:351)
Workaround
Delete the subscription from the database
delete from propertystring where id = (select id from propertyentry where property_key = 'com.atlassian.gadgets.directory.SubscribedGadgetFeedStore'); delete from propertyentry where property_key = 'com.atlassian.gadgets.directory.SubscribedGadgetFeedStore';
Attachments
Issue Links
- duplicates
-
JRASERVER-24979 The gadget directory code will wait forever on the gadget provider and this can hang the ability to add gadgets
- Closed