"use strict";(self.webpackChunkportal_ui=self.webpackChunkportal_ui||[]).push([[5702],{25702:function(e,t,n){n.r(t);var i=n(29439),s=n(72791),o=n(26181),r=n.n(o),c=n(78687),l=n(57689),a=n(29945),u=n(31776),d=n(82342),f=n(38442),b=n(56087),x=n(87995),h=n(9859),m=n(81551),j=n(75578),S=n(27454),p=n(80184),v=(0,j.Z)(s.lazy((function(){return n.e(455).then(n.bind(n,80455))}))),_=(0,j.Z)(s.lazy((function(){return Promise.all([n.e(5473),n.e(1715),n.e(5994),n.e(7391),n.e(225),n.e(9897),n.e(5739),n.e(2661)]).then(n.bind(n,82661))})));t.default=function(){var e=(0,m.TL)(),t=(0,l.UO)(),n=(0,c.v9)(h.HQ),o=(0,s.useState)(!1),j=(0,i.Z)(o,2),E=j[0],k=j[1],T=(0,s.useState)(!0),F=(0,i.Z)(T,2),I=F[0],N=F[1],C=(0,s.useState)([]),O=(0,i.Z)(C,2),A=O[0],Z=O[1],g=(0,s.useState)(!1),y=(0,i.Z)(g,2),K=y[0],P=y[1],B=(0,s.useState)(null),U=(0,i.Z)(B,2),G=U[0],M=U[1],w=t.bucketName||"",z=(0,f.F)(w,[b.Ft.S3_GET_BUCKET_NOTIFICATIONS,b.Ft.S3_GET_ACTIONS]);(0,s.useEffect)((function(){n&&N(!0)}),[n,N]),(0,s.useEffect)((function(){e((0,x.Sc)("bucket_detail_events"))}),[]),(0,s.useEffect)((function(){I&&(z?u.h.buckets.listBucketEvents(w).then((function(e){var t=r()(e.data,"events",[]);N(!1),Z(t||[])})).catch((function(t){N(!1),e((0,x.Ih)((0,d.g)(t.error)))})):N(!1))}),[I,e,w,z]);var R=[{type:"delete",onClick:function(e){P(!0),M(e)}}];return(0,p.jsxs)(s.Fragment,{children:[K&&(0,p.jsx)(v,{deleteOpen:K,selectedBucket:w,bucketEvent:G,closeDeleteModalAndRefresh:function(e){P(!1),e&&N(!0)}}),E&&(0,p.jsx)(_,{open:E,selectedBucket:w,closeModalAndRefresh:function(){k(!1),N(!0)}}),(0,p.jsx)(a.NZf,{separator:!0,sx:{marginBottom:15},actions:(0,p.jsx)(f.s,{scopes:[b.Ft.S3_PUT_BUCKET_NOTIFICATIONS,b.Ft.S3_PUT_ACTIONS,b.Ft.ADMIN_SERVER_INFO],resource:w,matchAll:!0,errorProps:{disabled:!0},children:(0,p.jsx)(S.Z,{tooltip:"Subscribe to Event",children:(0,p.jsx)(a.zxk,{id:"Subscribe-bucket-event",onClick:function(){k(!0)},label:"Subscribe to Event",icon:(0,p.jsx)(a.dtP,{}),variant:"callAction"})})}),children:"Events"}),(0,p.jsxs)(a.rjZ,{container:!0,children:[(0,p.jsx)(a.rjZ,{item:!0,xs:12,children:(0,p.jsx)(f.s,{scopes:[b.Ft.S3_GET_BUCKET_NOTIFICATIONS,b.Ft.S3_GET_ACTIONS],resource:w,errorProps:{disabled:!0},children:(0,p.jsx)(a.wQF,{itemActions:R,columns:[{label:"SQS",elementKey:"arn"},{label:"Events",elementKey:"events",renderFunction:function(e){return(0,p.jsx)(s.Fragment,{children:e.join(", ")})}},{label:"Prefix",elementKey:"prefix"},{label:"Suffix",elementKey:"suffix"}],isLoading:I,records:A,entityName:"Events",idField:"id",customPaperHeight:"400px"})})}),!I&&(0,p.jsxs)(a.rjZ,{item:!0,xs:12,children:[(0,p.jsx)("br",{}),(0,p.jsx)(a.KfX,{title:"Event Notifications",iconComponent:(0,p.jsx)(a.cCG,{}),help:(0,p.jsxs)(s.Fragment,{children:["MinIO bucket notifications allow administrators to send notifications to supported external services on certain object or bucket events. MinIO supports bucket and object-level S3 events similar to the Amazon S3 Event Notifications.",(0,p.jsx)("br",{}),(0,p.jsx)("br",{}),"You can learn more at our"," ",(0,p.jsx)("a",{href:"https://min.io/docs/minio/linux/administration/monitoring/bucket-notifications.html?ref=con",target:"_blank",rel:"noopener",children:"documentation"}),"."]})})]})]})]})}}}]);
//# sourceMappingURL=5702.6a08188b.chunk.js.map