cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Fire an event from a service

SOLVED
rmórocz
1-Newbie

Fire an event from a service

Hi!

How can i fire the event from inside the service code?

As an example: if validation fails inside the service i would like to fire an ValidationFails event.

Is this possible?

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions

About the Log, if you want to record debug type logs, you should activate Debug Log level:

Composer > Monitoring > Script

On the Log View Mashup

Logs > Settings  ( tab )

Inside settings tab:

Script Log --> New Settings = Debug

View solution in original post

4 REPLIES 4

me.name_of_the_event(params);

Hi Carles!

I have this in my code

(Test is an event)

Code of my test service:

var params = {

  Message: "Hello" /* STRING */,

};

me.Test(params);

And i have a subscription to this event (enabled). In the subscription i have this:

logger.debug(eventData.Message);

But "Hello" is still not showing in the script log.

What is missing?

About the Log, if you want to record debug type logs, you should activate Debug Log level:

Composer > Monitoring > Script

On the Log View Mashup

Logs > Settings  ( tab )

Inside settings tab:

Script Log --> New Settings = Debug

View solution in original post

That was the missing tile in the puzzle.

Thanks

Announcements