solliancenet / MCW-Managed-open-source-databases-on-Azure

Other
1 stars 5 forks source link

Draft workshop reviews #2

Closed DawnmarieDesJardins closed 5 years ago

DawnmarieDesJardins commented 5 years ago

Please leave your review comments for our authors here.

midomsft commented 5 years ago

"All event data is stored written to an Azure Databricks for PostgreSQL managed Hyperscale (Citus) database" should read as "All event data is stored written to an Azure DATABASE for PostgreSQL managed Hyperscale (Citus) database" - Instructor Guide

joelhulen commented 5 years ago

@midomsft good catch. Fixed :)

thesqlpro commented 5 years ago

I'm assuming you want us to skip sections that say things like: [insert your custom workshop content here . . . ]

thesqlpro commented 5 years ago

Diagrams in the student and instructor guides are clear, and very nicely put together. Thumbs up!

My only question is around why Data Lake is not specified as Gen1 or Gen2.

waltermyersiii commented 5 years ago

Correct "Postres" to "PostgreSQL" in WDS deck, slide 19. :-)

julienmichel commented 5 years ago

In the hands-on lab, Task 6: Deploy Azure Database for PostgreSQL : you need to specify which type of PostgreSQL instance they need to choose : Single server or Hyperscale (Citus) server group - PREVIEW.

thesqlpro commented 5 years ago

In the prep for the lab, this part confused me: Create a variable to hold your resource group name. This will be used when creating other resources. Replace SUFFIX with your Microsoft alias, initials, or another value to ensure uniqueness. resourcegroup=hands-on-lab-SUFFIX Create a variable to hold your resource group location name. Replace the westus location with a location closest to you. This same location will be used when provisioning other Azure resources. location=westus For a list of valid location names, execute: az account list-locations -o table Enter the following command to create a subscription group. az group create --name $resourcegroup --location $location

Instead of creating the variables, because it didn't work, I just hardcoded the values when creating the resource group. I've never used Bash before, so I probably did something wrong with the variable creation. But what I did was just define the variable like this and press enter:

variablename = value

I went back to try it again, and did not include the spaces in my variable definition. I think it is worthwhile to put a note in there about that as many of us come from different programming languages and are used to that. Anyway, it works now.

julienmichel commented 5 years ago

Try without spaces.

midomsft commented 5 years ago

Hey, just completed the "Before the HOL" section - all works fine, great job :-)

One question - on task 8 it says "From your LabVM, download the starter files by downloading a .zip copy of the Cosmos DB real-time advanced analytics GitHub repo..."

Did I miss a step where you have to create a LabVM? I didn't notice another prerequisities section at all (could be me of course!) - does a user need to create a VM or can they use their own laptop?

julienmichel commented 5 years ago

Is it normal that task 8 ask to redirect to "Cosmos DB real-time advanced analytics GitHub repo" ?

julienmichel commented 5 years ago

In the exercise 1, I was not able to connect to the instance because of the firewall. I needed to add a rule to allow all the IPs to connect (0.0.0.0 to 255.255.255.255) because it was not recognizing my public IP neither my private IP. I'm connecting through the MS corp network.

midomsft commented 5 years ago

Exercise 3 (Kafka setup) for the Hands on Lab instruction says -

"Within the folder, open the appconfig.json file in a text editor, such as Notepad."

However the actual file (and screenshot in the manual) show appsettings.json

Probably needs updating so instructions refer to correct file.

midomsft commented 5 years ago

kafkaerror

Hey, reaching a breaking error in exercise 3. I've changed the appsettings.json, but when I try and run KafkaProducer.exe I get the error attached. Should there be a lib/[dlls] folder included in the app source or have I missed a preq somewhere? I've looked but can't see anything.

I'm running the windows version of the app.

joelhulen commented 5 years ago

@midomsft Sorry about that. I've just committed an update that includes all the missing files if you want to try downloading the new version and try again.

midomsft commented 5 years ago

Thanks @joelhulen that's perfect, now working :-)

midomsft commented 5 years ago

Ok completed both the instructor guide and hands on lab walk through now. Aside from a couple of issues (responded to above) this all went smoothly. Excellent job!

joelhulen commented 5 years ago

Great, and thank you! I will address all non-breaking issues once the review process is complete.

