10

As with any programming language, what are the standard naming conventions to be followed while writing Mule flows? I found camel-case convention has been followed in Mule in Action book.What is the standard format for Mule naming convention.

Can any suggest the standard option?

tom
  • 5
  • 2
Ram Bavireddi
  • 1,139
  • 1
  • 19
  • 43

10 Answers10

8

There is no such thing as a naming convention for Mule. You could try to apply the same rules Mule community developers follow, but those are not strictly for Mule Applications.

At the same time it does make sense to follow the same naming conventions than the IoC container of Spring given that Mule is a sort of specialization of it.

Attila
  • 3,206
  • 2
  • 31
  • 44
Víctor Romero
  • 5,107
  • 2
  • 22
  • 32
3

I've made a training on MuleSoft "MuleSoft.U Developer Essentials" and all the flows they named was like that: nameOfTheFlow. So the first character was always at lower case and the name always ended with "Flow". Also, the first word was always what the flow was doing, for example: "getPermissionsFlow" or "postUserFlow". So, based on my experience, that was the convention the course brought to me.

tom
  • 5
  • 2
Gabriel
  • 952
  • 10
  • 31
2

There is no specific naming convention thumb rules. Java naming style would be good. Most of the case the enterprise for whom your are developing the application will hold their own naming convention standard.

Based on my experience naming conventions with a defnite symantics eg MF_Employee_RegService were MF is mule flow , Employee department , Registration service

camel-case is also a good option.

ARUN KUMAR
  • 89
  • 1
  • 9
  • 2
    This question has already been answered and accepted. Refrain from giving new answers to very old questions (1 month or older) unless your answer provides a significant amount of content not found in other answers or comments. –  Feb 13 '15 at 01:09
2

You can define your own There is no compulsion. For better maintainability and readability you can prefix targetSystemName for the flows which Hits the endpoint fallowed by the activityName that the flow accomplishes example:crm_fetchCustomerDetails, you can prefix common or util fro the flows which are common across your project.

2

Mule is a integration platform and not a programming language. There is no specific naming convention. But using the Java naming conventions will be good.

cryptic_star
  • 1,863
  • 3
  • 26
  • 47
1

There is no specific rules for naming Conventions for Mule Flows. Its always the best if you name them from maintainability and readability perspective. MuleBooks follow CAMEL Notation. FYR.some standards can be found at mule repo

1

There are no such hard rules for naming Conventions for Mule Flows. We should always follow same kind of naming pattern.MyFlow_flow1(using underscore) is preffered. MuleBooks follow CAMELcase Notation.

Soumya
  • 59
  • 7
1

Here are the best practices:

  1. Application name: In lowercase(Ex: myapplication)
  2. Config.xml file name(app/...) :Camel case. ex. myApplication.xml
  3. Flow name : Camel case. Reflects the purpose of a flow and ends with word Flow i.e myApplicationFlow
  4. Subflow name : Camel case. Reflects the purpose of a sub flow and ends with word sub_flow/subFlow i.e connectDBSub_flow/connectDBSubFlow

For rest of the things follow java standards cheers :)

Balwant Kumar Singh
  • 1,158
  • 4
  • 24
  • 48
-1

Flow name starts with FL_ and Subflow name Starts with SF_ would be increase code readability.

Venu
  • 19
  • 3
-1

These are some Naming conventions we use.

  • Flow Names Flows are generally used recursively through project, so proper naming could remove ambiguity throughout project. here are some examples Ex. gmail_mail_fetch_Flow.xml, gmail_mail_send_Flow.xml, gmaps_distance_fetch_Flow.xml

as one can really grasp the overall operation of flow by looking at its name.

Hemin
  • 712
  • 1
  • 14
  • 29