Skip to content

Commit f4d688c

Browse files
author
vijaykanthm28
committed
copyright year change and skews changes
1 parent 84243a5 commit f4d688c

39 files changed

+124
-53
lines changed

carton/assemblies.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

carton/assembly.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

carton/bind/binder.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

carton/component.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

carton/megd_process.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

carton/payload.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

carton/policy_ops.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

carton/req_operator.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

carton/req_parser.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

conf/mailer/balance.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ <h2 class="balance">Balance !</h2>
7474
</tr>
7575
<tr align="center">
7676
<td class="pad_b30">
77-
<p>© Megam 2016 All rights reserved.</p>
77+
<p>© Megam 2017 All rights reserved.</p>
7878
</td>
7979
</tr>
8080
</table>

conf/mailer/failure.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ <h3 style="font-size: 28px; font-weight: normal;">Hey <b>{{.email}}</b></h3>
2222
<td align="center" width="30%"><img src="https://s3-ap-southeast-1.amazonaws.com/megampub/images/mailers/error.png"></td>
2323
<td align="left" style="padding: 30px;" >
2424
<h2 style="margin: 30px 0px;"> Failed !</h2>
25-
<p>Unable to launch application {{.appname}} </p>
25+
<p>Unable to launch application {{.appname}} </p>
2626
<p>Please contact your administrators to solve this problem</p>
2727
</td>
2828
</tr>
@@ -49,7 +49,7 @@ <h2 style="margin: 30px 0px;"> Failed !</h2>
4949
</tr>
5050
<tr align="center">
5151
<td style="padding: 30px;">
52-
<p>© Megam 2016 All rights reserved.</p>
52+
<p>© Megam 2017 All rights reserved.</p>
5353
</td>
5454
</tr>
5555
</table>

conf/mailer/insufficientfunds.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ <h2 style="margin: 30px 0px;"> Failed !</h2>
4646
</tr>
4747
<tr align="center">
4848
<td style="padding: 30px;">
49-
<p>© Megam 2016 All rights reserved.</p>
49+
<p>© Megam 2017 All rights reserved.</p>
5050
</td>
5151
</tr>
5252
</table>

conf/mailer/invite.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ <h2 style="margin: 30px 0px;">Use as a team!</h2>
5050
</tr>
5151
<tr align="center">
5252
<td style="padding: 30px;">
53-
<p>© Megam 2016 All rights reserved.</p>
53+
<p>© Megam 2017 All rights reserved.</p>
5454
</td>
5555
</tr>
5656
</table>

conf/mailer/onboard.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ <h2 style="margin: 30px 0px;">Greetings !</h2>
4949
</tr>
5050
<tr align="center">
5151
<td style="padding: 30px;">
52-
<p>© Megam 2016 All rights reserved.</p>
52+
<p>© Megam 2017 All rights reserved.</p>
5353
</td>
5454
</tr>
5555
</table>

conf/mailer/quotaoverdue.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ <h2 style="margin: 30px 0px;"> Failed !</h2>
4646
</tr>
4747
<tr align="center">
4848
<td style="padding: 30px;">
49-
<p>© Megam 2016 All rights reserved.</p>
49+
<p>© Megam 2017 All rights reserved.</p>
5050
</td>
5151
</tr>
5252
</table>

conf/mailer/reset.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ <h2 style="margin: 30px 0px;">Forgot password !</h2>
6767
</tr>
6868
<tr align="center">
6969
<td style="padding: 30px;">
70-
<p>© Megam 2016 All rights reserved.</p>
70+
<p>© Megam 2017 All rights reserved.</p>
7171
</td>
7272
</tr>
7373
</table>

conf/mailer/running.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ <h2 style="margin: 30px 0px;">Running !</h2>
4848
</tr>
4949
<tr align="center">
5050
<td style="padding: 30px;">
51-
<p>© Megam 2016 All rights reserved.</p>
51+
<p>© Megam 2017 All rights reserved.</p>
5252
</td>
5353
</tr>
5454
</table>

conf/mailer/skews_warning.html

