Buggy code:
private void consolidateSteppedPrices ( PriceModel priceModel ) { } boolean saveLicenseInformationForPriceModel ( long productKey , long priceModelKey , VOPriceModel priceModel , PlatformUser currentUser , boolean isCreateNewPriceModel ) { } private List < VOLocalizedText > getOldLicenses ( long productKey , long priceModelKey , boolean isCreateNewPriceModel ) { } void validatePricedProductRoles ( List < VOPricedRole > roleSpecificUserPrices , Product product ) throws OperationNotPermittedException { } void setRoleSpecificPrices ( long voPriceModelKey , PriceModel priceModel , PricedParameter pricedParameter , PricedOption pricedOption , List < VOPricedRole > roleSpecificUserPrices , boolean priceModelCreatedInTransaction , Organization targetCustomer , Subscription subscription , List < PricedProductRole > oldPricedProductRoles ) throws ConcurrentModificationException , OperationNotPermittedException , ValidationException { } void updatePricedProductRole ( long voPriceModelKey , VOPricedRole pricedProductRole , PricedProductRole pprToUpdate , PriceModel priceModel , RoleDefinition roleDefinition , PricedParameter pricedParameter , Organization targetCustomer , Subscription subscription , boolean ifNeedLog ) throws ConcurrentModificationException , ValidationException { } PricedProductRole createPricedProductRole ( long voPriceModelKey , VOPricedRole pricedProductRole , PriceModel priceModel , RoleDefinition roleDefinition , PricedParameter pricedParameter , PricedOption pricedOption , Organization targetCustomer , Subscription subscription , List < PricedProductRole > oldPricedProductRoles ) throws ValidationException { } private BigDecimal findOldPrice ( List < PricedProductRole > oldPricedProductRoles , RoleDefinition roleDefinition ) { } List < PricedEvent > convertAndValidateEvents ( long voPriceModelKey , List < VOPricedEvent > voPricedEvents , List < Event > eventDefinitions , PriceModel priceModel , boolean priceModelCreatedInTransaction ) throws ConcurrentModificationException , OperationNotPermittedException , ValidationException { } void updatePricedEvent ( VOPricedEvent voPricedEvent , PricedEvent pricedEvent , Event event , PriceModel priceModel ) throws ConcurrentModificationException , ValidationException { } PricedEvent createPricedEvent ( VOPricedEvent voPricedEvent , Event event , PriceModel priceModel ) throws ValidationException { } void removePricedEvents ( long voPriceModelKey , Collection < PricedEvent > pricedEvents ) { } private void validateSteppedPrices ( Event event , PricedEvent pe , List < SteppedPrice > steppedPrices ) throws ValidationException { } private void validateDomainObjectKey ( BaseVO vo , DomainObject < ? > domainObject , boolean priceModelCreatedInTransaction ) throws OperationNotPermittedException { } List < SteppedPrice > convertAndValidateSteppedPrices ( long voPriceModelKey , List < VOSteppedPrice > voSteppedPrices , PriceModel priceModel , PricedEvent pricedEvent , PricedParameter pricedParameter , boolean priceModelCreatedInTransaction ) throws ConcurrentModificationException , OperationNotPermittedException , ValidationException { } SteppedPrice createSteppedPrice ( VOSteppedPrice voSteppedPrice , PriceModel priceModel , PricedEvent pricedEvent , PricedParameter pricedParameter ) throws ValidationException { } private void setSteppedPrice ( SteppedPrice steppedPrice , PriceModel priceModel , PricedEvent pricedEvent , PricedParameter pricedParameter ) { } void updateSteppedPrice ( VOSteppedPrice voSteppedPrice , SteppedPrice steppedPrice , PriceModel priceModel , PricedEvent pricedEvent , PricedParameter pricedParameter ) throws ConcurrentModificationException , ValidationException { } void removeSteppedPrices ( long voPriceModelKey , Collection < SteppedPrice > steppedPrices , PricedEvent pricedEvent , PricedParameter pricedParameter , PriceModel priceModel ) { } void validateSteppedPriceContraints ( PricedParameter pricedParameter , VOSteppedPrice steppedPrice ) throws ValidationException { } @ Override @ RolesAllowed ( "SERVICE_MANAGER" ) public VOServiceDetails savePriceModelForCustomer ( VOServiceDetails service , VOPriceModel priceModel , VOOrganization customer ) throws ConcurrentModificationException , CurrencyException , ObjectNotFoundException , OperationNotPermittedException , OrganizationAuthoritiesException , PriceModelException , ServiceOperationException , ServiceStateException , ValidationException { } void validateCustomersRole ( Organization targetCustomer , PlatformUser currentUser ) throws OperationNotPermittedException { } private void validateIfCustomerServiceExists ( VOServiceDetails service , Organization targetCustomer ) throws ObjectNotFoundException , ServiceOperationException , ServiceStateException { } @ Override @ RolesAllowed ( "SERVICE_MANAGER" ) public VOServiceDetails savePriceModelForSubscription ( VOServiceDetails service , VOPriceModel priceModel ) throws ConcurrentModificationException , CurrencyException , ObjectNotFoundException , OperationNotPermittedException , OrganizationAuthoritiesException , PaymentInformationException , PriceModelException , SubscriptionStateException , ValidationException { } private void validateOneTimeFee ( VOPriceModel priceModel , Product product ) throws OperationNotPermittedException { } private void validateFreePeriod ( VOPriceModel priceModel , Product product ) throws OperationNotPermittedException { } private void validatePriceModel ( VOPriceModel priceModel , Product product , Subscription sub ) throws PaymentInformationException , PriceModelException { } void validatePriceModelType ( PriceModel existingPriceModel , VOPriceModel newPriceModel ) throws PriceModelException { } void validateCurrency ( PriceModel existingPriceModel , VOPriceModel newPriceModel ) throws PriceModelException { } void validateTimeUnit ( PriceModel existingPriceModel , VOPriceModel newPriceModel ) throws PriceModelException { } private void validateExternalServiceMustBeFree ( VOPriceModel priceModel , VOServiceDetails serviceDetails ) throws ValidationException { } public VOSubscriptionDetails validateSubscription ( VOService service ) throws ObjectNotFoundException , OperationNotPermittedException , SubscriptionStateException { PlatformUser currentUser = dm . getCurrentUser ( ) ; Product product = dm . getReference ( Product . class , service . getKey ( ) ) ; Subscription subscription = validateSubscription ( service , currentUser , product ) ; <START_BUG> VOSubscriptionDetails voSubscriptionDetails = subscriptionService . getSubscriptionDetails ( subscription . getSubscriptionId ( ) ) ; <END_BUG> return voSubscriptionDetails ; } private Subscription validateSubscription ( VOService service , PlatformUser currentUser , Product product ) throws OperationNotPermittedException , SubscriptionStateException { } @ Override @ RolesAllowed ( "SERVICE_MANAGER" ) public List < VOService > getCompatibleServices ( VOService service ) throws ObjectNotFoundException , OperationNotPermittedException , OrganizationAuthoritiesException { } @ Override @ RolesAllowed ( "SERVICE_MANAGER" ) public void setCompatibleServices ( VOService service , List < VOService > compatibleServices ) throws ConcurrentModificationException , ObjectNotFoundException , OperationNotPermittedException , OrganizationAuthoritiesException , ServiceCompatibilityException , ServiceStateException { } void logServiceUpDownGradeOptions ( Product referencrProdut , List < ProductReference > targetProducts , String upDowngrade ) { } private void validateMarketplaceCompatibility ( Product referenceProduct , Product compatibleProduct ) throws ServiceCompatibilityException { } @ Override @ RolesAllowed ( "SERVICE_MANAGER" ) public void deleteService ( VOService service ) throws ConcurrentModificationException , ObjectNotFoundException , OperationNotPermittedException , OrganizationAuthoritiesException , ServiceOperationException , ServiceStateException { } @ Override @ TransactionAttribute ( TransactionAttributeType . MANDATORY ) public void deleteProduct ( Organization supplier , Product product ) throws OperationNotPermittedException , ServiceOperationException , ServiceStateException { } void deletePriceModelForCustomer ( Product product ) { } @ Override @ RolesAllowed ( "SERVICE_MANAGER" ) public boolean statusAllowsDeletion ( VOService service ) throws ConcurrentModificationException , ObjectNotFoundException , OperationNotPermittedException { } private long countNonSubscriptionCopiesInState ( Product template , Set < ServiceStatus > states ) { } void validateNotExistingResalePermissions ( Product template ) throws ServiceOperationException { } private List < Product > getCustomerSpecificProductCopies ( Product template ) { } List < Event > getPlatformEvents ( TechnicalProduct tp ) { } private List < ParameterDefinition > getPlatformParameterDefinitions ( TechnicalProduct tp ) { } private Product getProductFromQueryResult ( Organization cust , Query query ) { }

Fix:
VOSubscriptionDetails voSubscriptionDetails = subscriptionService . getSubscriptionDetailsWithoutOwnerCheck ( subscription . getKey ( ) ) ;