Re: [INCOMING] Metron 0.4.0 release (RC3)

2017-06-02 Thread Christian Tramnitz
While not a must-have, METRON-941 / PR-579 should be trivial enough to include 
it.


Thanks,
   Christian


On 01.06.17, 23:17, "Matt Foley"  wrote:

Hi all,

Now that METRON-844 is in, I plan to proceed with the 0.4.0 release 
candidate.  I think 844 was the last item we considered a must-have for the 
0.4.0 release, and we want to post this release before incorporating several 
broad changes that should go in the NEXT release not this one (METRON-777, 942, 
975, 876, etc.).

 

Let me know if anything else is considered must-have for 0.4.0, but I’m 
going to proceed unless I hear otherwise.  Current HEAD is SHA1= 85872bd686 
(METRON-858), I’ll go from there.

 

Thanks,

--Matt





[GitHub] metron pull request #606: METRON-980: Short circuit operations for Stellar

2017-06-02 Thread justinleet
Github user justinleet commented on a diff in the pull request:

https://github.com/apache/metron/pull/606#discussion_r119832707
  
--- Diff: 
metron-platform/metron-common/src/test/java/org/apache/metron/common/stellar/StellarTest.java
 ---
@@ -634,6 +679,40 @@ public void testLogicalFunctions() throws Exception {
 Assert.assertTrue(runPredicate("not(IN_SUBNET(ip_dst_addr, 
'192.168.0.0/24'))", v-> variableMap.get(v)));
   }
 
