This can be accomplished with batches (logged or unlogged), but that means that all apps need to be updated to dual-write. With a Trigger and admin can tee the data without having to change a line of app code.
---->Brian > On Dec 15, 2020, at 7:59 AM, Stefan Miklosovic > <stefan.mikloso...@instaclustr.com> wrote: > > Hi, > > why can't this be achieved by batches? Do I miss something fundamental > here? Batches may write to different tables right ... I am just > missing the point of using triggers for this. > > I add specifics to Brian's first paragraph, this is covered by > CASSANDRA-13985 - > https://github.com/apache/cassandra/commit/54de771e643e9cc64d1f5dd28b5de8a9a91a219e > This will be firstly introduced in 4.0. > > Stefan > >> On Tue, 15 Dec 2020 at 13:49, Brian Hess <brianmh...@gmail.com> wrote: >> >> One challenge to be aware of is that when you use multiple data centers, the >> users can make changes in either data center and those changes will >> propagate to the other data center. That is, there is no concept of a >> “read-only data center” in Cassandra. That may be fine, but some >> organizations want to grant access to the data for analytics but don’t want >> those teams to be able to modify the original data. You can, in some cases, >> restrict the write access through user/role permissions (the analytics team >> only has read access to that table), but that may not work depending on your >> use case (but it usually does work). >> >> One comment from Benjamin’s comment below. There is one scenario where the >> Trigger could guarantee the data makes it to both tables, specifically if >> both tables reside in the same keyspace and have the same partition key(s). >> Mutations in the same keyspace on tables that have the same partition key >> are internally to Cassandra merged into a single internal Mutation and >> always applied atomically. So, if you had an exactly same schema for your >> second table and it resides in the same keyspace (mytable and >> mytable_analytics, say, both in mykeyspace) your trigger could duplicate the >> mutation to the source table to be an exact copy into the second table and >> Cassandra will apply these both atomically (they both succeed or they both >> fail - never just one). In this scenario, the analytics team could modify >> data in the second table and not effect the data in the source table. >> >> ---->Brian >> >>>> On Dec 15, 2020, at 7:38 AM, pauloricardomg <pauloricard...@gmail.com> >>>> wrote: >>> >>> To extend Paul's point, datacenters in cassandra are logical concepts which >>> may be useful for your use case and do not necessarily need to be >>> represented by physical data centers. >>> >>> The presentation mentioned by Andrew, while helpful, covers some concepts >>> which are specific to Hadoop and may be outdated in more recent versions of >>> Cassandra. >>> >>> I'd recommend two more recent presentations on the multi-DC topic: >>> - >>> https://www.slideshare.net/DataStax/apache-cassandra-multidatacenter-essentials-julien-anguenot-iland-internet-solutions-c-summit-2016 >>> - >>> https://www.slideshare.net/DataStax/operations-consistency-failover-for-multidc-clusters-alexander-dejanovski-the-last-pickle-cassandra-summit-2016 >>> >>> Finally, if you have any more questions on this I'd recommend you send them >>> to the u...@cassandra.apache.org mailing list as this mailing list ( >>> dev@cassandra.apache.org) is related to the project development of >>> Cassandra. >>> >>>> Em ter., 15 de dez. de 2020 às 09:28, Greg Oliver >>>> <gol...@microsoft.com.invalid> escreveu: >>>> >>>> Can't see it in the email. What's the slide #? >>>> >>>> From: Andrew Cobley (Staff) <a.e.cob...@dundee.ac.uk> >>>> Sent: Tuesday, December 15, 2020 12:26 PM >>>> To: dev@cassandra.apache.org >>>> Subject: [EXTERNAL] Re: Triggers >>>> >>>> Yes that's right. I remember this illustration: >>>> >>>> [Diagram Description automatically generated] >>>> >>>> >>>> From this presentation: >>>> >>>> https://www.slideshare.net/rastrick/presentation-12982302< >>>> https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.slideshare.net%2Frastrick%2Fpresentation-12982302&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031889415%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=itM2Kb7eQqOSPO09fGiuHXJPVjW6C51qXCMYq985WaE%3D&reserved=0 >>>>> >>>> >>>> Might help. >>>> >>>> Andy >>>> >>>> [University of Dundee shield logo]< >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-home&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031899372%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=WrafubTszeH9pttSA%2BYVqlfYrcPkTfyIVVZXp7BEq8s%3D&reserved=0 >>>>> >>>> >>>> >>>> Andy Cobley >>>> Senior Lecturer, Program Director Data Science and Data Engineering MSc >>>> School of Science and Engineering, University of Dundee >>>> +44 (0)1382 385078 (Not at present) | a.e.cob...@dundee.ac.uk<mailto: >>>> a.e.cob...@dundee.ac.uk> >>>> [University of Dundee Facebook]< >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-fb&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031899372%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=8IIFStCp5WnED9YVMsPytY0iZghIS%2FZOIKQMKF4cyC4%3D&reserved=0> >>>> [University of Dundee Twitter] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-tw&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031909329%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=6wKLsHnA29J3IAMKab0X65HW6m%2BFxQCTrO9k8ckHUs8%3D&reserved=0> >>>> [University of Dundee LinkedIn] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-li&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031909329%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=ASXnqQm0RhV5syVKZsJRHRgNN1%2B0A02gYGmUD4DMipQ%3D&reserved=0> >>>> [University of Dundee YouTube] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-yt&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031919279%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=IMRJ5gCuQJVWLbB5yRiuaWRUlZaJTN0YXxdmnVeKAMs%3D&reserved=0> >>>> [University of Dundee Instagram] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-ig&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031919279%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=TnfBPZT9hoG%2Fy1xZMvkKHoqGZhsYNv6Ez7kmlTQPctk%3D&reserved=0> >>>> [University of Dundee Snapchat] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-sc&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031919279%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=NRmMMZ2exr%2B8g6kSw%2Bkc75Wi1gwlw4mlqj8NDRlHrMo%3D&reserved=0 >>>>> >>>> One of the UK's top 20 universities< >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-strapline&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031929244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=nYLpUf9xI26pOrv44naId%2BIfEtDF41ANCL03O5NQYSw%3D&reserved=0 >>>>> >>>> The Guardian University Guide 2021 >>>> [Covid code of conduct icons]< >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-cvc&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031929244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=1mHxfAjRPe4632ldow1H4Ov89HLjRi2HxHqwxYDAYOw%3D&reserved=0 >>>>> >>>> >>>> >>>> From: Paul Chandler <p...@redshots.com<mailto:p...@redshots.com>> >>>> Date: Tuesday, 15 December 2020 at 12:16 >>>> To: dev@cassandra.apache.org<mailto:dev@cassandra.apache.org> < >>>> dev@cassandra.apache.org<mailto:dev@cassandra.apache.org>> >>>> Subject: Re: Triggers >>>> Hi Greg, >>>> >>>> Andy is talking about Cassandra datacenters, which can easily be co >>>> located in the same physical datacenter. >>>> >>>> Paul >>>> >>>>> On 15 Dec 2020, at 12:10, Greg Oliver <gol...@microsoft.com.INVALID >>>> <mailto:gol...@microsoft.com.INVALID>> wrote: >>>>> >>>>> That's great in theory, but what if your customer is a national >>>> government (they require their data to remain within their borders) and >>>> there aren't enough DC's in nation to support multiple DC data >>>> distribution? >>>>> >>>>> To get the throughput needed (say - if the government announces a new >>>> program and 30M people try to sign up at the same time) CQRS seems a likely >>>> part of the solution. >>>>> >>>>> With Cassandra (and I'm definitely new to it), as I learn more it looks >>>> like a set of materialized views might be a way to achieve the goal. >>>>> >>>>> Thoughts? >>>>> >>>>> From: Andrew Cobley (Staff) <a.e.cob...@dundee.ac.uk<mailto: >>>> a.e.cob...@dundee.ac.uk>> >>>>> Sent: Tuesday, December 15, 2020 11:57 AM >>>>> To: dev@cassandra.apache.org<mailto:dev@cassandra.apache.org> >>>>> Subject: [EXTERNAL] Re: Triggers >>>>> >>>>> I may be wrong, but isn't the correct pattern for this to use two data >>>> centres? You write to one data centre, replicate to the other and read >>>> from that one. Or am misunderstanding ? >>>>> >>>>> Andy >>>>> >>>>> >>>>> [University of Dundee shield logo]< >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-home&data=04%7C01%7Cgolive%40microsoft.com%7Ca5f6a2b17aea4b0f1e6508d8a0f0931a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436302442412850%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=Ixrehte7KrUWOrVJEAEut%2FhQL2E2Ug0aRZbt6nFases%3D&reserved=0 >>>> < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-home&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031939190%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=nYMTRgqGct928YpEp0ymbzz5u2qhtvvre3MD461qTN8%3D&reserved=0 >>>>>> >>>>> >>>>> >>>>> Andy Cobley >>>>> Senior Lecturer, Program Director Data Science and Data Engineering MSc >>>>> School of Science and Engineering, University of Dundee >>>>> +44 (0)1382 385078 (Not at present) | a.e.cob...@dundee.ac.uk<mailto: >>>> a.e.cob...@dundee.ac.uk<mailto:a.e.cob...@dundee.ac.uk% >>>> 3cmailto:a.e.cob...@dundee.ac.uk>> >>>>> [University of Dundee Facebook]< >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-fb&data=04%7C01%7Cgolive%40microsoft.com%7Ca5f6a2b17aea4b0f1e6508d8a0f0931a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436302442412850%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=XMZmW3%2BbXmyJaVSDvAWPAe8e2y7ubJw%2BR7p2XBJJXVM%3D&reserved=0 >>>> < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-fb&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031939190%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=2YHCg6mskJwO73xH6VdVi0%2BYgBh%2Fp5qqvRLTZRQr5k0%3D&reserved=0>> >>>> [University of Dundee Twitter] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-tw&data=04%7C01%7Cgolive%40microsoft.com%7Ca5f6a2b17aea4b0f1e6508d8a0f0931a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436302442422802%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=vrqZgx%2BT1aeT%2FmKcweRupF2FkRlMiOTqcEXjTeLLFIw%3D&reserved=0 >>>> < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-tw&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031949151%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=bRUhO%2F%2FcguDgawVDiZKqXIIs7lCpCDBmNQ3bP53tlZs%3D&reserved=0>> >>>> [University of Dundee LinkedIn] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-li&data=04%7C01%7Cgolive%40microsoft.com%7Ca5f6a2b17aea4b0f1e6508d8a0f0931a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436302442422802%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=2mxK7SOrBF3Q%2Bze2a8n8zhPDLFjAoexb%2FFZz2vvn2qk%3D&reserved=0 >>>> < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-li&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031949151%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=LMICihjiJ5EmUR30V75tCRqc4X8%2F7%2Byp1MoPftwn2mA%3D&reserved=0>> >>>> [University of Dundee YouTube] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-yt&data=04%7C01%7Cgolive%40microsoft.com%7Ca5f6a2b17aea4b0f1e6508d8a0f0931a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436302442422802%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=AuOTbGCAYIzzylIlraKmZz8aopERMF2mKa%2FONYaTrDU%3D&reserved=0 >>>> < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-yt&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031959117%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=jP%2BCHsi2QkUxGgV7nFXvKvhslm6rM4jdxTOH3QUKSfg%3D&reserved=0>> >>>> [University of Dundee Instagram] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-ig&data=04%7C01%7Cgolive%40microsoft.com%7Ca5f6a2b17aea4b0f1e6508d8a0f0931a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436302442432759%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=gc28ZiYUWpTG%2F7knxx65ytSqzNJpAfZW1xSaDUYzaro%3D&reserved=0 >>>> < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-ig&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031959117%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=JQMkUXSFB9b7bQRdoMX%2FQTaKT0MOmv6WprbvpWHyx%2Fs%3D&reserved=0>> >>>> [University of Dundee Snapchat] < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-sc&data=04%7C01%7Cgolive%40microsoft.com%7Ca5f6a2b17aea4b0f1e6508d8a0f0931a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436302442432759%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=LV5u9t0Bv%2FAfiLpqv%2BQWsl07MTRjuBU8SnyS3QWgqmE%3D&reserved=0 >>>> < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-sc&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031969067%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=lHCjH5czLfppqxOwPxy%2BUqszDgE55s4JoBAbERpWJxg%3D&reserved=0 >>>>>> >>>>> One of the UK's top 20 universities< >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-strapline&data=04%7C01%7Cgolive%40microsoft.com%7Ca5f6a2b17aea4b0f1e6508d8a0f0931a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436302442442719%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=6lbV668OjpYmcQq8hgRXRepJmWCRWfj8xxCVbtJ1fHs%3D&reserved=0 >>>> < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-strapline&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031969067%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=dyZz8tMof%2BRYfRTlQZkvaesi0VWizcksMY21uB7c158%3D&reserved=0 >>>>>> >>>>> The Guardian University Guide 2021 >>>>> [Covid code of conduct icons]< >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-cvc&data=04%7C01%7Cgolive%40microsoft.com%7Ca5f6a2b17aea4b0f1e6508d8a0f0931a%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436302442442719%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=IuTeD3CgBxfqlULotR8tOx7KsYgZ9s%2Fu3ww4SyMv%2Bfg%3D&reserved=0 >>>> < >>>> https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fuod.ac.uk%2Fsig-cvc&data=04%7C01%7Cgolive%40microsoft.com%7Cb752cef4803d4deae42b08d8a0f4acd5%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637436320031979023%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=JGmKjzYxEKUXANjvr2kE06R6hxO3n9lArajgiXsswEg%3D&reserved=0 >>>>>> >>>>> >>>>> >>>>> From: Benjamin Lerer <benjamin.le...@datastax.com<mailto: >>>> benjamin.le...@datastax.com<mailto:benjamin.le...@datastax.com% >>>> 3cmailto:benjamin.le...@datastax.com>>> >>>>> Date: Tuesday, 15 December 2020 at 11:50 >>>>> To: dev@cassandra.apache.org<mailto:dev@cassandra.apache.org<mailto: >>>> dev@cassandra.apache.org%3cmailto:dev@cassandra.apache.org>> < >>>> dev@cassandra.apache.org<mailto:dev@cassandra.apache.org<mailto: >>>> dev@cassandra.apache.org%3cmailto:dev@cassandra.apache.org>>> >>>>> Subject: Re: Triggers >>>>> Hi Greg, >>>>> >>>>> Things are more tricky in an eventually consistent distributed system >>>> than >>>>> they are in a relational database. Even if the C* triggers were perfect >>>>> (and they are not) and your write and read tables were exactly the same, >>>>> there is no guarantee that all the updates created by the trigger from >>>> the >>>>> original mutations will be successfully delivered to your other table and >>>>> there are no entropy mechanisms to repair those problems. Overtime the >>>> data >>>>> in your write and read tables will just start to diverge. >>>>> >>>>> On Mon, Dec 14, 2020 at 2:02 PM Greg Oliver <gol...@microsoft.com.invalid >>>> <mailto:gol...@microsoft.com.invalid<mailto:gol...@microsoft.com.invalid% >>>> 3cmailto:gol...@microsoft.com.invalid>>> >>>>> wrote: >>>>> >>>>>> Hi all, >>>>>> >>>>>> My customer wants to use Cassandra together with the CQRS pattern. This >>>> is >>>>>> to say, they want to separate reads and writes to different tables, >>>>>> potentially in different keyspace or database. >>>>>> >>>>>> In my experience with relational databases I would set up a trigger on >>>> the >>>>>> "write" table such that on new row & update row events, a similar row >>>> would >>>>>> be inserted into the "read" table. >>>>>> >>>>>> I found a few examples of setting up a trigger on a Cassandra table and >>>>>> have replicated that on my system. But in reading the various Stack >>>>>> Overflow posts on the topic a persistent message saying "don't do it >>>> unless >>>>>> you really know what you're doing" pops up. >>>>>> >>>>>> Why? What are the cases for and against using triggers in Cassandra? >>>> What >>>>>> are the edge cases to avoid? What is the happy path? >>>>>> >>>>>> Thanks, >>>>>> Greg >>>>>> >>>>> >>>>> The University of Dundee is a registered Scottish Charity, No: SC015096 >>>> >>>> >>>> --------------------------------------------------------------------- >>>> To unsubscribe, e-mail: dev-unsubscr...@cassandra.apache.org<mailto: >>>> dev-unsubscr...@cassandra.apache.org> >>>> For additional commands, e-mail: dev-h...@cassandra.apache.org<mailto: >>>> dev-h...@cassandra.apache.org> >>>> >>>> The University of Dundee is a registered Scottish Charity, No: SC015096 >>>> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: dev-unsubscr...@cassandra.apache.org >> For additional commands, e-mail: dev-h...@cassandra.apache.org >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscr...@cassandra.apache.org > For additional commands, e-mail: dev-h...@cassandra.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@cassandra.apache.org For additional commands, e-mail: dev-h...@cassandra.apache.org