+69
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
<html>
2+
<head>
3+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
4+
<title>Failed to launch !</title>
5+
</head>
6+
<div style="font-family: sans-serif; font-size: 14px; color: #8a9ca2;">
7+
<body bgcolor="#eaf0f2">
8+
<table cellspacing="0" cellpadding="0" border="0" width="100%">
9+
<tr>
10+
<td bgcolor="#eaf0f2" align="center">
11+
<table width="650px" cellspacing="0" cellpadding="3" class="container">
12+
<tr>
13+
<td align="center">
14+
<img style="margin: 30px;" src="{{.logo}}">
15+
</td>
16+
</tr>
17+
<tr>
18+
<td align="center">
19+
<h3 style="font-size: 28px; font-weight: normal;">Hey <b>{{.email}}</b></h3>
20+
<table width="500px" cellspacing="0" cellpadding="3" >
21+
<tr style=" background-color: #fff;">
22+
<td align="center" width="30%"><img src="https://s3-ap-southeast-1.amazonaws.com/megampub/images/mailers/piggy-bank-icon.png"></td>
23+
<td align="left" style="padding: 41px;padding-top: 3px;padding-bottom: 43px;" >
24+
<h2 style="margin: 30px 0px;"> Failed !</h2>
25+
<p>I hope you're having a great day today. There are some issues on your account that need your attention. There is an invoice(s) that are past due on your account. Please be aware that any invoices more than {{.SoftGracePeriod}} days OR credit {{.SoftLimit}} amount past due are subject to {{.SoftAction}} and more than {{.HardGracePeriod}} days OR credit {{.HardLimit}} amount past due are subject to {{.HardAction}}.</p>
26+
27+
<p>GENERATED AT: {{.action_trigger_at}}</p>
28+
<p>DUE DATE: {{.next_action_due_at}}</p>
29+
30+
<p>This mail is to intimate for {{.action}}</p>
31+
32+
<p>If next due over dated {{.appname}} will be {{.next_action}}.</p>
33+
34+
<p>If you can please make a payment on your outstanding invoices to avoid cancellation of your services we would greatly appreciate it.</p>
35+
36+
<p>If your account balance is zero and your invoice still shows as unpaid, you may need to apply credit to the invoice. </p>
37+
38+
<p>Please be aware that any servers that are reconnected after termination will incur a $10 reconnection fee.</p> </td>
39+
</tr>
40+
</table >
41+
<table width="500px" cellspacing="0" cellpadding="3" style=" background-color: #fff;" >
42+
43+
<td align="center" style="padding: 45px;">
44+
<a href="{{.nilavu}}"><img src="https://s3-ap-southeast-1.amazonaws.com/megampub/images/mailers/add_funds.png"></a>
45+
</td>
46+
</tr>
47+
</table>
48+
</td>
49+
</tr>
50+
<tr align="center">
51+
<td width="28px" style="padding: 30px;">
52+
<a href="https://www.github.com/megamsys"><img src="https://s3-ap-southeast-1.amazonaws.com/megampub/images/mailers/git.png"></a>
53+
<a href="https://plus.google.com/105742854503471299978/about"><img src="https://s3-ap-southeast-1.amazonaws.com/megampub/images/mailers/plus.png"></a>
54+
<a href="https://facebook.com/megamsys"><img src="https://s3-ap-southeast-1.amazonaws.com/megampub/images/mailers/fb.png"></a>
55+
<a href="https://twitter.com/megamsys"><img src="https://s3-ap-southeast-1.amazonaws.com/megampub/images/mailers/twitter.png"></a>
56+
</td>
57+
</tr>
58+
<tr align="center">
59+
<td style="padding: 30px;">
60+
<p>© Megam 2017 All rights reserved.</p>
61+
</td>
62+
</tr>
63+
</table>
64+
</td>
65+
</tr>
66+
</table>
67+
</body>
68+
</div>
69+
</html>

git/git.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

git/git_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

marketplaces/req_parser.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

metrix/one.go

+15-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,21 @@ func (on *OpenNebula) DeductBill(c *MetricsCollection) (e error) {
3636
}
3737

3838
if on.SkewsActions[constants.ENABLED] == constants.TRUE {
39-
e = eventSkews(mc, on.SkewsActions)
39+
if len(mc.QuotaId) > 0 {
40+
quota, err := carton.NewQuota(mc.AccountId, mc.QuotaId)
41+
if err != nil {
42+
og.Debugf("quota get error : %s", err.Error())
43+
}
44+
action = alerts.QUOTA_UNPAID
45+
if quota.Status == "paid" {
46+
continue
47+
}
48+
on.SkewsActions[constants.SKEWS_TYPE] = "vm.quota.unpaid"
49+
} else {
50+
action = alerts.SKEWS_ACTIONS
51+
on.SkewsActions[constants.SKEWS_TYPE] = "vm.ondemand.bills"
52+
}
53+
e = eventSkews(mc, action, on.SkewsActions)
4054
}
4155

4256
}

metrix/scylla_output.go

+3-15
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ func mkBalance(s *Sensor, du map[string]string) error {
2828
m := s.Metrics.Totalcost(du)
2929
mi[constants.ACCOUNTID] = s.AccountId
3030
mi[constants.ASSEMBLYID] = s.AssemblyId
31+
mi[constants.ASSEMBLIESID] = s.AssembliesId
3132
mi[constants.ASSEMBLYNAME] = s.AssemblyName
3233
mi[constants.CONSUMED] = m
3334
mi[constants.START_TIME] = s.AuditPeriodBeginning
@@ -54,28 +55,15 @@ func mkBalance(s *Sensor, du map[string]string) error {
5455
return newEvent.Write()
5556
}
5657

57-
func eventSkews(s *Sensor, skews map[string]string) error {
58+
func eventSkews(s *Sensor, action alerts.EventAction, skews map[string]string) error {
5859
var action alerts.EventAction
5960
mi := make(map[string]string, 0)
6061

6162
mi[constants.ACCOUNTID] = s.AccountId
6263
mi[constants.ASSEMBLYID] = s.AssemblyId
64+
mi[constants.ASSEMBLIESID] = s.AssembliesId
6365
mi[constants.ASSEMBLYNAME] = s.AssemblyName
6466
mi[constants.QUOTAID] = s.QuotaId
65-
if len(s.QuotaId) > 0 {
66-
quota, err := carton.NewQuota(s.AccountId, s.QuotaId)
67-
if err != nil {
68-
return err
69-
}
70-
action = alerts.QUOTA_UNPAID
71-
if quota.Status == "paid" {
72-
return nil
73-
}
74-
mi[constants.SKEWS_TYPE] = "vm.quota.unpaid"
75-
} else {
76-
action = alerts.SKEWS_ACTIONS
77-
mi[constants.SKEWS_TYPE] = "vm.ondemand.bills"
78-
}
7967

8068
for k, v := range skews {
8169
mi[k] = v

metrix/sensor.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/box.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/box_compute.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/docker/utils.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/one/actions.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/one/actions_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/one/hc.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/one/hc_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/one/image.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/one/image_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/one/mk_provisioner.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/one/provisioner.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/one/provisioner_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

provision/provision.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
** Copyright [2013-2016] [Megam Systems]
2+
** Copyright [2013-2017] [Megam Systems]
33
**
44
** Licensed under the Apache License, Version 2.0 (the "License");
55
** you may not use this file except in compliance with the License.

0 commit comments

Comments
 (0)