Issue Details (XML | Word | Printable)

Key: COMMUNITY_EQUITY-316
Type: Sub-task Sub-task
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: cygnusecks1
Reporter: PRE
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
community-equity
COMMUNITY_EQUITY-272

can the feedtype automatically deteced (e.g. ATOM or Activity Streams)

Created: 16/Oct/09 05:06 PM   Updated: 15/Feb/10 10:25 AM   Resolved: 17/Dec/09 09:24 PM
Component/s: None
Affects Version/s: None
Fix Version/s: Milestone 1.3

Time Tracking:
Not Specified

Tags:


 Description  « Hide

I was reading an activtiy streams with the ATOM setting and get enclosed error.
Could the feed not automatically detect if its an ATOM or an Activity stream feed?
Error
SELECT PERSON_ID, ATTRIBUTES, CQ, PERSON_KEY, PQ, GIVEN_NAME, PEQ, E_MAIL, CREATED_ON, HOMEPAGE, UPDATED_ON, SURNAME, PICTURE_URL, SCREEN_NAME, COUNTRY_CODE FROM PERSON WHERE (LOWER(E_MAIL) = ?)
bind => [pre@anonymous]
Array index out of range: 0
java.lang.ArrayIndexOutOfBoundsException: Array index out of range: 0
at org.apache.abdera.parser.stax.util.FOMList.get(FOMList.java:83)
at com.sun.ceq.session.AtomFeedProcessor.processEntry(AtomFeedProcessor.java:292)
at com.sun.ceq.session.AtomFeedProcessor.processFeed(AtomFeedProcessor.java:157)
at com.sun.ceq.session.FeedServiceImpl.updateFeed(FeedServiceImpl.java:411)
at com.sun.ceq.session.FeedServiceImpl.timeoutHandler(FeedServiceImpl.java:388)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.sun.enterprise.security.application.EJBSecurityManager.runMethod(EJBSecurityManager.java:1011)
at com.sun.enterprise.security.SecurityUtil.invoke(SecurityUtil.java:175)
at com.sun.ejb.containers.BaseContainer.invokeTargetBeanMethod(BaseContainer.java:2920)
at com.sun.ejb.containers.BaseContainer.callEJBTimeout(BaseContainer.java:2849)
at com.sun.ejb.containers.EJBTimerService.deliverTimeout(EJBTimerService.java:1401)
at com.sun.ejb.containers.EJBTimerService.access$100(EJBTimerService.java:99)
at com.sun.ejb.containers.EJBTimerService$TaskExpiredWork.run(EJBTimerService.java:1952)
at com.sun.ejb.containers.EJBTimerService$TaskExpiredWork.service(EJBTimerService.java:1948)
at com.sun.ejb.containers.util.WorkAdapter.doWork(WorkAdapter.java:75)
at com.sun.corba.ee.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:555)
UPDATE PERSON SET UPDATED_ON = ? WHERE (PERSON_ID = ?)
bind => [2009-10-16 19:02:37.656, 4]
SELECT PERSON_ID, ATTRIBUTES, CQ, PERSON_KEY, PQ, GIVEN_NAME, PEQ, E_MAIL, CREATED_ON, HOMEPAGE, UPDATED_ON, SURNAME, PICTURE_URL, SCREEN_NAME, COUNTRY_CODE FROM PERSON WHERE (LOWER(PERSON_KEY) = ?)
bind => [admin]
SELECT t0.INFORMATION_ID, t0.INFORMATION_IQB, t0.INFORMATION_PQ, t0.AUTHOR_ID, t0.INFORMATION_PQK, t0.INFORMATION_IQK, t0.INFORMATION_PQB, t0.INFORMATION_IQ, t0.INFORMATION_STATUS, t0.INFORMATION_TYPE_ID, t1.INFORMATION_ID, t1.DESCRIPTION, t1.RATING, t1.INFORMATION_KEY, t1.RATING_COUNT, t1.TITLE, t1.VIEW_COUNT, t1.DOWNLOAD_COUNT, t1.URL, t1.CREATED_ON, t1.ARCHIVED, t1.UPDATED_ON, t1.UPDATED_BY, t1.INFORMATION_TYPE_ID, t1.APPLICATION_NAME, t1.MAIN_AUTHOR_ID, t1.PARENT_INFORMATION_ID FROM INFORMATION t1 LEFT OUTER JOIN PERSON_INFORMATION t2 ON (t2.INFORMATION_ID = t1.INFORMATION_ID) LEFT OUTER JOIN USER_GROUP_INFORMATION t3 ON (t3.INFORMATION_ID = t1.INFORMATION_ID) LEFT OUTER JOIN COMMUNITY_INFORMATION t4 ON (t4.INFORMATION_ID = t1.INFORMATION_ID), INFORMATION_CEQ t0 WHERE ((t1.INFORMATION_ID = t0.INFORMATION_ID) AND ((((t2.PERSON_ID = ?) OR t3.USER_GROUP_ID IN (SELECT t5.USER_GROUP_ID FROM PERSON_USER_GROUP t5 WHERE (NOT ((t5.ACR IS NULL)) AND (t5.PERSON_ID = ?)))) OR t4.COMMUNITY_ID IN (SELECT t6.COMMUNITY_ID FROM PERSON_COMMUNITY t6 WHERE (NOT ((t6.ACR IS NULL)) AND (t6.PERSON_ID = ?)))) OR t4.COMMUNITY_ID IN (SELECT t7.COMMUNITY_ID FROM PERSON_USER_GROUP t9, PERSON_USER_GROUP t8, USER_GROUP_COMMUNITY t7 WHERE ((((t8.USER_GROUP_ID = t7.USER_GROUP_ID) AND NOT ((t8.ACR IS NULL))) AND (t9.PERSON_ID = ?)) AND NOT ((t7.ACR IS NULL)))))) ORDER BY t1.CREATED_ON DESC
bind => [1, 1, 1, 1]
SELECT COUNT(t0.INFORMATION_ID) FROM INFORMATION t0 LEFT OUTER JOIN PERSON_INFORMATION t1 ON (t1.INFORMATION_ID = t0.INFORMATION_ID) LEFT OUTER JOIN USER_GROUP_INFORMATION t2 ON (t2.INFORMATION_ID = t0.INFORMATION_ID) LEFT OUTER JOIN COMMUNITY_INFORMATION t3 ON (t3.INFORMATION_ID = t0.INFORMATION_ID) WHERE ((((t1.PERSON_ID = ?) OR t2.USER_GROUP_ID IN (SELECT t4.USER_GROUP_ID FROM PERSON_USER_GROUP t4 WHERE (NOT ((t4.ACR IS NULL)) AND (t4.PERSON_ID = ?)))) OR t3.COMMUNITY_ID IN (SELECT t5.COMMUNITY_ID FROM PERSON_COMMUNITY t5 WHERE (NOT ((t5.ACR IS NULL)) AND (t5.PERSON_ID = ?)))) OR t3.COMMUNITY_ID IN (SELECT t6.COMMUNITY_ID FROM PERSON_USER_GROUP t8, PERSON_USER_GROUP t7, USER_GROUP_COMMUNITY t6 WHERE ((((t7.USER_GROUP_ID = t6.USER_GROUP_ID) AND NOT ((t7.ACR IS NULL))) AND (t8.PERSON_ID = ?)) AND NOT ((t6.ACR IS NULL)))))
bind => [1, 1, 1, 1]
SELECT FEED_ID, UPDATE_INTERVAL, DEFAULT_AUTHOR_E_MAIL, FEED_URL, LAST_UPDATED, DEFAULT_TAGS, LAST_ENTRY_DATE, TITLE, CREATED_ON, ENABLED, UPDATED_ON, FEED_TYPE, APPLICATION_NAME FROM FEED WHERE (ENABLED = ?)
bind => [true]
SELECT PERSON_ID, ATTRIBUTES, CQ, PERSON_KEY, PQ, GIVEN_NAME, PEQ, E_MAIL, CREATED_ON, HOMEPAGE, UPDATED_ON, SURNAME, PICTURE_URL, SCREEN_NAME, COUNTRY_CODE FROM PERSON WHERE (LOWER(E_MAIL) = ?)
bind => [pre@anonymous]
Array index out of range: 0
java.lang.ArrayIndexOutOfBoundsException: Array index out of range: 0
at org.apache.abdera.parser.stax.util.FOMList.get(FOMList.java:83)
at com.sun.ceq.session.AtomFeedProcessor.processEntry(AtomFeedProcessor.java:292)
at com.sun.ceq.session.AtomFeedProcessor.processFeed(AtomFeedProcessor.java:157)
at com.sun.ceq.session.FeedServiceImpl.updateFeed(FeedServiceImpl.java:411)
at com.sun.ceq.session.FeedServiceImpl.timeoutHandler(FeedServiceImpl.java:388)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.sun.enterprise.security.application.EJBSecurityManager.runMethod(EJBSecurityManager.java:1011)
at com.sun.enterprise.security.SecurityUtil.invoke(SecurityUtil.java:175)
at com.sun.ejb.containers.BaseContainer.invokeTargetBeanMethod(BaseContainer.java:2920)
at com.sun.ejb.containers.BaseContainer.callEJBTimeout(BaseContainer.java:2849)
at com.sun.ejb.containers.EJBTimerService.deliverTimeout(EJBTimerService.java:1401)
at com.sun.ejb.containers.EJBTimerService.access$100(EJBTimerService.java:99)
at com.sun.ejb.containers.EJBTimerService$TaskExpiredWork.run(EJBTimerService.java:1952)
at com.sun.ejb.containers.EJBTimerService$TaskExpiredWork.service(EJBTimerService.java:1948)
at com.sun.ejb.containers.util.WorkAdapter.doWork(WorkAdapter.java:75)
at com.sun.corba.ee.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:555)
UPDATE PERSON SET UPDATED_ON = ? WHERE (PERSON_ID = ?)
bind => [2009-10-16 19:03:37.943, 4]



cygnusecks1 added a comment - 16/Oct/09 08:25 PM

Yes, auto-detection shouldn't be too difficult. You can discover which namespaces are defined in a stream and if there are elements in that namespace, and then you can deduce whether it contains an activity stream or just a simple atom feed.

If we decide to add RSS we can do autodetection of that as well, so one would simply plug in the URL and 'see if it works'

I can take a look at this next week.


cygnusecks1 added a comment - 17/Dec/09 09:24 PM

Fixed in SVN revision 436.


PRE added a comment - 15/Feb/10 10:25 AM

closed all ticket for Milestone Release 1.3