+  @Test
+  public void testShortCircuit_conditional() throws Exception {
+Assert.assertEquals("foo", run("if true then 'foo' else 
THROW('expression')", new HashMap<>()));
+Assert.assertEquals("foo", run("true ? 'foo' : THROW('expression')", 
new HashMap<>()));
+Assert.assertEquals("foo", run("if false then THROW('exception') else 
'foo'", new HashMap<>()));
+Assert.assertEquals("foo", run("false ? THROW('exception') : 'foo'", 
new HashMap<>()));
+Assert.assertEquals(true, run("RET_TRUE(if true then 'foo' else 
THROW('expression'))", new HashMap<>()));
+Assert.assertEquals("foo", run("if true or (true or THROW('if 
exception')) then 'foo' else THROW('expression')", new HashMap<>()));
+Assert.assertEquals("foo", run("if true or (false or THROW('if 
exception')) then 'foo' else THROW('expression')", new HashMap<>()));
+Assert.assertEquals("foo", run("if NOT(true or (false or THROW('if 
exception'))) then THROW('expression') else 'foo'", new HashMap<>()));
+Assert.assertEquals("foo", run("if NOT('metron' in [ 'metron', 
'metronicus'] ) then THROW('expression') else 'foo'", new HashMap<>()));
+  }
+
+  @Test
+  public void testShortCircuit_boolean() throws Exception {
+Assert.assertTrue(runPredicate("'metron' in ['metron', 'metronicus', 
'mortron'] or (true or THROW('exception'))", x -> null));
--- End diff --

Adding a case like:
`Assert.assertTrue(runPredicate("NOT(true) or THROW('exception'))", x -> 
null));` doesn't parse and I would expect it to.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] metron pull request #606: METRON-980: Short circuit operations for Stellar

2017-06-02 Thread justinleet
Github user justinleet commented on a diff in the pull request:

https://github.com/apache/metron/pull/606#discussion_r119831834
  
--- Diff: 
metron-platform/metron-common/src/test/java/org/apache/metron/common/stellar/StellarTest.java
 ---
@@ -33,19 +31,66 @@
 import org.reflections.Reflections;
 import org.reflections.util.ConfigurationBuilder;
 
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Map;
+import java.util.*;
 
 import static org.apache.metron.common.utils.StellarProcessorUtils.run;
 import static 
org.apache.metron.common.utils.StellarProcessorUtils.runPredicate;
 
 @SuppressWarnings("ALL")
 public class StellarTest {
 
+  @Stellar(
+  description="throw exception",
+  name="THROW",
+  params = {
+   "message - exception message"
+  },
+  returns="nothing"
+  )
+  public static class Throw implements StellarFunction {
+
+@Override
+public Object apply(List args, Context context) throws 
ParseException {
+  throw new IllegalStateException(Joiner.on(" ").join(args));
+}
+
+@Override
+public void initialize(Context context) {
+
+}
+
+@Override
+public boolean isInitialized() {
+  return true;
+}
+  }
+
+  @Stellar(
--- End diff --

Could you change the description, params, and returns to not be what's in 
THROW?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


Re: Storm Slots - creating and deploying parsers

2017-06-02 Thread Simon Elliston Ball
Correct, you need to make sure you have sufficient slots in Ambari. Personally 
I tend to just add a bunch of ports at install, and create slots across the 
supervisors, but you can always add more supervisors too.

Simon

> On 2 Jun 2017, at 18:10, Otto Fowler  wrote:
> 
> What is our current thinking on storm slot requirements for adding parsers
> to the system?  Please correct me if I am wrong but I don’t think the rest
> services do this, so we have to go into ambari.



Storm Slots - creating and deploying parsers

2017-06-02 Thread Otto Fowler
What is our current thinking on storm slot requirements for adding parsers
to the system?  Please correct me if I am wrong but I don’t think the rest
services do this, so we have to go into ambari.


Re: Storm Slots - creating and deploying parsers

2017-06-02 Thread Otto Fowler
Simon,
Can you write a blurb on your best practices?  I would like to add it to
METRON-947 steps and documentation.

Maybe the Jira for the Management UI would be to have something tell you if
you don’t have enough slots to activate a parser or something?


On June 2, 2017 at 13:23:30, Simon Elliston Ball (
si...@simonellistonball.com) wrote:

Correct, you need to make sure you have sufficient slots in Ambari.
Personally I tend to just add a bunch of ports at install, and create slots
across the supervisors, but you can always add more supervisors too.

Simon

> On 2 Jun 2017, at 18:10, Otto Fowler  wrote:
>
> What is our current thinking on storm slot requirements for adding
parsers
> to the system? Please correct me if I am wrong but I don’t think the rest
> services do this, so we have to go into ambari.


Re: Default Management UI username and password

2017-06-02 Thread Otto Fowler
How do you change that if you start with ambari now and not from the cli?


On June 2, 2017 at 13:19:44, Simon Elliston Ball (
si...@simonellistonball.com) wrote:

If you start with —spring.profiles.active=dev it will auto-create a user
(user / password)

To change it (and frankly for anything other than testing, you have to
setup a proper DB. Right now you just update the password in the DB.

We should probably push the authentication into kerberos with Spenego or
some such for consistency.

Simon

> On 2 Jun 2017, at 17:55, Otto Fowler  wrote:
>
> For the life of me, I cannot find it, can someone point me in the right
> direction?
> Also how would you change it?


[GitHub] metron issue #605: Metron-979 markdown errors in site-book

2017-06-02 Thread justinleet
Github user justinleet commented on the issue:

https://github.com/apache/metron/pull/605
  
@mattf-horton is correct, I am +1 on this. Thanks a lot for working on 
this, it's great to have.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] metron pull request #605: Metron-979 markdown errors in site-book

2017-06-02 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/metron/pull/605


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] metron issue #605: Metron-979 markdown errors in site-book

2017-06-02 Thread mattf-horton
Github user mattf-horton commented on the issue:

https://github.com/apache/metron/pull/605
  
Thanks, I'm going to take @JonZeolla  and @justinleet 's comments as +1s 
and get this in for 0.4.0.  Thanks.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] metron issue #605: Metron-979 markdown errors in site-book

2017-06-02 Thread JonZeolla
Github user JonZeolla commented on the issue:

https://github.com/apache/metron/pull/605
  
Go for it.  Just trying to make sure it got in under a documentation
related Jira without a ton of overhead.

Jon

On Fri, Jun 2, 2017, 6:23 PM Matt Foley  wrote:

> Hi @JonZeolla  , sorry if I moved too fast.
> I consider your patch to be a valuable contribution in its own right. 
Since
> it's non-intersecting with the changes I made, I hereby give it a +1 👍
> With your permission I'll commit it under the same jira, credited to you.
> If you prefer to do so yourself, let me know.
>
> —
> You are receiving this because you were mentioned.
>
>
> Reply to this email directly, view it on GitHub
> , or 
mute
> the thread
> 

> .
>
-- 

Jon



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---