Posts

Showing posts from May, 2017

Heroku : Deployment

Image
Deployment There are many ways to deploy an app. You can use the command line and deploy using Git , or you can set up Pipelines to group stages of deployment, combined with Review Apps , which let you automatically deploy on a Pull Request. Finally, you can also deploy using a Heroku Button Replace myapp with the name of your app. Git Deploying with Git Git Cloning Existing Heroku Applications Deploying with Git Git is a powerful decentralized revision control system, and is the means for deploying apps to Heroku. You don’t need to be proficient with Git to use it for deploying code to Heroku, but you may find it valuable to learn the basics. Heroku apps expect the app directory structure at the root of the repository. If your app is inside a subdirectory in your repository, it won’t run when pushed to Heroku. Before you can push an app to Heroku, you’ll need to initialize a local Git repository and commit your files to it. For example, if you have an app in a

Salesforce : Annotations

Annotations An Apex annotation modifies the way that a method or class is used, similar to annotations in Java. Annotations are defined with an initial @ symbol, followed by the appropriate keyword. To add an annotation to a method, specify it immediately before the method or class definition. For example: global class MyClass { @future Public static void myMethod(String a){ //long-running Apex code } } Apex supports the following annotations. @AuraEnabled @Deprecated @Future @InvocableMethod @InvocableVariable @IsTest @ReadOnly @RemoteAction @TestSetup @TestVisible Apex REST annotations: @RestResource (urlMapping= '/ yourUrl ') @HttpDelete @HttpGet

Simple data sharing with Data Clips

Image
What is a Dataclip? A Dataclip is a secret URL that holds the results of a SQL query on a particular Heroku Postgres database. Given the unique, private URL for a query, a user can call up the most recently stored results of that query. Our system will automatically re-run the Dataclip from time to time in order to keep results fresh. By sharing a Dataclip URL the same way you would share the underlying data, any recipient can view that data within, download it as a CSV, or even embed it live into a tool like Google Sheets. When we share information on the Internet, we do so by sharing URLs.We send URLs for locations, books, videos, and even source code. Until now there hasn't been a convenient way to share data inside a database. That's why we're introducing Data Clips. They are a fast and easy way to unlock the data in your database in the form of a secure URL . Data Clips allow the results of SQL queries on a Heroku Postgres database to be easily shared. Simply

Redirecting a domain with HTTPS using Amazon S3 and CloudFront

Image
Configuring the Amazon S3 static site with SSL The first step is to configure a site in Amazon S3 that will trigger the redirect. The site will be used as the origin for the CloudFront distribution. Create a new Amazon S3 bucket with exactly the same name as the origin domain. For example, if the origin is www.example-1469917820.com , then you must give the bucket the same name. There are several ways to create a new bucket in Amazon S3, and this is beyond the scope of this article. In this particular case, I will use the Amazon AWS web console: You can use the region you prefer. If you don't have a specific preference, leave US Standard . Configure the bucket to redirect all requests to another host name . Select the bucket from the list, click Properties , and in the Static Website Hosting section configure the redirect. The value of the Redirect all requests to field should be the domain or host name where you want