Debt (Details)
$ in Thousands
1 Months Ended 12 Months Ended
Dec. 21, 2018
USD ($)
tranche
Jun. 30, 2019
USD ($)
May 31, 2018
May 31, 2017
Dec. 31, 2018
USD ($)
Estimated future principal payments due          
2022   $ 25,000      
Thereafter   25,000      
Total debt   50,000      
2015 Credit Facility          
Debt          
Principal amount         $ 5,500
Floor rate     5.50% 4.50%  
Repayment         5,500
2015 Credit Facility | Maximum          
Debt          
Loss on extinguishment         $ (100)
2015 Credit Facility | Prime rate          
Debt          
Variable interest rate     0.75% 1.25%  
2018 Credit Facility          
Debt          
Maximum amount outstanding $ 75,000        
Number of tranche | tranche 3        
Borrowing $ 25,000 $ 25,000      
Period for commencing monthly principal payments 36 months        
Amortization period 24 months        
Prepayment fee in first year 1.00%        
Prepayment fee in second year 0.50%        
Prepayment fee in third year 0.25%        
Issuance costs $ 800        
Debt default interest rate addition (as a percent) 4.00        
2018 Credit Facility | One-month U.S. LIBOR          
Debt          
Variable interest rate 5.50%        
2018 Credit Facility | Term loan          
Debt          
Borrowing $ 25,000