Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation #30

Open
masterDen opened this issue Oct 24, 2012 · 7 comments
Open

Documentation #30

masterDen opened this issue Oct 24, 2012 · 7 comments

Comments

@masterDen
Copy link

Could you write documentation (guide, etc) for implementation SocketIOServer listeners?

@mrniko
Copy link
Owner

mrniko commented Oct 25, 2012

Have you seen at demo project code examples? What kind of description is needed?

@masterDen
Copy link
Author

Yes, I see the demo project. What is purpose of AckRequest and AckCallback? What its lifecycle?

@mrniko
Copy link
Owner

mrniko commented Nov 8, 2012

I put some comments right in sources of those classes. Does it help?

@niffrig
Copy link

niffrig commented Feb 10, 2015

Additionally interface documentation for things like JsonSupport. The expectations for namespaces and arrays are unclear. What are the expectations of lifecycle and how are they expected to scale? It appears that a JsonSupport instance is effectively meant to be request scoped but that happens as a detail of implementation in the default JacksonJsonSupport.

@AlexCzar
Copy link

Also I couldn't find any info on how to make SpringAnnotationScanner work. Declaring it like this, does nothing:

@Bean(destroyMethod = "stop")
def socketServer() {
    new SocketIOServer(new com.corundumstudio.socketio.Configuration())
}

@Bean
def socketIoConfigurer() {
    new SpringAnnotationScanner(socketServer())
}

@mrniko
Copy link
Owner

mrniko commented Feb 16, 2015

@AlexCzar i have almost the same config as you wrote and it works. Is socketServer available as bean?

@AlexCzar
Copy link

Yes it is. For now I add all the handler in the static void main() like this:

def app = SpringApplication.run(Bootstrap, args)
def ioServer = app.getBean(SocketIOServer)
ioServer.addListeners(MyHandler)
ioServer.start()

This works, but having to remember to edit main every time I add a new handler class is kinda lame.

By the way, I tried defining handler as a @Service, a @Component and as a @Bean. The problem is the same for all three.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants