API changed error during AOSP build. How to fix? - java-8
Im trying to build AOSP(lollipop) using openjdk 1.8 and during make im getting the following errors.
prebuilts/sdk/api/22.txt:24965: error 9: Removed public constructor MediaStore.Audio.Genres()
prebuilts/sdk/api/22.txt:24976: error 9: Removed public constructor MediaStore.Audio.Genres.Members()
prebuilts/sdk/api/22.txt:24989: error 9: Removed public constructor MediaStore.Audio.Media()
prebuilts/sdk/api/22.txt:25002: error 9: Removed public constructor MediaStore.Audio.Playlists()
prebuilts/sdk/api/22.txt:25012: error 9: Removed public constructor MediaStore.Audio.Playlists.Members()
prebuilts/sdk/api/22.txt:25035: error 9: Removed public constructor MediaStore.Files()
prebuilts/sdk/api/22.txt:25053: error 9: Removed public constructor MediaStore.Images()
prebuilts/sdk/api/22.txt:25070: error 9: Removed public constructor MediaStore.Images.Media()
prebuilts/sdk/api/22.txt:25085: error 9: Removed public constructor MediaStore.Images.Thumbnails()
prebuilts/sdk/api/22.txt:25121: error 9: Removed public constructor MediaStore.Video()
prebuilts/sdk/api/22.txt:25127: error 9: Removed public constructor MediaStore.Video.Media()
prebuilts/sdk/api/22.txt:25136: error 9: Removed public constructor MediaStore.Video.Thumbnails()
prebuilts/sdk/api/22.txt:25246: error 9: Removed public constructor Settings.Global()
prebuilts/sdk/api/22.txt:25302: error 9: Removed public constructor Settings.NameValueTable()
prebuilts/sdk/api/22.txt:25310: error 9: Removed public constructor Settings.Secure()
prebuilts/sdk/api/22.txt:25394: error 9: Removed public constructor Settings.SettingNotFoundException(String)
prebuilts/sdk/api/22.txt:25398: error 9: Removed public constructor Settings.System()
prebuilts/sdk/api/22.txt:25537: error 9: Removed public constructor SyncStateContract.Constants()
prebuilts/sdk/api/22.txt:25542: error 9: Removed public constructor SyncStateContract.Helpers()
prebuilts/sdk/api/22.txt:25838: error 9: Removed public constructor UserDictionary.Words()
prebuilts/sdk/api/22.txt:26135: error 9: Removed public constructor Element.Builder(RenderScript)
prebuilts/sdk/api/22.txt:26461: error 9: Removed public constructor RenderScript.RSErrorHandler()
prebuilts/sdk/api/22.txt:26468: error 9: Removed public constructor RenderScript.RSMessageHandler()
prebuilts/sdk/api/22.txt:26493: error 9: Removed public constructor Sampler.Builder(RenderScript)
prebuilts/sdk/api/22.txt:26543: error 9: Removed public constructor Script.FieldBase()
prebuilts/sdk/api/22.txt:26561: error 9: Removed public constructor Script.LaunchOptions()
prebuilts/sdk/api/22.txt:26587: error 9: Removed public constructor ScriptGroup.Builder(RenderScript)
prebuilts/sdk/api/22.txt:26778: error 9: Removed public constructor Type.Builder(RenderScript,Element)
prebuilts/sdk/api/22.txt:26885: error 9: Removed public constructor KeyPairGeneratorSpec.Builder(Context)
prebuilts/sdk/api/22.txt:26903: error 9: Removed public constructor KeyStoreParameter.Builder(Context)
prebuilts/sdk/api/22.txt:26935: error 9: Removed public constructor CarrierMessagingService.SendMmsResult(int,byte)
prebuilts/sdk/api/22.txt:26941: error 9: Removed public constructor CarrierMessagingService.SendMultipartSmsResult(int,int)
prebuilts/sdk/api/22.txt:26947: error 9: Removed public constructor CarrierMessagingService.SendSmsResult(int,int)
prebuilts/sdk/api/22.txt:27027: error 9: Removed public constructor MediaBrowserService.BrowserRoot(String,Bundle)
prebuilts/sdk/api/22.txt:27071: error 9: Removed public constructor NotificationListenerService.Ranking()
prebuilts/sdk/api/22.txt:27128: error 9: Removed public constructor SpellCheckerService.Session()
prebuilts/sdk/api/22.txt:27161: error 9: Removed public constructor AlwaysOnHotwordDetector.Callback()
prebuilts/sdk/api/22.txt:27219: error 9: Removed public constructor WallpaperService.Engine()
prebuilts/sdk/api/22.txt:27438: error 9: Removed public constructor TextToSpeech.Engine()
prebuilts/sdk/api/22.txt:27472: error 9: Removed public constructor TextToSpeech.EngineInfo()
prebuilts/sdk/api/22.txt:28648: error 9: Removed public constructor SubscriptionManager.OnSubscriptionsChangedListener()
prebuilts/sdk/api/22.txt:28844: error 9: Removed public constructor SmsMessage.SubmitPdu()
prebuilts/sdk/api/22.txt:29442: error 9: Removed public constructor TestSuiteBuilder.FailedToCreateTests(Exception)
prebuilts/sdk/api/22.txt:29521: error 9: Removed public constructor BidiFormatter.Builder()
prebuilts/sdk/api/22.txt:29522: error 9: Removed public constructor BidiFormatter.Builder(boolean)
prebuilts/sdk/api/22.txt:29523: error 9: Removed public constructor BidiFormatter.Builder(Locale)
prebuilts/sdk/api/22.txt:29553: error 9: Removed public constructor BoringLayout.Metrics()
prebuilts/sdk/api/22.txt:29597: error 9: Removed public constructor Editable.Factory()
prebuilts/sdk/api/22.txt:29626: error 9: Removed public constructor InputFilter.AllCaps()
prebuilts/sdk/api/22.txt:29631: error 9: Removed public constructor InputFilter.LengthFilter(int)
prebuilts/sdk/api/22.txt:29751: error 9: Removed public constructor LoginFilter.PasswordFilterGMail()
prebuilts/sdk/api/22.txt:29752: error 9: Removed public constructor LoginFilter.PasswordFilterGMail(boolean)
prebuilts/sdk/api/22.txt:29757: error 9: Removed public constructor LoginFilter.UsernameFilterGMail()
prebuilts/sdk/api/22.txt:29758: error 9: Removed public constructor LoginFilter.UsernameFilterGMail(boolean)
prebuilts/sdk/api/22.txt:29763: error 9: Removed public constructor LoginFilter.UsernameFilterGeneric()
prebuilts/sdk/api/22.txt:29764: error 9: Removed public constructor LoginFilter.UsernameFilterGeneric(boolean)
prebuilts/sdk/api/22.txt:29772: error 9: Removed public constructor NoCopySpan.Concrete()
prebuilts/sdk/api/22.txt:29815: error 9: Removed public constructor Spannable.Factory()
prebuilts/sdk/api/22.txt:29996: error 9: Removed public constructor TextUtils.SimpleStringSplitter(char)
prebuilts/sdk/api/22.txt:30439: error 9: Removed public constructor AlignmentSpan.Standard(Alignment)
prebuilts/sdk/api/22.txt:30440: error 9: Removed public constructor AlignmentSpan.Standard(Parcel)
prebuilts/sdk/api/22.txt:30560: error 9: Removed public constructor LeadingMarginSpan.Standard(int,int)
prebuilts/sdk/api/22.txt:30561: error 9: Removed public constructor LeadingMarginSpan.Standard(int)
prebuilts/sdk/api/22.txt:30562: error 9: Removed public constructor LeadingMarginSpan.Standard(Parcel)
prebuilts/sdk/api/22.txt:30724: error 9: Removed public constructor TabStopSpan.Standard(int)
prebuilts/sdk/api/22.txt:30836: error 9: Removed public constructor TtsSpan.Builder(String)
prebuilts/sdk/api/22.txt:30844: error 9: Removed public constructor TtsSpan.CardinalBuilder()
prebuilts/sdk/api/22.txt:30845: error 9: Removed public constructor TtsSpan.CardinalBuilder(long)
prebuilts/sdk/api/22.txt:30846: error 9: Removed public constructor TtsSpan.CardinalBuilder(String)
prebuilts/sdk/api/22.txt:30852: error 9: Removed public constructor TtsSpan.DateBuilder()
prebuilts/sdk/api/22.txt:30853: error 9: Removed public constructor TtsSpan.DateBuilder(Integer,Integer,Integer,Integer)
prebuilts/sdk/api/22.txt:30861: error 9: Removed public constructor TtsSpan.DecimalBuilder()
prebuilts/sdk/api/22.txt:30862: error 9: Removed public constructor TtsSpan.DecimalBuilder(double,int,int)
prebuilts/sdk/api/22.txt:30863: error 9: Removed public constructor TtsSpan.DecimalBuilder(String,String)
prebuilts/sdk/api/22.txt:30871: error 9: Removed public constructor TtsSpan.DigitsBuilder()
prebuilts/sdk/api/22.txt:30872: error 9: Removed public constructor TtsSpan.DigitsBuilder(String)
prebuilts/sdk/api/22.txt:30877: error 9: Removed public constructor TtsSpan.ElectronicBuilder()
prebuilts/sdk/api/22.txt:30890: error 9: Removed public constructor TtsSpan.FractionBuilder()
prebuilts/sdk/api/22.txt:30891: error 9: Removed public constructor TtsSpan.FractionBuilder(long,long,long)
prebuilts/sdk/api/22.txt:30901: error 9: Removed public constructor TtsSpan.MeasureBuilder()
prebuilts/sdk/api/22.txt:30915: error 9: Removed public constructor TtsSpan.MoneyBuilder()
prebuilts/sdk/api/22.txt:30924: error 9: Removed public constructor TtsSpan.OrdinalBuilder()
prebuilts/sdk/api/22.txt:30925: error 9: Removed public constructor TtsSpan.OrdinalBuilder(long)
prebuilts/sdk/api/22.txt:30926: error 9: Removed public constructor TtsSpan.OrdinalBuilder(String)
prebuilts/sdk/api/22.txt:30932: error 9: Removed public constructor TtsSpan.SemioticClassBuilder(String)
prebuilts/sdk/api/22.txt:30940: error 9: Removed public constructor TtsSpan.TelephoneBuilder()
prebuilts/sdk/api/22.txt:30941: error 9: Removed public constructor TtsSpan.TelephoneBuilder(String)
prebuilts/sdk/api/22.txt:30948: error 9: Removed public constructor TtsSpan.TextBuilder()
prebuilts/sdk/api/22.txt:30949: error 9: Removed public constructor TtsSpan.TextBuilder(String)
prebuilts/sdk/api/22.txt:30954: error 9: Removed public constructor TtsSpan.TimeBuilder()
prebuilts/sdk/api/22.txt:30955: error 9: Removed public constructor TtsSpan.TimeBuilder(int,int)
prebuilts/sdk/api/22.txt:30961: error 9: Removed public constructor TtsSpan.VerbatimBuilder()
prebuilts/sdk/api/22.txt:30962: error 9: Removed public constructor TtsSpan.VerbatimBuilder(String)
prebuilts/sdk/api/22.txt:31227: error 9: Removed public constructor Transition.EpicenterCallback()
prebuilts/sdk/api/22.txt:32173: error 9: Removed public constructor GestureDetector.SimpleOnGestureListener()
prebuilts/sdk/api/22.txt:32361: error 9: Removed public constructor KeyCharacterMap.KeyData()
prebuilts/sdk/api/22.txt:32369: error 9: Removed public constructor KeyCharacterMap.UnavailableException(String)
prebuilts/sdk/api/22.txt:32744: error 9: Removed public constructor KeyEvent.DispatcherState()
prebuilts/sdk/api/22.txt:33055: error 9: Removed public constructor MotionEvent.PointerCoords()
prebuilts/sdk/api/22.txt:33056: error 9: Removed public constructor MotionEvent.PointerCoords(PointerCoords)
prebuilts/sdk/api/22.txt:33073: error 9: Removed public constructor MotionEvent.PointerProperties()
prebuilts/sdk/api/22.txt:33074: error 9: Removed public constructor MotionEvent.PointerProperties(PointerProperties)
prebuilts/sdk/api/22.txt:33129: error 9: Removed public constructor ScaleGestureDetector.SimpleOnScaleGestureListener()
prebuilts/sdk/api/22.txt:33174: error 9: Removed public constructor Surface.OutOfResourcesException()
prebuilts/sdk/api/22.txt:33175: error 9: Removed public constructor Surface.OutOfResourcesException(String)
prebuilts/sdk/api/22.txt:33199: error 9: Removed public constructor SurfaceHolder.BadSurfaceTypeException()
prebuilts/sdk/api/22.txt:33200: error 9: Removed public constructor SurfaceHolder.BadSurfaceTypeException(String)
prebuilts/sdk/api/22.txt:33889: error 9: Removed public constructor View.AccessibilityDelegate()
prebuilts/sdk/api/22.txt:33902: error 9: Removed public constructor View.BaseSavedState(Parcel)
prebuilts/sdk/api/22.txt:33903: error 9: Removed public constructor View.BaseSavedState(Parcelable)
prebuilts/sdk/api/22.txt:33908: error 9: Removed public constructor View.DragShadowBuilder(View)
prebuilts/sdk/api/22.txt:33909: error 9: Removed public constructor View.DragShadowBuilder()
prebuilts/sdk/api/22.txt:33910: error 9: Removed public method android.view.View.DragShadowBuilder.getView
prebuilts/sdk/api/22.txt:33916: error 9: Removed public constructor View.MeasureSpec()
prebuilts/sdk/api/22.txt:34209: error 9: Removed public constructor ViewGroup.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:34210: error 9: Removed public constructor ViewGroup.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:34211: error 9: Removed public constructor ViewGroup.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:34223: error 9: Removed public constructor ViewGroup.MarginLayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:34224: error 9: Removed public constructor ViewGroup.MarginLayoutParams(int,int)
prebuilts/sdk/api/22.txt:34225: error 9: Removed public constructor ViewGroup.MarginLayoutParams(MarginLayoutParams)
prebuilts/sdk/api/22.txt:34226: error 9: Removed public constructor ViewGroup.MarginLayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:34627: error 9: Removed public constructor WindowId.FocusObserver()
prebuilts/sdk/api/22.txt:34659: error 9: Removed public constructor WindowManager.BadTokenException()
prebuilts/sdk/api/22.txt:34660: error 9: Removed public constructor WindowManager.BadTokenException(String)
prebuilts/sdk/api/22.txt:34664: error 9: Removed public constructor WindowManager.InvalidDisplayException()
prebuilts/sdk/api/22.txt:34665: error 9: Removed public constructor WindowManager.InvalidDisplayException(String)
prebuilts/sdk/api/22.txt:34669: error 9: Removed public constructor WindowManager.LayoutParams()
prebuilts/sdk/api/22.txt:34670: error 9: Removed public constructor WindowManager.LayoutParams(int)
prebuilts/sdk/api/22.txt:34671: error 9: Removed public constructor WindowManager.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:34672: error 9: Removed public constructor WindowManager.LayoutParams(int,int,int)
prebuilts/sdk/api/22.txt:34673: error 9: Removed public constructor WindowManager.LayoutParams(int,int,int,int,int)
prebuilts/sdk/api/22.txt:34674: error 9: Removed public constructor WindowManager.LayoutParams(int,int,int,int,int,int,int)
prebuilts/sdk/api/22.txt:34675: error 9: Removed public constructor WindowManager.LayoutParams(Parcel)
prebuilts/sdk/api/22.txt:35045: error 9: Removed public constructor AccessibilityNodeInfo.AccessibilityAction(int,CharSequence)
prebuilts/sdk/api/22.txt:35218: error 9: Removed public constructor CaptioningManager.CaptioningChangeListener()
prebuilts/sdk/api/22.txt:35314: error 9: Removed public constructor Animation.Description()
prebuilts/sdk/api/22.txt:35399: error 9: Removed public constructor GridLayoutAnimationController.AnimationParameters()
prebuilts/sdk/api/22.txt:35438: error 9: Removed public constructor LayoutAnimationController.AnimationParameters()
prebuilts/sdk/api/22.txt:35584: error 9: Removed public constructor CursorAnchorInfo.Builder()
prebuilts/sdk/api/22.txt:35859: error 9: Removed public constructor InputMethodSubtype.InputMethodSubtypeBuilder()
prebuilts/sdk/api/22.txt:36173: error 9: Removed public constructor WebChromeClient.FileChooserParams()
prebuilts/sdk/api/22.txt:36535: error 9: Removed public constructor WebView.WebViewTransport()
prebuilts/sdk/api/22.txt:36688: error 9: Removed public constructor AbsListView.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:36689: error 9: Removed public constructor AbsListView.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:36690: error 9: Removed public constructor AbsListView.LayoutParams(int,int,int)
prebuilts/sdk/api/22.txt:36691: error 9: Removed public constructor AbsListView.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:36757: error 9: Removed public constructor AbsoluteLayout.LayoutParams(int,int,int,int)
prebuilts/sdk/api/22.txt:36758: error 9: Removed public constructor AbsoluteLayout.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:36759: error 9: Removed public constructor AbsoluteLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:36781: error 9: Removed public constructor ActionMenuView.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:36782: error 9: Removed public constructor ActionMenuView.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:36783: error 9: Removed public constructor ActionMenuView.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:36784: error 9: Removed public constructor ActionMenuView.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:36841: error 9: Removed public constructor AdapterView.AdapterContextMenuInfo(View,int,long)
prebuilts/sdk/api/22.txt:37365: error 9: Removed public constructor ExpandableListView.ExpandableListContextMenuInfo(View,long,long)
prebuilts/sdk/api/22.txt:37401: error 9: Removed public constructor Filter.FilterResults()
prebuilts/sdk/api/22.txt:37434: error 9: Removed public constructor FrameLayout.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:37435: error 9: Removed public constructor FrameLayout.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:37436: error 9: Removed public constructor FrameLayout.LayoutParams(int,int,int)
prebuilts/sdk/api/22.txt:37437: error 9: Removed public constructor FrameLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:37438: error 9: Removed public constructor FrameLayout.LayoutParams(MarginLayoutParams)
prebuilts/sdk/api/22.txt:37439: error 9: Removed public constructor FrameLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:37462: error 9: Removed public constructor Gallery.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:37463: error 9: Removed public constructor Gallery.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:37464: error 9: Removed public constructor Gallery.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:37515: error 9: Removed public constructor GridLayout.LayoutParams(Spec,Spec)
prebuilts/sdk/api/22.txt:37516: error 9: Removed public constructor GridLayout.LayoutParams()
prebuilts/sdk/api/22.txt:37517: error 9: Removed public constructor GridLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:37518: error 9: Removed public constructor GridLayout.LayoutParams(MarginLayoutParams)
prebuilts/sdk/api/22.txt:37519: error 9: Removed public constructor GridLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:37520: error 9: Removed public constructor GridLayout.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:37712: error 9: Removed public constructor LinearLayout.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:37713: error 9: Removed public constructor LinearLayout.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:37714: error 9: Removed public constructor LinearLayout.LayoutParams(int,int,float)
prebuilts/sdk/api/22.txt:37715: error 9: Removed public constructor LinearLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:37716: error 9: Removed public constructor LinearLayout.LayoutParams(MarginLayoutParams)
prebuilts/sdk/api/22.txt:37717: error 9: Removed public constructor LinearLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:37827: error 9: Removed public constructor ListView.FixedViewInfo()
prebuilts/sdk/api/22.txt:37871: error 9: Removed public constructor MultiAutoCompleteTextView.CommaTokenizer()
prebuilts/sdk/api/22.txt:38113: error 9: Removed public constructor RadioGroup.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:38114: error 9: Removed public constructor RadioGroup.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:38115: error 9: Removed public constructor RadioGroup.LayoutParams(int,int,float)
prebuilts/sdk/api/22.txt:38116: error 9: Removed public constructor RadioGroup.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:38117: error 9: Removed public constructor RadioGroup.LayoutParams(MarginLayoutParams)
prebuilts/sdk/api/22.txt:38182: error 9: Removed public constructor RelativeLayout.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:38183: error 9: Removed public constructor RelativeLayout.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:38184: error 9: Removed public constructor RelativeLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:38185: error 9: Removed public constructor RelativeLayout.LayoutParams(MarginLayoutParams)
prebuilts/sdk/api/22.txt:38186: error 9: Removed public constructor RelativeLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:38254: error 9: Removed public constructor RemoteViews.ActionException(Exception)
prebuilts/sdk/api/22.txt:38255: error 9: Removed public constructor RemoteViews.ActionException(String)
prebuilts/sdk/api/22.txt:38688: error 9: Removed public constructor TableLayout.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:38689: error 9: Removed public constructor TableLayout.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:38690: error 9: Removed public constructor TableLayout.LayoutParams(int,int,float)
prebuilts/sdk/api/22.txt:38691: error 9: Removed public constructor TableLayout.LayoutParams()
prebuilts/sdk/api/22.txt:38692: error 9: Removed public constructor TableLayout.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:38693: error 9: Removed public constructor TableLayout.LayoutParams(MarginLayoutParams)
prebuilts/sdk/api/22.txt:38704: error 9: Removed public constructor TableRow.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:38705: error 9: Removed public constructor TableRow.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:38706: error 9: Removed public constructor TableRow.LayoutParams(int,int,float)
prebuilts/sdk/api/22.txt:38707: error 9: Removed public constructor TableRow.LayoutParams()
prebuilts/sdk/api/22.txt:38708: error 9: Removed public constructor TableRow.LayoutParams(int)
prebuilts/sdk/api/22.txt:38709: error 9: Removed public constructor TableRow.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:38710: error 9: Removed public constructor TableRow.LayoutParams(MarginLayoutParams)
prebuilts/sdk/api/22.txt:39052: error 9: Removed public constructor Toolbar.LayoutParams(Context,AttributeSet)
prebuilts/sdk/api/22.txt:39053: error 9: Removed public constructor Toolbar.LayoutParams(int,int)
prebuilts/sdk/api/22.txt:39054: error 9: Removed public constructor Toolbar.LayoutParams(int,int,int)
prebuilts/sdk/api/22.txt:39055: error 9: Removed public constructor Toolbar.LayoutParams(int)
prebuilts/sdk/api/22.txt:39056: error 9: Removed public constructor Toolbar.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:39057: error 9: Removed public constructor Toolbar.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:39058: error 9: Removed public constructor Toolbar.LayoutParams(MarginLayoutParams)
prebuilts/sdk/api/22.txt:39059: error 9: Removed public constructor Toolbar.LayoutParams(LayoutParams)
prebuilts/sdk/api/22.txt:40130: error 9: Removed public constructor ObjectInputStream.GetField()
prebuilts/sdk/api/22.txt:40190: error 9: Removed public constructor ObjectOutputStream.PutField()
prebuilts/sdk/api/22.txt:40858: error 9: Removed public constructor Character.Subset(String)
prebuilts/sdk/api/22.txt:43965: error 9: Removed public constructor Pipe.SinkChannel(SelectorProvider)
prebuilts/sdk/api/22.txt:43970: error 9: Removed public constructor Pipe.SourceChannel(SelectorProvider)
prebuilts/sdk/api/22.txt:44605: error 9: Removed public constructor KeyStore.Builder()
prebuilts/sdk/api/22.txt:44614: error 9: Removed public constructor KeyStore.CallbackHandlerProtection(CallbackHandler)
prebuilts/sdk/api/22.txt:44626: error 9: Removed public constructor KeyStore.PasswordProtection(char)
prebuilts/sdk/api/22.txt:44633: error 9: Removed public constructor KeyStore.PrivateKeyEntry(PrivateKey,Certificate)
prebuilts/sdk/api/22.txt:44643: error 9: Removed public constructor KeyStore.SecretKeyEntry(SecretKey)
prebuilts/sdk/api/22.txt:44648: error 9: Removed public constructor KeyStore.TrustedCertificateEntry(Certificate)
prebuilts/sdk/api/22.txt:44828: error 9: Removed public constructor Provider.Service(Provider,String,String,String,List,Map)
prebuilts/sdk/api/22.txt:45088: error 9: Removed public constructor CertPath.CertPathRep(String,byte)
prebuilts/sdk/api/22.txt:45201: error 9: Removed public constructor Certificate.CertificateRep(String,byte)
prebuilts/sdk/api/22.txt:47037: error 9: Removed public constructor AttributedCharacterIterator.Attribute(String)
prebuilts/sdk/api/22.txt:47243: error 9: Removed public constructor DateFormat.Field(String,int)
prebuilts/sdk/api/22.txt:47385: error 9: Removed public constructor Format.Field(String)
prebuilts/sdk/api/22.txt:47410: error 9: Removed public constructor MessageFormat.Field(String)
prebuilts/sdk/api/22.txt:47470: error 9: Removed public constructor NumberFormat.Field(String)
prebuilts/sdk/api/22.txt:47596: error 9: Removed public constructor AbstractMap.SimpleEntry(K,V)
prebuilts/sdk/api/22.txt:47597: error 9: Removed public constructor AbstractMap.SimpleEntry(Entry)
prebuilts/sdk/api/22.txt:47604: error 9: Removed public constructor AbstractMap.SimpleImmutableEntry(K,V)
prebuilts/sdk/api/22.txt:47605: error 9: Removed public constructor AbstractMap.SimpleImmutableEntry(Entry)
prebuilts/sdk/api/22.txt:48471: error 9: Removed public constructor Locale.Builder()
prebuilts/sdk/api/22.txt:48702: error 9: Removed public constructor ResourceBundle.Control()
prebuilts/sdk/api/22.txt:49836: error 9: Removed public constructor ThreadPoolExecutor.AbortPolicy()
prebuilts/sdk/api/22.txt:49841: error 9: Removed public constructor ThreadPoolExecutor.CallerRunsPolicy()
prebuilts/sdk/api/22.txt:49846: error 9: Removed public constructor ThreadPoolExecutor.DiscardOldestPolicy()
prebuilts/sdk/api/22.txt:49851: error 9: Removed public constructor ThreadPoolExecutor.DiscardPolicy()
prebuilts/sdk/api/22.txt:50118: error 9: Removed public constructor AbstractQueuedLongSynchronizer.ConditionObject()
prebuilts/sdk/api/22.txt:50165: error 9: Removed public constructor AbstractQueuedSynchronizer.ConditionObject()
prebuilts/sdk/api/22.txt:50260: error 9: Removed public constructor ReentrantReadWriteLock.ReadLock(ReentrantReadWriteLock)
prebuilts/sdk/api/22.txt:50270: error 9: Removed public constructor ReentrantReadWriteLock.WriteLock(ReentrantReadWriteLock)
prebuilts/sdk/api/22.txt:50309: error 9: Removed public constructor Attributes.Name(String)
prebuilts/sdk/api/22.txt:51639: error 9: Removed public constructor PSource.PSpecified(byte)
prebuilts/sdk/api/22.txt:56296: error 9: Removed public constructor SingleClientConnManager.ConnAdapter(PoolEntry,HttpRoute)
prebuilts/sdk/api/22.txt:56300: error 9: Removed public constructor SingleClientConnManager.PoolEntry()
******************************
You have tried to change the API from what has been previously released in
an SDK. Please fix the errors listed above.
******************************
make: *** [out/target/common/obj/PACKAGING/checkpublicapi-last-timestamp] Error 38
#### make failed to build some targets (03:08 (mm:ss)) ####
I tried to give make update-api which gave me make completed successfully message.Here is the last few lines of it
Copying: out/target/common/obj/JAVA_LIBRARIES/android-support-v8-renderscript_intermediates/classes-jarjar.jar
Copying: out/target/common/obj/JAVA_LIBRARIES/android-support-v8-renderscript_intermediates/emma_out/lib/classes-jarjar.jar
Copying: out/target/common/obj/JAVA_LIBRARIES/android-support-v8-renderscript_intermediates/classes.jar
Docs droiddoc: out/target/common/docs/doc-comment-check
javadoc: warning - Multiple sources of package comments found for package "android.media.effect"
DroidDoc took 82 sec. to write docs to out/target/common/docs/doc-comment-check
1 warning
Copying current.txt
Copying removed.txt
Copying system-current.txt
Copying system-removed.txt
#### make completed successfully (02:50 (mm:ss)) ####
What am i doing wrong here? Can someone help me to identify the issue?
PS:I wanted to build using java 1.8 only :)
Related
How to find which component required a bean?
I have the error message "A component required a bean named XYZ that could not be found." Is there a way to display, which component this is? UPDATES: This is the error message *************************** APPLICATION FAILED TO START *************************** Description: A component required a bean named 'demoAnnotation' that could not be found. Action: Consider defining a bean named 'demoAnnotation' in your configuration. I have a bean defined called demoAnnotation: #Component #Qualifier("demoAnnotation") public class Demo implements IDemo { private static final Logger log = LoggerFactory.getLogger(Demo.class); #Value("${com.example.demo.Demo.beanName:BEAN_NAME_DEFAULT}") private String beanName; #Override public String getBeanName() { return beanName; } #Override public void setBeanName(String beanName) { this.beanName = beanName; } }
When you start your application, you should get a message like: Field repository in com.example.demo.Controller required a bean of type 'com.example.demo.Repository' that could not be found. com.example.demo.Controller is the name of the class that needs the com.example.demo.Repository bean Then it would be easier if you show us the exact error message
Constructor parameter in configuration class required a bean of type 'StratusAuthenticationEntryPoint' that could not be found
Parameter 0 of constructor in ResourceServerConfiguration required a bean of type 'StratusAuthenticationEntryPoint' that could not be found. I am using spring boot 2.6.6 Here is the code: #Configuration #EnableGlobalMethodSecurity(prePostEnabled = true) #Order(100) //#Import({ApiPermissionEvaluator.class}) public class ResourceServerConfiguration extends WebSecurityConfigurerAdapter { private final StratusAuthenticationEntryPoint securityAuthenticationEntryPoint; public ResourceServerConfiguration(StratusAuthenticationEntryPoint securityAuthenticationEntryPoint) { super(); this.securityAuthenticationEntryPoint = securityAuthenticationEntryPoint; } } error message: *************************** APPLICATION FAILED TO START *************************** Description: Parameter 0 of constructor in com.stratus.security.config.ResourceServerConfiguration required a bean of type 'com.stratus.security.config.StratusAuthenticationEntryPoint' that c ould not be found. Action: Consider defining a bean of type 'com.stratus.security.config.StratusAuthenticationEntryPoint' in your configuration.
Add #Component over Class of StratusAuthenticationEntryPoint that a bean created by spring ioc verify if the ComponentScan path contains Class of StratusAuthenticationEntryPoint
Circular dependency error for beans in Spring org.springframework.beans.factory.BeanCurrentlyInCreationException:
I have a classes defined as follows : #Configuration public class TestConfig extends IntegrationTestConfig { #Bean public TestUserManager testUserManager() { ... } #Configuration #Import({BaseTestConfig.class}) public class IntegrationTestConfig { #Autowired private TestUserManager ssbTestUserManager; #Bean #DependsOn({"testUserManager"}) public TestDeviceFactory testDeviceFactory() { return new TestDeviceManager(); } #Configuration public class BaseTestConfig { #Bean public TestUserManager testUserManager() { ... } } When I try to execute it, it gives the error : Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'testConfig': Unsatisfied dependency expressed through field 'ssbTestUserManager'; nested exception is org.springframework.beans.factory.BeanCurrentlyInCreationException: Error creating bean with name 'testUserManager': Requested bean is currently in creation: Is there an unresolvable circular reference How can I fix this issue? I am not able to override the testUserManager() method in TestConfig since it does not directly inherit from BaseTestConfig. IntegrationTestConfig and BaseTestConfig are imported as libraries so I dont have much control there. I think #DependsOn({"testUserManager"}) is causing issue but not sure how I can resolve it
A circular reference occurs when you have a chain of beans that depends together and a cycle created in the dependency graph. So, in your case, you've defined an instance of TestUserManager in TestConfig class and uses it in the parent class and it creates a cycle! The solution is defininig abstract getTestUserManager method in the parent class and override it in the child class with #Bean annotation (If you are using it in other parts of code). You can use that method in your parent class instead of using the variable you've defined. IntegrationTestConfig: #Configuration public abstract class IntegrationTestConfig { public abstract TestUserManager getTestUserManager(); } TestConfig: #Configuration public class TestConfig extends IntegrationTestConfig { #Bean #Override public TestUserManager getTestUserManager() { return new TestUserManager(); } }
Encountered invalid #Scheduled method 'methodName': Only no-arg methods may be annotated with #Scheduled
plz I don't know wath is the exact problem in the code if I add Scheduled annotatiçon in my code suddenly this error appears if you have any soulustion please. plz I don't know wath is the exact problem in the code if I add Scheduled annotatiçon in my code suddenly this error appears if you have any soulustion please. Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled. 12-09-2019 18:11:54.908 [restartedMain] ERROR o.s.boot.SpringApplication.reportFailure - Application run failed org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'missionResource': Unsatisfied dependency expressed through field 'missionManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'missionImpl' defined in file [C:\Users\El Oussa\Desktop\vgas-api\vgas-manager\target\classes\ma\valueit\vgas\manager\business\impl\MissionImpl.class]: Initialization of bean failed; nested exception is java.lang.IllegalStateException: Encountered invalid #Scheduled method 'editMission': Only no-arg methods may be annotated with #Scheduled at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:596) at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:90) I have added #EnableScheduling in SpringBootApplication -------------------------------------------------------- #SpringBootApplication #EnableScheduling #ComponentScan("com.qaiboub.vs") public class Application { public static void main(String[] args) { SpringApplication.run(Application.class, args); } } #Service public class MissionImpl extends CrudManagerImpl<MissionDto, Integer, MissionEntity, MissionService, MissionConverter> implements MissionManager { #Autowired private MissionService missionService; #Autowired private MissionConverter missionConverter; enter code here #Override public MissionService getService() { return missionService; } #Override public MissionConverter getConverter() { return missionConverter; } #Scheduled(cron = "0 15 18 * * *") public void editMission(Integer id, MissionDto missionDto) { if (StringUtils.isEmpty(id)) { throw new MissingIdException(); } if (missionDto == null) { throw new InvalidPayloadException(); } if (!id.equals(missionDto.getId())) { throw new BusinessException(CommonErrorCode.TRYING_TO_EDIT_ANOTHER_ENTITY); } missionEntity = missionConverter.convertFrom(missionDto); missionEntity = missionService.save(missionEntity); } }
remove the function arg. Scheduler don't take arg in their functions
You need to remove all the arguments from the function, the scheduler does not accept any argument public void syncData(#RequestParam(name = "created_at_from") String createdAtFrom, #RequestParam(name = "created_at_to") String createdAtTo) {} Correct format is public void syncData() throws Exception {} Use this link for additional details: https://www.baeldung.com/shedlock-spring
AOP applied to all public methods gives BeanCreationException exception
I have created a simple aspect that is applicable to all public methods like this: #Aspect #Component public class MyAspect { #Pointcut("execution(public * *(..))") private void anyPublicOperation() { } #Before("anyPublicOperation()") private void beforePointCut(){ System.out.println("Inside before pointcut of MyAspect"); } } I have below Java configuration: #Configuration //Enable AspectJ auto proxying #EnableAspectJAutoProxy #ComponentScan(basePackages={"com.examples"}) public class Config { //Declare a bean #Bean public MyAspect myAspectProgram() { return new MyAspect(); } } I am getting below exception when I load my configuration using AnnotationConfigApplicationContext class: Caused by: org.springframework.beans.factory.BeanCurrentlyInCreationException: Error creating bean with name 'myAspectProgram': Requested bean is currently in creation: Is there an unresolvable circular reference? If I change the pointcut expression then I don't get any exceptions, program is working fine. Why I am getting issue when I have the pointcut expression as #Pointcut("execution(public * *(..))")?