I’m trying to make a trial service using backendless.
I would like to use variables shared in the scope of each sessions.
I found only 2 ways for handling variables in codeless logic, Varible and Cache.
It looks for me that variables are in page scope, and caches are in global scope.
Are there any way to share variables in session scope?
Thanks in advance,
Manabu from NoCodeCamp in Japan.
Are you working on UI or Server-side logic? The screenshot you shared shows server-side logic, however, the original message made me think you’re working on the UI.
If you’re working on the business logic, there is no state - every invocation of the service is stateless.
It’s bad news for me.
I’m joining NoCodeCamp in Japan, then I have strong interest in codeless logic.
If there are no state for codeless logic, I can’t imagine it’s use cases.
Do you have any plan to enhance about state in the near future?
All modern API services (especially the serverless ones) must be stateless. There is no guarantee that your service will be invoked on the same machine where the previous invocation stored state. You can use the Caching API to persist any information between the invocations, but storing it in memory is a very bad idea.
You are very welcome. Btw, this is not related to Codeless. It is a general rule that applies to all API services regardless of how they are implemented. The entire Backendless platform is built that way - all APIs we offer out of the box are stateless.
Now we are developing a SNS application with Backendless and AppGyver for a trial in our community, NoCodeCamp in Japan.
We are planning to end this project within this year. Now we end week 1 as planning phase.
Now we are in week 2 for deciding architecture.
We will implement in week 3 and 4 and release in early next year.
Please notice that it’s just trial and very early release.
Then I don’t have much time.
I would like to follow the URL below at this time.
Thank you for the information, however, I am confused now. You started by asking about storing data in sessions and now we ended with the article you referenced.
You said you wanted to follow the article. Ok, that’s great. Did you run into a problem? If you did, what is it? Please be specific in describing the problem you’re experiencing.
The problem is my misunderstand.
I tried to handle session state in business logic, but now I know it was wrong conceptually.
Then I searched the articles and it looks like good for me.
I’d like to try it this time because I don’t have much time.