To reproduce: + import manifest + enable repos (not sure required step for reproducer) + delete manifest + import same manifest <pre> 2017-02-08 15:01:01,616 [thread=http-bio-8443-exec-6] [req=91ff7192-38db-4370-9111-1389725c6ed1, org=] INFO org.candlepin.common.filter.LoggingFilter - Request: verb=GET, uri=/candlepin/owners/examplecorp/uebercert 2017-02-08 15:01:01,655 [thread=http-bio-8443-exec-6] [req=91ff7192-38db-4370-9111-1389725c6ed1, org=examplecorp] ERROR org.candlepin.common.exceptions.mappers.CandlepinExceptionMapper - Runtime Error Index: 0, Size: 0 at java.util.ArrayList.rangeCheck:653 java.lang.IndexOutOfBoundsException: Index: 0, Size: 0 at java.util.ArrayList.rangeCheck(ArrayList.java:653) ~[na:1.8.0_111] at java.util.ArrayList.get(ArrayList.java:429) ~[na:1.8.0_111] at org.candlepin.resource.OwnerResource.getUeberCertificate(OwnerResource.java:1422) ~[OwnerResource.class:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_111] </pre>
Created from redmine issue http://projects.theforeman.org/issues/18424
Debug notes: SELECT -- NO SUBS FOR 2.0 -- Certificates (SELECT Count(*) FROM cp_ent_certificate ec INNER JOIN cp_entitlement e ON e.id = ec.entitlement_id INNER JOIN cp_pool p ON e.pool_id = p.id INNER JOIN cp2_products prod ON prod.uuid = p.product_uuid WHERE prod.NAME LIKE '%_ueber_product') AS UEBER_ENT_CERTS, -- Entitlements (SELECT Count(*) FROM cp_entitlement e INNER JOIN cp_pool p ON e.pool_id = p.id INNER JOIN cp2_products prod ON prod.uuid = p.product_uuid WHERE prod.NAME LIKE '%_ueber_product') AS UEBER_ENTS, -- Pools (SELECT Count(*) FROM cp_pool p INNER JOIN cp2_products prod ON prod.uuid = p.product_uuid WHERE prod.NAME LIKE '%_ueber_product') AS UEBER_POOLS, -- Content (select count(*) from cp2_content c inner join cp2_product_content pc on pc.content_uuid=c.uuid inner join cp2_products p on p.uuid=pc.product_uuid where p.name LIKE '%ueber_product' ) AS CP2_UEBER_CONTENT, -- Owner Content (select count(*) from cp2_owner_content oc inner join cp2_content c on c.uuid=oc.content_uuid inner join cp2_product_content pc on pc.content_uuid=c.uuid inner join cp2_products p on p.uuid=pc.product_uuid where p.name LIKE '%ueber_product' ) as CP2_OWNER_CONTENT, -- Products (select count(*) from cp2_products p where p.name LIKE '%ueber_product') AS CP2_PRODUCTS, -- Owner Products (select count(*) from cp2_owner_products op INNER JOIN cp2_products prod on op.product_uuid = prod.uuid WHERE prod.name LIKE '%ueber_product' ) AS CP2_OWNER_PRODUCTS, -- Consumers (SELECT Count(*) FROM cp_consumer WHERE NAME = 'ueber_cert_consumer' ) AS UEBER_CONSUMER; Before manifest delete: ueber_ent_certs | ueber_ents | ueber_pools | cp2_ueber_content | cp2_owner_content | cp2_products | cp2_owner_products | ueber_consumer -----------------+------------+-------------+-------------------+-------------------+--------------+--------------------+---------------- 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 After manifest delete: ueber_ent_certs | ueber_ents | ueber_pools | cp2_ueber_content | cp2_owner_content | cp2_products | cp2_owner_products | ueber_consumer -----------------+------------+-------------+-------------------+-------------------+--------------+--------------------+---------------- 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1
Fix is available in candlepin-2.0.25-1
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. > > For information on the advisory, and where to find the updated files, follow the link below. > > If the solution does not work for you, open a new bug report. > > https://access.redhat.com/errata/RHSA-2018:0336