thesqlpro commented 5 years ago

I'm going to skip this task and come back to it when I get an answer, but I know other things will not happen unless it is fixed. Details below.

Task 3 Step 8 giving me an insuffienct privelages error:

ayman@Azure:~$ az ad sp create-for-rbac -n "wwi-oss-sp" --role "Storage Blob Data Contributor" --scopes /subscriptions/XXXXXXXXXXXXXXXXXXXXXX/resourceGroups/hands-on-lab-ayelghaz/providers/Microsoft.Storage/storageAccounts/wwiadlsayelghaz Changing "wwi-oss-sp" to a valid URI of "http://wwi-oss-sp", which is the required format used for service principal names Found an existing application instance of "2b7a55ff-62f9-49d6-8324-c236c362c9a2". We will patch it Insufficient privileges to complete the operation.

joelhulen commented 5 years ago

@thesqlpro Are you using your own pay-as-you-go or MSDN-based Azure subscription, or a sponsored subscription provided by Microsoft? Please look at the Requirements listed in the Before the Hands-on Lab document. You must have permissions within your Azure subscription to create an App Registration and service principal within Azure Active Directory.

thesqlpro commented 5 years ago

@joelhulen I'm using our internal MS subscription. I've done app registration before in AAD. I'll look into repeating these steps, but I don't know if my MSDN subscription still works.

thesqlpro commented 5 years ago

@joelhulen I just skipped the step and completed the rest of the lab. I manually inserted data into the Postgres events table to test out my dataframe and the PowerBI report. It wasn't streaming because of that step that failed due to permissions (our exchange above). I will try to reproduce this lab if I can get my MSDN working properly.

Overall, the lab is easy to follow. Clean code. Everything works as expected. I really enjoyed working on this and learning. The comments in the notebook are easy to follow.

Thank you for including me in this!!

samay-sharma commented 5 years ago

Great work @joelhulen . I'm still going through the content but wanted to add in feedback on the trainer / student guides and the outline sections. I'll go through the hands on labs tomorrow and then add feedback on that as a separate comment.

I'm adding comments as checkboxes to make it easy for you to address.

Outline.md file :

Reason: Pre-aggregated data seems a bit too specific for this stage of the discussion.

WDS Trainer Guide

Preferred Solution

https://github.com/solliancenet/MCW-Managed-open-source-databases-on-Azure/blob/master/Whiteboard%20design%20session/WDS%20trainer%20guide%20-%20Managed%20open%20source%20databases%20on%20Azure.md#preferred-solution

Scale

Process data while generating roll-ups

Resilient stream processing

Checklist of preferred objection handling

https://github.com/solliancenet/MCW-Managed-open-source-databases-on-Azure/blob/master/Whiteboard%20design%20session/WDS%20trainer%20guide%20-%20Managed%20open%20source%20databases%20on%20Azure.md#checklist-of-preferred-objection-handling

I don't think we need to get into coordinator and workers at this stage.

Customer quote

Migrating our PostgreSQL databases to Azure with the Hyperscale server group (Citus) deployment option...

A few general comments

elsantorini commented 5 years ago

@joelhulen, really well done! It's straight forward with no pitfalls. Just a typo in the pre-lab, where the title Task 3 is used twice.

miyamam commented 5 years ago

Preparation:

elsantorini commented 5 years ago

@miyamam, In the trainer guide it explains what were the customer's struggles, and it says that they have multiple tenants, and that they need to shard the Database to make queries run faster.

miyamam commented 5 years ago

@elsantorini But current WWI's data size is so small that single instance is enough.

joelhulen commented 5 years ago

@miyamam I agree about data size, but since the Citus-specific capabilities of the Hyperscale version are the things being highlighted and used in the lab, it is a requirement for successful completion of the lab, and for the scenario. We could provide a much larger test database, but that would be an unnecessarily large dependency for the lab.

samay-sharma commented 5 years ago

So, I went through the prep for HoL and had the following comments.

joelhulen commented 5 years ago

@samay-sharma I've promised to hold off on commenting until after the review ends, but you bring up some good points (and you're currently blocked).

samay-sharma commented 5 years ago

Thanks @joelhulen . So, I tried to complete the Hands on Lab but had a few issues:

Time
2019-06-26 17:01:01 PDT
Message
Cluster terminated. Reason: Cloud Provider Launch Failure

A cloud provider error was encountered while launching worker nodes. See the Databricks guide for more information.

Azure error code: ServerUnreachable

Azure error message: Azure API server unreachable, please try again later.

I don't know if this is something I did or if it is an issue. Can you help me with this?

For the Postgres / Citus pieces, I was able to work through all of them (just without data) and have a few inputs. I'll put those in my next comment.

samay-sharma commented 5 years ago

I also think we should include 2 lines to explain what create_distributed_table does. We can say “ that we are sharding each of the tables on customer_id column. “ This is done by calling create_distributed_table function. When you run this function, Citus inserts metadata marking the table as distributed and creates shards on the worker nodes. Then incoming data into these tables is routed to the right node based on customer id.

Then, we can continue with:

Because we are sharding on the same ID for our raw events table and rollup tables, our data stored in both types of table are automatically co-located for us by Citus....

We should also create a separate section for create rollup tables.

We should also explain why rollup tables are useful. Something like:

In this task, you will create two rollup tables for storing aggregated data pulled from the raw events table. Rollup tables allow you to pre-aggregate data for certain commonly run queries so that you don’t need to aggregate the data repeatedly during query time. This allows you to have longer retention, compression of results and faster query time by reducing the amount of data to scan.

The rollup tables you will create are...

Exercise 2

Exercise 4:

So, maybe we can do something like this:

You still need to be able to keep track of which events have already been aggregated. We will do that by tracking sequence number. There’s a few other approaches to do this and you can read more about why this approach is recommended here (link to blog post).

Task 2:

A few comments on the queries we have in task 2 and structuring.

If we do that, we can add a description saying: “The following queries don’t have customer id in the filter so these queries will be executed in parallel across all different nodes in the cluster leading to fast query performance.

For the queries with the filter, we can say “As these queries have a filter on customer_id, Citus will route the queries to only the node which has the data for that particular customer without needing to touch data for the remaining customers. This leads to faster performance as you need to scan only a small portion of the data.

samay-sharma commented 5 years ago

@joelhulen : That would be my first round of feedback focussed primarily on the Postgres / Citus pieces. There is an important point around me not able to do the spark cluster creation and hence ingestion and the visualization piece. If you can help me fix the spark one (the other one I should be able to fix on my own), I can complete the rest of the lab and provide more complete feedback.

joelhulen commented 5 years ago

@samay-sharma in the pre-requisites listed in Before the HOL, we state the following:

  1. Microsoft Azure subscription must be pay-as-you-go or MSDN.
    • Trial subscriptions will not work.
    • IMPORTANT: To complete the OAuth 2.0 access components of this hands-on lab you must have permissions within your Azure subscription to create an App Registration and service principal within Azure Active Directory.

If you are using a Microsoft-provided Azure subscription, then you will most likely not be able to complete the OAuth 2.0 access components.

In Task 3, Step 8, you need to make sure you've replaced the -scope value with your own. Again, if you did then it may have to do with your permissions as described above.

I am not sure why you cannot create a cluster. That seems like a platform-related error. Maybe try again later? Worst case, delete the Databricks workspace and re-create it.

joelhulen commented 5 years ago

@samay-sharma Were you ever able to complete the lab, given the information above? Today I plan on applying changes to the MCW based on feedback here, since feedback was officially closed EOD Wednesday and I need to finalize today. Please let me know soon if you have additional feedback or if you could not complete for some reason.

samay-sharma commented 5 years ago

@joelhulen : I haven't. The databricks cluster creation still hasn't worked. I retried creating the cluster and still gives me the same error.

I'm not sure how to do the Oauth 2.0 access components. I don't have any other subscription other than my Microsoft one. So, not sure how to take care of that.

The PowerBI stuff is fine.

I think my major feedback has been around the Citus pieces and it looks like others were able to do the lab successfully, so this seems something specific to my account.

joelhulen commented 5 years ago

I have addressed all the feedback and made a PR to the official Microsoft repo: https://github.com/microsoft/MCW-Real-time-data-with-Azure-Database-for-PostgreSQL-Hyperscale

Thank you so much, everyone, for taking your time to review this MCW. It was great working with you!